[PATCH] D40025: [LLD] [COFF] Always truncate the .eh_frame section name
Martin Storsjö via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 14 23:45:39 PST 2017
mstorsjo added inline comments.
================
Comment at: COFF/Writer.cpp:544
continue;
+ if (Name == ".eh_frame" && Config->MinGW)
+ continue;
----------------
ruiu wrote:
> I'd prefer doing this at the very early stage instead of this late. Can you modify InputFiles.cpp so that a section with name ".eh_frame" is read as if ".eh_fram"?
>
> I also wonder if there's a problem if we do not limit it to MinGW. Generally I'd try reducing "if (MinGW)" code, so if we can do this unconditionally, we should do that unconditionally.
I guess that's doable as well.
What do you think about @rnk 's suggestion about always truncating it for any section that will be mapped at runtime (only write long names for sections with the flag IMAGE_SCN_MEM_DISCARDABLE, or what's the right way to find out about that)?
I don't mind removing the "if (MinGW)" if what the patch does is considered favourable in general and not just a tradeoff/workaround for this case.
https://reviews.llvm.org/D40025
More information about the llvm-commits
mailing list