[PATCH] D37736: [ELF] - Do not spread specific flags when emiting output sections.

Rafael Avila de Espindola via llvm-commits llvm-commits at lists.llvm.org
Fri Oct 6 15:14:54 PDT 2017


Rui Ueyama via Phabricator <reviews at reviews.llvm.org> writes:

> ruiu added a comment.
>
> I still don't think I understand the point of this patch. This patch in the original form says that the patch is to fix a crash bug, but it does not crash anymore (is this correct?)
>
> Then what's the point to set a "correct" flag to an empty section? Since a section is empty, it doesn't have any visible effect, no?

It does. At least:

* Orphan placement uses the flags.
* Program header creation uses the flags.
* assignAddresses uses SHF_ALLOC.

We can change those to know about these dummy sections, or we can pick a
flag that has the desired effect.

Cheers,
Rafael


More information about the llvm-commits mailing list