[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug binutils/28689] p_align in ELF program headers should not exceed se
From: |
hjl.tools at gmail dot com |
Subject: |
[Bug binutils/28689] p_align in ELF program headers should not exceed section alignment |
Date: |
Mon, 13 Dec 2021 23:53:39 +0000 |
https://sourceware.org/bugzilla/show_bug.cgi?id=28689
--- Comment #2 from H.J. Lu <hjl.tools at gmail dot com> ---
One problem:
Elf file type is EXEC (Executable file)
Entry point 0x600000
There are 7 program headers, starting at offset 64
Program Headers:
Type Offset VirtAddr PhysAddr FileSiz MemSiz
Flg Align
LOAD 0x000000 0x0000000000400000 0x0000000000400000 0x0001f8
0x0001f8 R 0x1000
LOAD 0x200000 0x0000000000600000 0x0000000000600000 0x000001
0x000001 R E 0x1000
LOAD 0x400000 0x0000000000800000 0x0000000000800000 0x002000
0x002000 RW 0x1000
NOTE 0x0001c8 0x00000000004001c8 0x00000000004001c8 0x000030
0x000030 R 0x8
TLS 0x400000 0x0000000000800000 0x0000000000800000 0x001000
0x001000 R 0x10
GNU_PROPERTY 0x0001c8 0x00000000004001c8 0x00000000004001c8 0x000030
0x000030 R 0x8
GNU_RELRO 0x400000 0x0000000000800000 0x0000000000800000 0x001000
0x001000 R 0x1
But objcopy will take p_align as the maximum page size:
Elf file type is EXEC (Executable file)
Entry point 0x600000
There are 7 program headers, starting at offset 64
Program Headers:
Type Offset VirtAddr PhysAddr FileSiz MemSiz
Flg Align
LOAD 0x000000 0x0000000000400000 0x0000000000400000 0x0001f8
0x0001f8 R 0x1000
LOAD 0x001000 0x0000000000600000 0x0000000000600000 0x000001
0x000001 R E 0x1000
LOAD 0x002000 0x0000000000800000 0x0000000000800000 0x002000
0x002000 RW 0x1000
NOTE 0x0001c8 0x00000000004001c8 0x00000000004001c8 0x000030
0x000030 R 0x8
TLS 0x002000 0x0000000000800000 0x0000000000800000 0x001000
0x001000 R 0x10
GNU_PROPERTY 0x0001c8 0x00000000004001c8 0x00000000004001c8 0x000030
0x000030 R 0x8
GNU_RELRO 0x002000 0x0000000000800000 0x0000000000800000 0x001000
0x001000 R 0x1
File offsets are changed.
--
You are receiving this mail because:
You are on the CC list for the bug.
- [Bug binutils/28689] New: p_align in ELF program headers should not exceed section alignment, fweimer at redhat dot com, 2021/12/13
- [Bug binutils/28689] p_align in ELF program headers should not exceed section alignment, hjl.tools at gmail dot com, 2021/12/13
- [Bug binutils/28689] p_align in ELF program headers should not exceed section alignment, hjl.tools at gmail dot com, 2021/12/13
- [Bug binutils/28689] p_align in ELF program headers should not exceed section alignment,
hjl.tools at gmail dot com <=
- [Bug binutils/28689] p_align in ELF program headers should not exceed section alignment, hjl.tools at gmail dot com, 2021/12/13
- [Bug binutils/28689] p_align in ELF program headers should not exceed section alignment, i at maskray dot me, 2021/12/14
- [Bug binutils/28689] p_align in ELF program headers should not exceed section alignment, i at maskray dot me, 2021/12/14
- [Bug binutils/28689] p_align in ELF program headers should not exceed section alignment, hjl.tools at gmail dot com, 2021/12/14