A base address selection entry in a location list consist of two (constant or
relocated) address offsets. The two offsets are the same size as an address
on the target machine.
The test-case gdb.dwarf2/dw2-skip-prologue.S encodes a base address selection
entry using .4byte, which is incorrect for 8-byte pointer size. [ Which
triggers an assert in dwz, see PR dwz/24172. ]
Fix this by using PTRBYTE instead.
Tested on x86_64-linux.
gdb/testsuite/ChangeLog:
2019-05-14 Tom de Vries <tdevries@suse.de>
* gdb.dwarf2/dw2-skip-prologue.S (.debug_loc): Fix base address
selection entry encoding.
+2019-05-14 Tom de Vries <tdevries@suse.de>
+
+ * gdb.dwarf2/dw2-skip-prologue.S (.debug_loc): Fix base address
+ selection entry encoding.
+
2019-05-10 Tom Tromey <tromey@adacore.com>
* gdb.ada/info_exc.exp: Add "complete" test.
.section .debug_loc
loclist:
/* Reset the location list base address first. */
- .4byte -1, 0
+ PTRBYTE -1, 0
PTRBYTE func_start, func_end
.2byte 2f-1f