[all-commits] [llvm/llvm-project] fbf2f6: [ELF] Update flag propagation rule to ignore disca...
Fangrui Song via All-commits
all-commits at lists.llvm.org
Tue Feb 1 10:19:44 PST 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: fbf2f6640067dec144f9aef8231d58c740e3d014
https://github.com/llvm/llvm-project/commit/fbf2f6640067dec144f9aef8231d58c740e3d014
Author: Fangrui Song <i at maskray.me>
Date: 2022-02-01 (Tue, 01 Feb 2022)
Changed paths:
M lld/ELF/LinkerScript.cpp
M lld/test/ELF/linkerscript/insert-before.test
Log Message:
-----------
[ELF] Update flag propagation rule to ignore discarded output sections
See the updated insert-before.test for the effects: many synthetic
sections are SHF_ALLOC|SHF_WRITE. If they are discarded, we don't want
to propagate their flags to subsequent output section descriptions.
`getFirstInputSection(sec) == nullptr` can technically be merged into
`isDiscardable` but I'd like to postpone that as not sharing code may give more
refactoring opportunity.
Depends on D118529.
Reviewed By: peter.smith, bluca
Differential Revision: https://reviews.llvm.org/D118530
More information about the All-commits
mailing list