This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
[committed] Don't relocate parisc unwind addresses twice in readelf
- From: "John David Anglin" <dave at hiauly1 dot hia dot nrc dot ca>
- To: binutils at sourceware dot org
- Date: Sun, 8 Nov 2009 16:45:17 -0500 (EST)
- Subject: [committed] Don't relocate parisc unwind addresses twice in readelf
The attached patch fixes another problem noticed trying to debug
out of order unwind entries in the parisc linux kernel. readelf -u
when applied to a .o file would display twice the expected values
for the start and end offsets of a function.
Tested on hppa-unknown-linux-gnu. Committed to trunk.
Dave
--
J. David Anglin dave.anglin@nrc-cnrc.gc.ca
National Research Council of Canada (613) 990-0752 (FAX: 952-6602)
2009-11-08 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
* readelf.c (slurp_hppa_unwind_table): Don't relocate address twice.
Index: readelf.c
===================================================================
RCS file: /cvs/src/src/binutils/readelf.c,v
retrieving revision 1.467
diff -u -3 -p -r1.467 readelf.c
--- readelf.c 23 Oct 2009 00:15:07 -0000 1.467
+++ readelf.c 29 Oct 2009 20:59:26 -0000
@@ -5589,11 +5589,11 @@ slurp_hppa_unwind_table (FILE * file,
{
case 0:
aux->table[i].start.section = sym->st_shndx;
- aux->table[i].start.offset += sym->st_value + rp->r_addend;
+ aux->table[i].start.offset = sym->st_value + rp->r_addend;
break;
case 1:
aux->table[i].end.section = sym->st_shndx;
- aux->table[i].end.offset += sym->st_value + rp->r_addend;
+ aux->table[i].end.offset = sym->st_value + rp->r_addend;
break;
default:
break;