[PATCH] D59531: [ELF] Produce multiple PT_NOTE segments as needed
Peter Smith via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Mar 19 05:22:46 PDT 2019
peter.smith added a comment.
In D59531#1434312 <https://reviews.llvm.org/D59531#1434312>, @pcc wrote:
> Is it possible for this to fail with a linker script that looks like:
>
> SECTIONS {
> . = SIZEOF_HEADERS;
> .note1 : { *(.note1) }
> . = 0x10000;
> .note2 : { *(.note2) }
> }
>
>
> ?
AFAICT this will produce a single very large PT_NOTE. In this particular case I'd think that the intention of the script author would be for the notes to be separate as they wouldn't be accounting for the gap in the middle. Given that a parser will want to iterate based on the alignment of the program header, perhaps generate a new PT_NOTE if there is more than one alignment padding's gap between contiguous Note OutputSections.
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D59531/new/
https://reviews.llvm.org/D59531
More information about the llvm-commits
mailing list