mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2024-12-21 04:42:53 +08:00
a27e685fa0
This change, with prerequisite 0e5fabeb
, provides a toc base aligned
to 256 bytes rather than 8 bytes. This is necessary for a minor gcc
optimisation, allowing use of d-form instructions to correctly access
toc-relative items larger than 8 bytes.
bfd/
* elf64-ppc.c (TOC_BASE_ALIGN): Define.
(ppc64_elf_next_toc_section): Align multi-got toc base.
(ppc64_elf_set_toc): Likewise initial toc base and .TOC. symbol.
ld/
* emulparams/elf64ppc.sh (GOT): Align.
ld/testsuite/
* ld-powerpc/ambiguousv1b.d: Update for aligned .got.
* ld-powerpc/defsym.d: Likewise.
* ld-powerpc/elfv2-2exe.d: Likewise.
* ld-powerpc/elfv2exe.d: Likewise.
* ld-powerpc/elfv2so.d: Likewise.
* ld-powerpc/relbrlt.d: Likewise.
* ld-powerpc/tls.g: Likewise.
* ld-powerpc/tlsexe.d: Likewise.
* ld-powerpc/tlsexe.g: Likewise.
* ld-powerpc/tlsexe.r: Likewise.
* ld-powerpc/tlsexetoc.d: Likewise.
* ld-powerpc/tlsexetoc.g: Likewise.
* ld-powerpc/tlsexetoc.r: Likewise.
* ld-powerpc/tlsso.d: Likewise.
* ld-powerpc/tlsso.g: Likewise.
* ld-powerpc/tlsso.r: Likewise.
* ld-powerpc/tlstoc.g: Likewise.
* ld-powerpc/tlstocso.d: Likewise.
* ld-powerpc/tlstocso.g: Likewise.
* ld-powerpc/tlstocso.r: Likewise.
* ld-powerpc/tocopt.d: Likewise.
* ld-powerpc/tocopt2.d: Likewise.
* ld-powerpc/tocopt3.d: Likewise.
* ld-powerpc/tocopt4.d: Likewise.
* ld-powerpc/tocopt5.d: Likewise.
25 lines
674 B
Makefile
25 lines
674 B
Makefile
#source: startv1.s
|
|
#source: funref2.s
|
|
#as: -a64
|
|
#ld: -melf64ppc --emit-stub-syms
|
|
#ld_after_inputfiles: tmpdir/funv1.so
|
|
#readelf: -rs --wide
|
|
# Check that we do the right thing with funref2.s that doesn't have
|
|
# anything to mark it as ELFv1 or ELFv2. Since my_func address is
|
|
# taken in a read-only section we should get a copy reloc for the OPD
|
|
# entry.
|
|
|
|
Relocation section .* contains 1 entries:
|
|
.*
|
|
.* R_PPC64_COPY .* my_func \+ 0
|
|
|
|
Symbol table '\.dynsym' contains 5 entries:
|
|
.*
|
|
0: .*
|
|
1: 0+10010408 4 FUNC GLOBAL DEFAULT 12 my_func
|
|
#...
|
|
Symbol table '\.symtab' contains 20 entries:
|
|
#...
|
|
15: 0+10010408 4 FUNC GLOBAL DEFAULT 12 my_func
|
|
#pass
|