summaryrefslogtreecommitdiff
path: root/binutils/dwarf.c
diff options
context:
space:
mode:
authorCary Coutant <ccoutant@google.com>2013-05-29 00:39:32 +0000
committerCary Coutant <ccoutant@google.com>2013-05-29 00:39:32 +0000
commit5c6692ceeaaf77e554956dd7c4595203dcac9b69 (patch)
treebc4be827395a5820f5b71c8c383c9bf9a9c08cea /binutils/dwarf.c
parent498ee3cb415ada89ccef993d4f6f4b07b12a6169 (diff)
downloadbinutils-redhat-5c6692ceeaaf77e554956dd7c4595203dcac9b69.tar.gz
binutils/
* dwarf.c (display_debug_lines_raw): Print section offsets. binutils/testsuite/ * binutils-all/dw2-1.W: Adjust expected output. * binutils-all/objdump.W: Likewise. * binutils-all/i386/compressed-1a.d: Likewise. * binutils-all/x86-64/compressed-1a.d: Likewise. gas/testsuite/ * gas/cris/rd-dw2-1.d: Adjust expected output. * gas/cris/rd-dw2-10.d: Likewise. * gas/cris/rd-dw2-11.d: Likewise. * gas/cris/rd-dw2-12.d: Likewise. * gas/cris/rd-dw2-13.d: Likewise. * gas/cris/rd-dw2-14.d: Likewise. * gas/cris/rd-dw2-15.d: Likewise. * gas/cris/rd-dw2-2.d: Likewise. * gas/cris/rd-dw2-3.d: Likewise. * gas/cris/rd-dw2-4.d: Likewise. * gas/cris/rd-dw2-5.d: Likewise. * gas/cris/rd-dw2-6.d: Likewise. * gas/cris/rd-dw2-7.d: Likewise. * gas/cris/rd-dw2-8.d: Likewise. * gas/cris/rd-dw2-9.d: Likewise. * gas/elf/dwarf2-1.d: Likewise. * gas/elf/dwarf2-2.d: Likewise. * gas/elf/dwarf2-3.d: Likewise. * gas/i386/debug1.d: Likewise. * gas/i386/dw2-compress-1.d: Likewise. * gas/i386/ilp32/lns/lns-common-1.d: Likewise. * gas/i386/ilp32/lns/lns-duplicate.d: Likewise. * gas/ia64/pr13167.d: Likewise. * gas/lns/lns-big-delta.d: Likewise. * gas/lns/lns-common-1-alt.d: Likewise. * gas/lns/lns-common-1.d: Likewise. * gas/lns/lns-duplicate.d: Likewise. * gas/mips/loc-swap-2.d: Likewise. * gas/mips/loc-swap.d: Likewise. * gas/mips/micromips@loc-swap-2.d: Likewise. * gas/mips/micromips@loc-swap.d: Likewise. * gas/mips/mips16-dwarf2-n32.d: Likewise. * gas/mips/mips16-dwarf2.d: Likewise. * gas/mips/mips16@loc-swap-2.d: Likewise. * gas/mips/mips16@loc-swap.d: Likewise.
Diffstat (limited to 'binutils/dwarf.c')
-rw-r--r--binutils/dwarf.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/binutils/dwarf.c b/binutils/dwarf.c
index 862a060bd9..4063f0a0ca 100644
--- a/binutils/dwarf.c
+++ b/binutils/dwarf.c
@@ -2656,7 +2656,8 @@ display_debug_lines_raw (struct dwarf_section *section,
DWARF2_Internal_LineInfo linfo;
unsigned char *standard_opcodes;
unsigned char *end_of_sequence;
- int i;
+ unsigned int last_dir_entry = 0;
+ int i;
if (const_strneq (section->name, ".debug_line.")
/* Note: the following does not apply to .debug_line.dwo sections.
@@ -2715,11 +2716,12 @@ display_debug_lines_raw (struct dwarf_section *section,
printf (_("\n The Directory Table is empty.\n"));
else
{
- printf (_("\n The Directory Table:\n"));
+ printf (_("\n The Directory Table (offset 0x%lx):\n"),
+ (long)(data - start));
while (*data != 0)
{
- printf (" %s\n", data);
+ printf (" %d\t%s\n", ++last_dir_entry, data);
data += strnlen ((char *) data, end - data) + 1;
}
@@ -2733,7 +2735,8 @@ display_debug_lines_raw (struct dwarf_section *section,
printf (_("\n The File Name Table is empty.\n"));
else
{
- printf (_("\n The File Name Table:\n"));
+ printf (_("\n The File Name Table (offset 0x%lx):\n"),
+ (long)(data - start));
printf (_(" Entry\tDir\tTime\tSize\tName\n"));
while (*data != 0)
@@ -2784,6 +2787,8 @@ display_debug_lines_raw (struct dwarf_section *section,
dwarf_vma uladv;
unsigned int bytes_read;
+ printf (" [0x%08lx]", (long)(data - start));
+
op_code = *data++;
if (op_code >= linfo.li_opcode_base)