https://sourceware.org/bugzilla/show_bug.cgi?id=32221
Bug ID: 32221
Summary: -z separate-code doesn't work correctly for many
targets
Product: binutils
Version: 2.44 (HEAD)
Status: NEW
Severity: normal
Priority: P2
Component: ld
Assignee: unassigned at sourceware dot org
Reporter: hjl.tools at gmail dot com
Target Milestone: ---
commit 428f3561bc16dfc2944ee641201acdd166315aa2
Author: Alan Modra <[email protected]>
Date: Fri Sep 27 09:53:10 2024 +0930
Enable -z separate-code, -z common and -z text for more targets
Fix a mis-placed "fi"
enables -z separate-code for more targets. But it doesn't work correctly
for targets like arc-elf. testsuite/ld-elf/pr23658-1e.d passes on arc-elf.
But the output is wrong:
Elf file type is EXEC (Executable file)
Entry point 0x1c8
There are 4 program headers, starting at offset 52
Program Headers:
Type Offset VirtAddr PhysAddr FileSiz MemSiz Flg Align
LOAD 0x000000 0x00000000 0x00000000 0x001cc 0x001cc R E 0x2000
LOAD 0x0001cc 0x000021cc 0x000021cc 0x00000 0x15004 RW 0x2000
NOTE 0x000100 0x00000100 0x00000100 0x00050 0x00050 R 0x8
NOTE 0x000150 0x00000150 0x00000150 0x00074 0x00074 R 0x4
Section to Segment mapping:
Segment Sections...
00 .note.4 .note.1 .note.2 .note.3 .note.gnu.build-id .text
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ This is wrong.
01 .bss .heap .stack
02 .note.4 .note.1
03 .note.2 .note.3 .note.gnu.build-id
[hjl@gnu-tgl-3 ld]$
--
You are receiving this mail because:
You are on the CC list for the bug.