aboutsummaryrefslogtreecommitdiff
path: root/ld/testsuite/ld-mips-elf
diff options
context:
space:
mode:
authorYunQiang Su <yunqiang.su@cipunited.com>2023-07-28 06:00:36 +0100
committerMaciej W. Rozycki <macro@orcam.me.uk>2023-07-28 06:00:36 +0100
commited4dca900c0dbc1317917cb289255d2f8d03f732 (patch)
tree2ab6dd4cf81b476ac020a3ad795ef3af49701c5f /ld/testsuite/ld-mips-elf
parentec76a6172f7b6d61f7d76c2bcf766122132116b8 (diff)
downloadfsf-binutils-gdb-ed4dca900c0dbc1317917cb289255d2f8d03f732.zip
fsf-binutils-gdb-ed4dca900c0dbc1317917cb289255d2f8d03f732.tar.gz
fsf-binutils-gdb-ed4dca900c0dbc1317917cb289255d2f8d03f732.tar.bz2
testsuite: Handle composed R_MIPS_NONE relocations
MIPS n64 ABI has a peculiarity where all relocations are composed of three, with subsequent relocation types set to R_MIPS_NONE if further calculation is not required. Example output produced by `readelf' and `objdump' for such relocations is: Offset Info Type Sym. Value Sym. Name + Addend 000000000000 000800000002 R_MIPS_32 0000000000000000 foo + 0 Type2: R_MIPS_NONE Type3: R_MIPS_NONE and: OFFSET TYPE VALUE 0000000000000000 R_MIPS_32 foo 0000000000000000 R_MIPS_NONE *ABS* 0000000000000000 R_MIPS_NONE *ABS* respectively. The presence of these extra R_MIPS_NONE entries is not relevant for generic or even some MIPS tests, so optionally match them with the respective dump patterns, also discarding `xfail' annotation for MIPS/OpenBSD targets from gas/elf/missing-build-notes.d, removing these regressions: mips64-openbsd -FAIL: readelf -r bintest mips64-openbsd -FAIL: forward expression mips64-openbsd -FAIL: assignment tests mips64-openbsd -FAIL: gas/all/none mips64-openbsd -XFAIL: gas/elf/missing-build-notes mips64-openbsd -FAIL: macro test 2 mips64-openbsd -FAIL: macro irp mips64-openbsd -FAIL: macro rept mips64-openbsd -FAIL: nested irp/irpc/rept mips64-openbsd -FAIL: macro vararg mips64-openbsd -FAIL: mips jalx mips64-openbsd -FAIL: ST Microelectronics Loongson-2F workarounds of Jump Instruction issue mips64el-openbsd -FAIL: readelf -r bintest mips64el-openbsd -FAIL: forward expression mips64el-openbsd -FAIL: assignment tests mips64el-openbsd -FAIL: gas/all/none mips64el-openbsd -XFAIL: gas/elf/missing-build-notes mips64el-openbsd -FAIL: macro test 2 mips64el-openbsd -FAIL: macro irp mips64el-openbsd -FAIL: macro rept mips64el-openbsd -FAIL: nested irp/irpc/rept mips64el-openbsd -FAIL: macro vararg mips64el-openbsd -FAIL: mips jalx mips64el-openbsd -FAIL: ST Microelectronics Loongson-2F workarounds of Jump Instruction issue Co-Authored-By: Maciej W. Rozycki <macro@orcam.me.uk> binutils/ * testsuite/binutils-all/readelf.r-64: Optionally match extra R_MIPS_NONE pairs. gas/ * testsuite/gas/all/assign.d: Optionally match extra R_MIPS_NONE pairs. * testsuite/gas/all/fwdexp.d: Likewise. * testsuite/gas/all/none.d: Likewise. * testsuite/gas/macros/irp.d: Likewise. * testsuite/gas/macros/repeat.d: Likewise. * testsuite/gas/macros/rept.d: Likewise. * testsuite/gas/macros/test2.d: Likewise. * testsuite/gas/macros/vararg.d: Likewise. * testsuite/gas/mips/compact-eh-eb-1.d: Likewise. * testsuite/gas/mips/compact-eh-eb-2.d: Likewise. * testsuite/gas/mips/compact-eh-eb-3.d: Likewise. * testsuite/gas/mips/compact-eh-eb-4.d: Likewise. * testsuite/gas/mips/compact-eh-eb-5.d: Likewise. * testsuite/gas/mips/compact-eh-eb-6.d: Likewise. * testsuite/gas/mips/compact-eh-el-1.d: Likewise. * testsuite/gas/mips/compact-eh-el-2.d: Likewise. * testsuite/gas/mips/compact-eh-el-3.d: Likewise. * testsuite/gas/mips/compact-eh-el-4.d: Likewise. * testsuite/gas/mips/compact-eh-el-5.d: Likewise. * testsuite/gas/mips/compact-eh-el-6.d: Likewise. * testsuite/gas/mips/loongson-2f-3.d: Likewise. * testsuite/gas/mips/mips-jalx.d: Likewise. * testsuite/gas/elf/missing-build-notes.d: Likewise. Remove the `xfail' tag. ld/ * testsuite/ld-mips-elf/reloc-estimate-1.d: Optionally match extra R_MIPS_NONE pairs.
Diffstat (limited to 'ld/testsuite/ld-mips-elf')
-rw-r--r--ld/testsuite/ld-mips-elf/reloc-estimate-1.d4
1 files changed, 4 insertions, 0 deletions
diff --git a/ld/testsuite/ld-mips-elf/reloc-estimate-1.d b/ld/testsuite/ld-mips-elf/reloc-estimate-1.d
index fa536f9..65094cf 100644
--- a/ld/testsuite/ld-mips-elf/reloc-estimate-1.d
+++ b/ld/testsuite/ld-mips-elf/reloc-estimate-1.d
@@ -9,7 +9,11 @@
DYNAMIC RELOCATION RECORDS
OFFSET +TYPE +VALUE
0+000000 R_MIPS_NONE \*ABS\*
+#?.*R_MIPS_NONE.*
+#?.*R_MIPS_NONE.*
0+010000 R_MIPS_REL32 foo@@V2
+#?.*R_MIPS_NONE.*
+#?.*R_MIPS_NONE.*
# The address must be 0x810. We should only ever allocate one dynamic