diff options
author | Kevin Buettner <kevinb@redhat.com> | 2018-07-30 16:15:34 -0700 |
---|---|---|
committer | Kevin Buettner <kevinb@redhat.com> | 2018-08-18 12:59:15 -0700 |
commit | ae3a7c47e6a95d69a09838c11f9fd3c9cbb25cb6 (patch) | |
tree | fb5df4584b4921d546d4cabfa891443943bdf1bc /gdb/testsuite/lib | |
parent | a6b786da4e3353bf634ec7d9c7bffbd7569e73c6 (diff) | |
download | binutils-gdb-ae3a7c47e6a95d69a09838c11f9fd3c9cbb25cb6.tar.gz |
Add support of DW_OP_GNU_variable_value to DWARF assembler
gdb/testsuite/ChangeLog:
* lib/dwarf.exp: Add support for DW_OP_GNU_variable_value.
Diffstat (limited to 'gdb/testsuite/lib')
-rw-r--r-- | gdb/testsuite/lib/dwarf.exp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/gdb/testsuite/lib/dwarf.exp b/gdb/testsuite/lib/dwarf.exp index 82ec29b57dc..0c3f50a0388 100644 --- a/gdb/testsuite/lib/dwarf.exp +++ b/gdb/testsuite/lib/dwarf.exp @@ -962,6 +962,20 @@ namespace eval Dwarf { _op .sleb128 [lindex $line 2] } + DW_OP_GNU_variable_value { + if {[llength $line] != 2} { + error "usage: $opcode LABEL" + } + + # Here label is a section offset. + set label [lindex $line 1] + if { $_cu_version == 2 } { + _op .${_cu_addr_size}byte $label + } else { + _op .${_cu_offset_size}byte $label + } + } + DW_OP_deref_size { if {[llength $line] != 2} { error "usage: DW_OP_deref_size SIZE" |