[PATCH] D27415: [ELF] - Replace MergeOutputSection with synthetic input section MergeSection.

Rui Ueyama via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Dec 16 08:58:30 PST 2016

ruiu added inline comments.

Comment at: ELF/OutputSections.cpp:134
+  if (auto *Sec = dyn_cast<MergeSyntheticSection<ELFT>>(C))
+    Sec->setOutputSection(this);
Do you really need this? This looks odd because you are handling MergeInputSection in a special way. Generally you want to avoid that as possible. If you really need this, this may be a sign that we need to fix something else.

Comment at: ELF/Writer.cpp:200
+  combineMergableSections(Symtab<ELFT>::X->Sections);
As you know we usually do not pass around `Symtab<ELFT>::X->Sections`.


More information about the llvm-commits mailing list