[PATCH] D33643: [ELF] - Allow multiple comdats when producing relocatable output.
Rui Ueyama via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jun 5 08:53:33 PDT 2017
ruiu accepted this revision.
ruiu added a comment.
This revision is now accepted and ready to land.
LGTM with this change.
================
Comment at: ELF/OutputSections.cpp:363-365
+ // Used for -r. When we have multiple different SHT_GROUPs, they may have
+ // equal names, flags and other properties. We should not combine such
+ // sections, but create single output section for each input.
----------------
Then this explanation doesn't capture why we are doing this.
Sections with the SHT_GROUP attribute reach here only when the -r option is given. Such sections define "section groups", and InputFiles.cpp has dedup'ed section groups by their signatures. For the -r, we want to pass through all SHT_GROUP sections without merging them because merging them creates broken section contents.
https://reviews.llvm.org/D33643
More information about the llvm-commits
mailing list