Fix an opd->append index in elf64-ppc.c
authorRichard Sandiford <rdsandiford@googlemail.com>
Sun, 5 Jul 2015 18:56:59 +0000 (19:56 +0100)
committerRichard Sandiford <rdsandiford@googlemail.com>
Sun, 5 Jul 2015 18:57:07 +0000 (19:57 +0100)
commit92a9c616e496f41c3d1da949078d5739add79161
tree5243661e65ba554184d6e44791a91b09ed96237b
parent533edc14b87398bbf4cbf3083bd6deaa5b89d5ab
Fix an opd->append index in elf64-ppc.c

bfd/
* elf64-ppc.c (toc_adjusting_stub_needed): Use the symbol value
plus addend rather than the original st_value when looking up
entries in opd->adjust.

ld/testsuite/
* ld-powerpc/tocopt6-inc.s, ld-powerpc/tocopt6a.s,
ld-powerpc/tocopt6b.s, ld-powerpc/tocopt6c.s,
ld-powerpc/tocopt6.d: New test.
* ld-powerpc/powerpc.exp (ppc64elftests): Add it.
bfd/ChangeLog
bfd/elf64-ppc.c
ld/testsuite/ChangeLog
ld/testsuite/ld-powerpc/powerpc.exp
ld/testsuite/ld-powerpc/tocopt6-inc.s [new file with mode: 0644]
ld/testsuite/ld-powerpc/tocopt6.d [new file with mode: 0644]
ld/testsuite/ld-powerpc/tocopt6a.s [new file with mode: 0644]
ld/testsuite/ld-powerpc/tocopt6b.s [new file with mode: 0644]
ld/testsuite/ld-powerpc/tocopt6c.s [new file with mode: 0644]