]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
Add support for new DWARF overlay operations users/zaric/location_on_dwarf_stack
authorZoran Zaric <zoran.zaric@amd.com>
Tue, 25 Oct 2022 13:33:36 +0000 (14:33 +0100)
committerZoran Zaric <zoran.zaric@amd.com>
Wed, 26 Oct 2022 09:43:27 +0000 (10:43 +0100)
commitb7383d64e7184470d19132831abb6f5b893d7b6e
tree5ca1643c9f2c7a01ad879aa0654d0b03655de8b7
parenta50f771b91791dcdd17aabd62ee83d76d6229c75
Add support for new DWARF overlay operations

Another complex DWARF expression operations, that are usefull for
SIMD/SIMT like architectures are: DW_OP_LLVM_overlay and
DW_OP_LLVM_bit_overlay. These operations pop four stack entries,
where the first must be an integral that represents an overlay size,
the second must be an integral that represents a starting point of the
overlay from the base location, the third must be a location
description that represents the overlay location description and the
forth must be a location description that represents the base location
description.

Resulting composite location description contains parts from base
location description, overlayed by the overlay location description,
starting from the overlay offset, ending at a sum of the overlay offset
and overlay size.

A new test in gdb.dwarf2 called dw2-llvm-overlay has been also added to
test the support for both operations.
gdb/compile/compile-loc2c.c
gdb/dwarf2/expr.c
gdb/dwarf2/loc.c
gdb/testsuite/gdb.dwarf2/dw2-llvm-overlay.c [new file with mode: 0644]
gdb/testsuite/gdb.dwarf2/dw2-llvm-overlay.exp [new file with mode: 0644]
include/dwarf2.def