ef2b5578f6
* gas/mips/mips.exp: Set has_newabi for mips*-sde-elf* too. * gas/mips/elf-rel-got-n32.s: Adjust padding. * gas/mips/elf-rel-got-n64.s: Likewise. * gas/mips/elf-rel23.s: Likewise. * gas/mips/elf-rel28.s: Likewise. * gas/mips/n32-consec.s: Likewise. * gas/mips/elf-rel-xgot-n32.d: Adjust output expected. * gas/mips/elf-rel-xgot-n64.d: Likewise. * gas/mips/elf-rel23.d: Likewise. * gas/mips/elf-rel23a.d: Likewise. * gas/mips/elf-rel23b.d: Likewise. * gas/mips/elf-rel28-n32.d: Likewise. ld/testsuite/ * lib/ld-lib.exp (run_dump_test): Implement the EXTRA_OPTIONS argument and the "dump" keyword. * ld-mips-elf/emit-relocs-1a.s: Make section alignment uniform across targets. * ld-mips-elf/emit-relocs-1b.s: Likewise. * ld-mips-elf/jalbal.s: Adjust padding. * ld-mips-elf/elf-rel-got-n32-embed.d: New test. * ld-mips-elf/elf-rel-got-n64-embed.d: New test. * ld-mips-elf/elf-rel-xgot-n32-embed.d: New test. * ld-mips-elf/elf-rel-xgot-n64-embed.d: New test. * ld-mips-elf/elf-rel-got-n32.d: Remove -melf32btsmipn32. * ld-mips-elf/elf-rel-got-n64.d: Remove -melf64btsmip. Adjust output. * ld-mips-elf/elf-rel-got-n64-linux.d: Remove -melf64btsmip. * ld-mips-elf/elf-rel-xgot-n32.d: Remove -melf32btsmipn32. Adjust output. * ld-mips-elf/elf-rel-xgot-n64.d: Remove -melf64btsmip. Adjust output. * ld-mips-elf/elf-rel-xgot-n64-linux.d: Likewise. * ld-mips-elf/reloc-1-n64.d: Remove -melf64btsmip. * ld-mips-elf/mips-elf.exp: Set has_newabi for mips*-sde-elf* too. Move tool flags from o32_as_flags and o32_ld_flags variables into abi_asflags and abi_ldflags arrays. Adjust test cases run to use them. Run the new tests.
459 lines
9.3 KiB
Makefile
459 lines
9.3 KiB
Makefile
#source: reloc-1a.s -mabi=64 -EB
|
|
#source: reloc-1b.s -mabi=64 -EB
|
|
#ld: -r
|
|
#readelf: --relocs
|
|
|
|
Relocation section '\.rela\.text' .*
|
|
.*
|
|
#
|
|
# Relocations against tstarta
|
|
#
|
|
.* R_MIPS_HI16 .* \.text \- 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \- 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* \.text \- 8000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \- 8000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* \.text \+ 0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* \.text \+ 7ff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 7ff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* \.text \+ 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against t32a
|
|
#
|
|
.* R_MIPS_HI16 .* \.text \- 7ff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \- 7ff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* \.text \- 7fe0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \- 7fe0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* \.text \+ 20
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 20
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* \.text \+ 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* \.text \+ 8030
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 8030
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against _start
|
|
#
|
|
.* R_MIPS_HI16 .* _start \- 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* _start \- 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* _start \- 8000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* _start \- 8000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* _start \+ 0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* _start \+ 0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* _start \+ 7ff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* _start \+ 7ff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* _start \+ 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* _start \+ 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against tstarta
|
|
#
|
|
.* R_MIPS_GOT16 .* \.text \- 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \- 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GOT16 .* \.text \- 8000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \- 8000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GOT16 .* \.text \+ 0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GOT16 .* \.text \+ 7ff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 7ff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GOT16 .* \.text \+ 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against t32a
|
|
#
|
|
.* R_MIPS_GOT16 .* \.text \- 7ff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \- 7ff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GOT16 .* \.text \- 7fe0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \- 7fe0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GOT16 .* \.text \+ 20
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 20
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GOT16 .* \.text \+ 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GOT16 .* \.text \+ 8030
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 8030
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against sdg
|
|
#
|
|
.* R_MIPS_GPREL16 .* sdg \- 4
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GPREL16 .* sdg \+ 0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GPREL16 .* sdg \+ 4
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against sdla. .sdata should be the first piece of gp-relative
|
|
# data, which the linker script should put _gp - 0x7ff0.
|
|
#
|
|
.* R_MIPS_GPREL16 .* \.sdata \- 7fe4
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GPREL16 .* \.sdata \- 7fe0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GPREL16 .* \.sdata \- 7fdc
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against tstarta
|
|
#
|
|
.* R_MIPS_26 .* \.text \- 4
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_26 .* \.text \+ 0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_26 .* \.text \+ 4
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against t32a
|
|
#
|
|
.* R_MIPS_26 .* \.text \+ 1c
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_26 .* \.text \+ 20
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_26 .* \.text \+ 24
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against _start
|
|
#
|
|
.* R_MIPS_26 .* _start \- 4
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_26 .* _start \+ 0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_26 .* _start \+ 4
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against tstartb
|
|
#
|
|
.* R_MIPS_HI16 .* \.text \+ 7fe0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 7fe0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* \.text \+ 7ff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 7ff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* \.text \+ fff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ fff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* \.text \+ 17fe0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 17fe0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* \.text \+ 18000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 18000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against t32b
|
|
#
|
|
.* R_MIPS_HI16 .* \.text \+ 8000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 8000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* \.text \+ 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* \.text \+ 10010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 10010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* \.text \+ 18000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 18000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* \.text \+ 18020
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 18020
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against _start
|
|
#
|
|
.* R_MIPS_HI16 .* _start \- 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* _start \- 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* _start \- 8000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* _start \- 8000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* _start \+ 0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* _start \+ 0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* _start \+ 7ff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* _start \+ 7ff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_HI16 .* _start \+ 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* _start \+ 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against tstartb
|
|
#
|
|
.* R_MIPS_GOT16 .* \.text \+ 7fe0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 7fe0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GOT16 .* \.text \+ 7ff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 7ff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GOT16 .* \.text \+ fff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ fff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GOT16 .* \.text \+ 17fe0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 17fe0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GOT16 .* \.text \+ 18000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 18000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against t32b
|
|
#
|
|
.* R_MIPS_GOT16 .* \.text \+ 8000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 8000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GOT16 .* \.text \+ 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 8010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GOT16 .* \.text \+ 10010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 10010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GOT16 .* \.text \+ 18000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 18000
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GOT16 .* \.text \+ 18020
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_LO16 .* \.text \+ 18020
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against sdg
|
|
#
|
|
.* R_MIPS_GPREL16 .* sdg \- 4
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GPREL16 .* sdg \+ 0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GPREL16 .* sdg \+ 4
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against sdlb
|
|
#
|
|
.* R_MIPS_GPREL16 .* \.sdata \- 7fc4
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GPREL16 .* \.sdata \- 7fc0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_GPREL16 .* \.sdata \- 7fbc
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against tstartb
|
|
#
|
|
.* R_MIPS_26 .* \.text \+ ffec
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_26 .* \.text \+ fff0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_26 .* \.text \+ fff4
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against t32b
|
|
#
|
|
.* R_MIPS_26 .* \.text \+ 1000c
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_26 .* \.text \+ 10010
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_26 .* \.text \+ 10014
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#
|
|
# Relocations against _start
|
|
#
|
|
.* R_MIPS_26 .* _start \- 4
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_26 .* _start \+ 0
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_26 .* _start \+ 4
|
|
.* R_MIPS_NONE *
|
|
.* R_MIPS_NONE *
|
|
#pass
|