bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug ld/22423] PT_PHDR segment is marked with PF_X


From: ppluzhnikov at google dot com
Subject: [Bug ld/22423] PT_PHDR segment is marked with PF_X
Date: Sun, 12 Nov 2017 01:16:29 +0000

https://sourceware.org/bugzilla/show_bug.cgi?id=22423

Paul Pluzhnikov <ppluzhnikov at google dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ppluzhnikov at google dot com

--- Comment #1 from Paul Pluzhnikov <ppluzhnikov at google dot com> ---
> It was reasonable 20 years ago.

Normally PT_PHDR overlaps with the first PT_LOAD.

If you keep that, the flags on PT_PHDR don't matter (the first PT_LOAD will
have PF_X).

If you don't keep the overlap, you'll waste an entire page for 64-byte PT_PHDR.

Also, a lot of programs assume that the first PT_LOAD "covers" PT_PHDR and
starts with ElfW(Ehdr). It's not guaranteed, but it has been true for the last
20 years. You'll break all such programs.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]