[PATCH] D139069: [lld-macho] Ignored aliases to weak symbols should not retain section data

Vy Nguyen via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Dec 1 06:05:25 PST 2022


oontvoo accepted this revision.
oontvoo added a comment.
This revision is now accepted and ready to land.

LG!

(Not sure why  git-clang-format is failing for the debian build ... probably unrelated?)



================
Comment at: lld/MachO/InputFiles.cpp:624
 
+static bool isIgnoredName(StringRef name) {
+  return name.startswith("l") || name.startswith("L");
----------------
int3 wrote:
> int3 wrote:
> > oontvoo wrote:
> > > super nit ...
> > will add the comment. honestly I don't think either name is super good heh (I went back and forth before deciding on this). ld64 calls them "ignored labels" which doesn't seem great either because the rest of the code doesn't use the word "label"
> > 
> > but the symbol isn't exactly ignored either :/ it's used at parse time, just immediately dropped as part of the parse...
> > 
> > will mull on this a bit
> MC calls these "private labels" so let's go with that (see https://github.com/llvm/llvm-project/blob/main/llvm/lib/MC/MCAsmInfo.cpp#L46)
SG!


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D139069/new/

https://reviews.llvm.org/D139069



More information about the llvm-commits mailing list