[PATCH] D44622: [ELF] - Fix for "LLD crashes with --emit-relocs when trying to proccess .eh_frame"
Rafael Avila de Espindola via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 19 14:09:56 PDT 2018
espindola added inline comments.
================
Comment at: ELF/Writer.cpp:161
+ // sections because them are special.
+ if (Config->EmitRelocs)
+ std::stable_partition(V.begin(), V.end(), [](InputSectionBase *IS) {
----------------
This is a useful invariant. Could we do this even when Config->EmitRelocs is false?
================
Comment at: ELF/Writer.cpp:1391
static void removeUnusedSyntheticSections() {
// All input synthetic sections that can be empty are placed after
// all regular ones. We iterate over them all and exit at first
----------------
This comment is now out of date.
================
Comment at: test/ELF/emit-relocs-eh-frame.s:17
+ .Lfunc_end0:
+ .size foo, .Lfunc_end0-foo
+ .cfi_endproc
----------------
I think you can delete the .size and the .Lfunc_end0.
https://reviews.llvm.org/D44622
More information about the llvm-commits
mailing list