aboutsummaryrefslogtreecommitdiff
path: root/gdb/dwarf2
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/dwarf2')
-rw-r--r--gdb/dwarf2/attribute.c5
-rw-r--r--gdb/dwarf2/attribute.h1
-rw-r--r--gdb/dwarf2/read.c16
3 files changed, 18 insertions, 4 deletions
diff --git a/gdb/dwarf2/attribute.c b/gdb/dwarf2/attribute.c
index 4792610..b4f188a 100644
--- a/gdb/dwarf2/attribute.c
+++ b/gdb/dwarf2/attribute.c
@@ -179,6 +179,7 @@ attribute::form_is_unsigned () const
|| form == DW_FORM_flag_present
|| form == DW_FORM_udata
|| form == DW_FORM_rnglistx
+ || form == DW_FORM_loclistx
|| form == DW_FORM_ref1
|| form == DW_FORM_ref2
|| form == DW_FORM_ref4
@@ -197,7 +198,9 @@ attribute::form_requires_reprocessing () const
|| form == DW_FORM_strx4
|| form == DW_FORM_GNU_str_index
|| form == DW_FORM_addrx
- || form == DW_FORM_GNU_addr_index);
+ || form == DW_FORM_GNU_addr_index
+ || form == DW_FORM_rnglistx
+ || form == DW_FORM_loclistx);
}
/* See attribute.h. */
diff --git a/gdb/dwarf2/attribute.h b/gdb/dwarf2/attribute.h
index a3ff9b0..56776d6 100644
--- a/gdb/dwarf2/attribute.h
+++ b/gdb/dwarf2/attribute.h
@@ -223,6 +223,7 @@ struct attribute
{
gdb_assert (form_is_unsigned ());
u.unsnd = unsnd;
+ requires_reprocessing = 0;
}
/* Temporarily set this attribute to an unsigned integer. This is
diff --git a/gdb/dwarf2/read.c b/gdb/dwarf2/read.c
index ee0f8be..4fe4f94 100644
--- a/gdb/dwarf2/read.c
+++ b/gdb/dwarf2/read.c
@@ -20315,10 +20315,20 @@ read_attribute_reprocess (const struct die_reader_specs *reader,
attr->as_unsigned_reprocess ()));
break;
case DW_FORM_loclistx:
- attr->set_address (read_loclist_index (cu, attr->as_unsigned ()));
- break;
+ {
+ CORE_ADDR loclists_sect_off
+ = read_loclist_index (cu, attr->as_unsigned_reprocess ());
+
+ attr->set_unsigned (loclists_sect_off);
+ }
+ break;
case DW_FORM_rnglistx:
- attr->set_address (read_rnglist_index (cu, attr->as_unsigned (), tag));
+ {
+ CORE_ADDR rnglists_sect_off
+ = read_rnglist_index (cu, attr->as_unsigned_reprocess (), tag);
+
+ attr->set_unsigned (rnglists_sect_off);
+ }
break;
case DW_FORM_strx:
case DW_FORM_strx1: