This is an archive of the discontinued LLVM Phabricator instance.

[ELF] Ignore sections flagged with SHF_EXCLUDE
ClosedPublic

Authored by evgeny777 on Sep 27 2016, 8:15 AM.

Details

Summary

The spec says:

This section is excluded from input to the link-edit of an executable or shared object. This flag is ignored if the SHF_ALLOC flag is also set, or if relocations exist against the section.

However both gold and ld seem to always discard such sections. The same approach was chosen for this patch.

Diff Detail

Event Timeline

evgeny777 updated this revision to Diff 72655.Sep 27 2016, 8:15 AM
evgeny777 retitled this revision from to [ELF] Ignore sections flagged with SHF_EXCLUDE.
evgeny777 updated this object.
evgeny777 added reviewers: ruiu, rafael.
evgeny777 set the repository for this revision to rL LLVM.
evgeny777 added a project: lld.
evgeny777 added subscribers: grimar, ikudrin, llvm-commits.
rafael accepted this revision.Sep 27 2016, 9:37 AM
rafael edited edge metadata.
This revision is now accepted and ready to land.Sep 27 2016, 9:37 AM
This revision was automatically updated to reflect the committed changes.
ruiu edited edge metadata.Sep 28 2016, 1:01 PM

LGTM