From: Jakub Jelinek Date: Wed, 22 Jun 2011 15:03:19 +0000 (+0000) Subject: * dwarf2.h (enum dwarf_location_atom): Add DW_OP_GNU_parameter_ref. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=f8b999f94554f44229f48a6c93fc14e715871091;p=binutils-gdb.git * dwarf2.h (enum dwarf_location_atom): Add DW_OP_GNU_parameter_ref. * dwarf.c (decode_location_expression): For DW_OP_GNU_convert and DW_OP_GNU_reinterpret, if uvalue is 0, don't add cu_offset. Handle DW_OP_GNU_parameter_ref. --- diff --git a/binutils/ChangeLog b/binutils/ChangeLog index 29563e11633..edb87600c54 100644 --- a/binutils/ChangeLog +++ b/binutils/ChangeLog @@ -1,3 +1,9 @@ +2011-06-22 Jakub Jelinek + + * dwarf.c (decode_location_expression): For DW_OP_GNU_convert and + DW_OP_GNU_reinterpret, if uvalue is 0, don't add cu_offset. + Handle DW_OP_GNU_parameter_ref. + 2011-06-16 Tom Tromey * dwarf-mode.el (dwarf-do-insert-substructure): Call diff --git a/binutils/dwarf.c b/binutils/dwarf.c index 46c454adf68..f5a8d7bf17e 100644 --- a/binutils/dwarf.c +++ b/binutils/dwarf.c @@ -1179,13 +1179,18 @@ decode_location_expression (unsigned char * data, uvalue = read_leb128 (data, &bytes_read, 0); data += bytes_read; printf ("DW_OP_GNU_convert <0x%s>", - dwarf_vmatoa ("x", cu_offset + uvalue)); + dwarf_vmatoa ("x", uvalue ? cu_offset + uvalue : 0)); break; case DW_OP_GNU_reinterpret: uvalue = read_leb128 (data, &bytes_read, 0); data += bytes_read; printf ("DW_OP_GNU_reinterpret <0x%s>", - dwarf_vmatoa ("x", cu_offset + uvalue)); + dwarf_vmatoa ("x", uvalue ? cu_offset + uvalue : 0)); + break; + case DW_OP_GNU_parameter_ref: + printf ("DW_OP_GNU_parameter_ref: <0x%s>", + dwarf_vmatoa ("x", cu_offset + byte_get (data, 4))); + data += 4; break; /* HP extensions. */ diff --git a/include/ChangeLog b/include/ChangeLog index 6ff56e6b065..83c7bcee909 100644 --- a/include/ChangeLog +++ b/include/ChangeLog @@ -1,3 +1,7 @@ +2011-06-22 Jakub Jelinek + + * dwarf2.h (enum dwarf_location_atom): Add DW_OP_GNU_parameter_ref. + 2011-06-20 Jakub Jelinek PR ld/12570 diff --git a/include/dwarf2.h b/include/dwarf2.h index 0b008661f96..b2806ef78c9 100644 --- a/include/dwarf2.h +++ b/include/dwarf2.h @@ -563,6 +563,8 @@ enum dwarf_location_atom DW_OP_GNU_deref_type = 0xf6, DW_OP_GNU_convert = 0xf7, DW_OP_GNU_reinterpret = 0xf9, + /* The GNU parameter ref extension. */ + DW_OP_GNU_parameter_ref = 0xfa, /* HP extensions. */ DW_OP_HP_unknown = 0xe0, /* Ouch, the same as GNU_push_tls_address. */ DW_OP_HP_is_value = 0xe1,