diff options
author | Jakub Jelinek <jakub@redhat.com> | 2012-05-10 06:18:48 +0000 |
---|---|---|
committer | Jakub Jelinek <jakub@redhat.com> | 2012-05-10 06:18:48 +0000 |
commit | afd6e1ffce8eec2e38d90dcb4a0af004e413e277 (patch) | |
tree | 2949a9a2e34875bd54954ddd582e99ede1319549 | |
parent | 83acd3e879271522628c834171c3e52c041c90cc (diff) | |
download | binutils-gdb-afd6e1ffce8eec2e38d90dcb4a0af004e413e277.tar.gz |
* dwarf.c (read_and_display_attr_value): Don't look up tag from
abbrev for DW_FORM_ref_addr.
-rw-r--r-- | binutils/ChangeLog | 5 | ||||
-rw-r--r-- | binutils/dwarf.c | 16 |
2 files changed, 16 insertions, 5 deletions
diff --git a/binutils/ChangeLog b/binutils/ChangeLog index 6fad5075156..c5b85c065c0 100644 --- a/binutils/ChangeLog +++ b/binutils/ChangeLog @@ -1,3 +1,8 @@ +2012-05-10 Jakub Jelinek <jakub@redhat.com> + + * dwarf.c (read_and_display_attr_value): Don't look up tag from + abbrev for DW_FORM_ref_addr. + 2012-05-08 Sean Keys <skeys@ipdatasys.com> * binutils/MAINTAINERS: Added my entry to the maintainers secion. diff --git a/binutils/dwarf.c b/binutils/dwarf.c index 856a851a437..5361396b8ef 100644 --- a/binutils/dwarf.c +++ b/binutils/dwarf.c @@ -1716,11 +1716,17 @@ read_and_display_attr_value (unsigned long attribute, abbrev_number = read_leb128 (section->start + uvalue, NULL, 0); printf (_("[Abbrev Number: %ld"), abbrev_number); - for (entry = first_abbrev; entry != NULL; entry = entry->next) - if (entry->entry == abbrev_number) - break; - if (entry != NULL) - printf (" (%s)", get_TAG_name (entry->tag)); + /* Don't look up abbrev for DW_FORM_ref_addr, as it very often will + use different abbrev table, and we don't track .debug_info chunks + yet. */ + if (form != DW_FORM_ref_addr) + { + for (entry = first_abbrev; entry != NULL; entry = entry->next) + if (entry->entry == abbrev_number) + break; + if (entry != NULL) + printf (" (%s)", get_TAG_name (entry->tag)); + } printf ("]"); } } |