DWARF-5: DW_FORM_data16
authorJan Kratochvil <jan.kratochvil@redhat.com>
Mon, 20 Feb 2017 19:53:22 +0000 (20:53 +0100)
committerJan Kratochvil <jan.kratochvil@redhat.com>
Mon, 20 Feb 2017 20:02:20 +0000 (21:02 +0100)
commit0224619f6085908935f689b87e1ac4e460bb1e71
tree34c09b59c3bad8775318ecbc545bb39038ec6e28
parent0af92d6069f5c43f0090b78d4cb8fda7d9861b22
DWARF-5: DW_FORM_data16

DWARF-5 has new form DW_FORM_data16.  The problem is that GDB cannot pass
16-byte constant as a constant value as that would require GDB to use GCC
extension __int128.

Formerly such data was coded as DW_FORM_block* so GDB still decodes
DW_FORM_data16 like DW_FORM_block*.

gdb/ChangeLog
2017-02-20  Jan Kratochvil  <jan.kratochvil@redhat.com>

* dwarf2read.c (skip_one_die, read_attribute_value)
(dwarf2_const_value_attr, dump_die_shallow)
(dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
(skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.

gdb/testsuite/ChangeLog
2017-02-20  Jan Kratochvil  <jan.kratochvil@redhat.com>

* gdb.dwarf2/formdata16.c: New file.
* gdb.dwarf2/formdata16.exp: New file.
* lib/dwarf.exp (Dwarf): Add DW_FORM_data16.
gdb/ChangeLog
gdb/dwarf2read.c
gdb/testsuite/ChangeLog
gdb/testsuite/gdb.dwarf2/formdata16.c [new file with mode: 0644]
gdb/testsuite/gdb.dwarf2/formdata16.exp [new file with mode: 0644]
gdb/testsuite/lib/dwarf.exp