aboutsummaryrefslogtreecommitdiff
path: root/bfd
diff options
context:
space:
mode:
authorJeff Law <law@redhat.com>1995-06-17 15:43:06 +0000
committerJeff Law <law@redhat.com>1995-06-17 15:43:06 +0000
commit9a6880571c8a7f48a01b0502574712e75864dd49 (patch)
tree2190d313170808a99bc24a06df5889f44e8d2815 /bfd
parent018dafca8a6af00b7d6c06de0db0c211811849d3 (diff)
downloadgdb-9a6880571c8a7f48a01b0502574712e75864dd49.zip
gdb-9a6880571c8a7f48a01b0502574712e75864dd49.tar.gz
gdb-9a6880571c8a7f48a01b0502574712e75864dd49.tar.bz2
* elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Don't mess
with the operands of an R_PARISC_DPREL21L relocation if the insn is not "addil <symbol>,%r27".
Diffstat (limited to 'bfd')
-rw-r--r--bfd/ChangeLog6
-rw-r--r--bfd/elf32-hppa.c8
2 files changed, 12 insertions, 2 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index 2426427..d9aa3e0 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,9 @@
+Sat Jun 17 09:40:44 1995 Jeff Law (law@snake.cs.utah.edu)
+
+ * elf32-hppa.c (elf32_hppa_bfd_final_link_relocate): Don't mess
+ with the operands of an R_PARISC_DPREL21L relocation if the insn
+ is not "addil <symbol>,%r27".
+
Fri Jun 16 15:04:47 1995 Stan Shebs <shebs@andros.cygnus.com>
* bfd-in.h (NT_subsystem, NT_stack_heap): Declare but don't
diff --git a/bfd/elf32-hppa.c b/bfd/elf32-hppa.c
index e74db34..d66679f 100644
--- a/bfd/elf32-hppa.c
+++ b/bfd/elf32-hppa.c
@@ -1300,11 +1300,15 @@ elf32_hppa_bfd_final_link_relocate (howto, input_bfd, output_bfd,
section. If it's a code section, then "data pointer relative" makes
no sense. In that case we don't adjust the "value", and for 21 bit
addil instructions, we change the source addend register from %dp to
- %r0. */
+ %r0.
case R_PARISC_DPREL21L:
r_field = e_lrsel;
if (sym_sec->flags & SEC_CODE)
- insn &= ~0x03e00000;
+ {
+ if ((insn & 0xfc) >> 26 == 0xa
+ && (insn & 0x03e00000) >> 21 == 0x1b)
+ insn &= ~0x03e00000;
+ }
else
value -= elf32_hppa_hash_table (info)->global_value;
goto do_basic_type_1;