[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug default/24251] New: Allocatable section after non-allocatable ones
https://sourceware.org/bugzilla/show_bug.cgi?id=24251
Bug ID: 24251
Summary: Allocatable section after non-allocatable ones
Product: dwz
Version: unspecified
Status: NEW
Severity: normal
Priority: P2
Component: default
Assignee: nobody at sourceware dot org
Reporter: vries at gcc dot gnu.org
CC: dwz at sourceware dot org
Target Milestone: ---
[ This is essentially a refiling of PR21191 - "objcopy --only-keep-debug
creates non-monotonically increasing section offsets", which was closed as
WONTFIX, for dwz. ]
For the example from PR21191, with trunk dwz and objcopy we have:
...
$ cat t.c
int main()
{
}
$ gcc t.c -g
$ objcopy --only-keep-debug a.out a.debug
$ dwz a.debug
dwz: Allocatable section in a.debug after non-allocatable ones
...
The dwz tool complains that allocatable section .init_array at offset 0xe40:
...
[17] .init_array NOBITS 0000000000600e40 00000e40
0000000000000008 0000000000000008 WA 0 0 8
...
is at a bigger offset than non-allocatable section .debug_info at offset 0x410:
...
[26] .debug_info PROGBITS 0000000000000000 00000410
00000000000002f3 0000000000000000 0 0 1
...
In the original a.out this situation does not occur:
...
[17] .init_array INIT_ARRAY 0000000000600e40 00000e40
0000000000000008 0000000000000008 WA 0 0 8
[26] .debug_info PROGBITS 0000000000000000 000011a0
00000000000002f3 0000000000000000 0 0 1
...
The rationale with which PR21191 was closed as WONTFIX is: "File offset for a
SHT_NOBITS section is irrelevant".
Following that rationale, dwz should not complain here.
--
You are receiving this mail because:
You are on the CC list for the bug.