[PATCH] D114195: [lld/mac] Crash even less on undefined symbols with --icf=all
Jez Ng via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Nov 18 22:47:10 PST 2021
int3 accepted this revision.
int3 added inline comments.
This revision is now accepted and ready to land.
================
Comment at: lld/MachO/ICF.cpp:117
if (!isa<Defined>(sa)) {
- assert(isa<DylibSymbol>(sa));
+ assert(isa<DylibSymbol>(sa) || isa<Undefined>(sa));
return sa == sb;
----------------
hmm having an Undefined here basically means that the link will error out, right? maybe add a comment to that effect
(tbh I'm not sure the assert is worth much any more, basically the only thing we are still excluding is LazySymbols...)
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D114195/new/
https://reviews.llvm.org/D114195
More information about the llvm-commits
mailing list