[PATCH] D123252: [lld/mac] Don't emit stabs entries for functions folded during ICF
Jez Ng via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Apr 6 21:07:00 PDT 2022
int3 accepted this revision.
int3 added inline comments.
This revision is now accepted and ready to land.
================
Comment at: lld/MachO/Symbols.cpp:103
+ isec = canonical;
+ wasIdenticalCodeFolded = true;
+ }
----------------
How do you feel about doing this work in `ConcatInputSection::foldIdentical` instead? We already toggle `ConcatInputSection::wasCoalesced` there, so this would fit in nicely.
(We could also perform the canonicalization of `Defined::isec` there -- I'd previously put it here because InputSections didn't use to hold references to their symbols.)
================
Comment at: lld/MachO/Symbols.h:148
bool includeInSymtab : 1;
+ // Whether this symbol was folded with a different symbol during ICF.
+ bool wasIdenticalCodeFolded : 1;
----------------
nit: "with" suggests a symmetric relationship, "into" seems more apt to me
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D123252/new/
https://reviews.llvm.org/D123252
More information about the llvm-commits
mailing list