diff options
author | H.J. Lu <hjl.tools@gmail.com> | 2024-01-06 06:43:04 -0800 |
---|---|---|
committer | H.J. Lu <hjl.tools@gmail.com> | 2024-01-06 07:10:15 -0800 |
commit | c9eb960580aa906d6f792cf842d4ef60c98e1320 (patch) | |
tree | 19f7e9a14d476275841e9c21838877a69f82b27a /ld/testsuite/ld-elf | |
parent | a2c02fa6ee6a5b01f516e340f3e3855fee7e0834 (diff) | |
download | gdb-c9eb960580aa906d6f792cf842d4ef60c98e1320.zip gdb-c9eb960580aa906d6f792cf842d4ef60c98e1320.tar.gz gdb-c9eb960580aa906d6f792cf842d4ef60c98e1320.tar.bz2 |
ld: Adjust x86 and x86-64 tests for -z mark-plt
To support -z mark-plt enabled by default, adjust x86 tests to accept
non-zero r_addend for JUMP_SLOT relocation and pass -z nomark-plt to
x86-64 tests if -z mark-plt changes the expected outputs.
* testsuite/ld-elf/indirect-extern-access-2.rd: Allow non-zero
r_addend for JUMP_SLOT relocation.
* testsuite/ld-elf/pr23161d.rd: Likewise.
* testsuite/ld-ifunc/ifunc-25c-x86.d: Likewise.
* testsuite/ld-ifunc/ifunc-16-x86-64-now.d: Pass -z nomark-plt
to linker.
* testsuite/ld-ifunc/ifunc-16-x86-64.d: Likewise.
* testsuite/ld-ifunc/ifunc-2-local-x86-64-now.d: Likewise.
* testsuite/ld-ifunc/ifunc-2-local-x86-64.d: Likewise.
* testsuite/ld-ifunc/ifunc-2-x86-64-now.d: Likewise.
* testsuite/ld-ifunc/ifunc-2-x86-64.d: Likewise.
* testsuite/ld-ifunc/ifunc-20-x86-64.d: Likewise.
* testsuite/ld-ifunc/ifunc-5b-x86-64.d: Likewise.
* testsuite/ld-ifunc/pr17154-x86-64-now.d: Likewise.
* testsuite/ld-ifunc/pr17154-x86-64.d: Likewise.
* testsuite/ld-x86-64/dt-relr-1a-x32.d: Likewise.
* testsuite/ld-x86-64/dt-relr-1a.d: Likewise.
* testsuite/ld-x86-64/dt-relr-1b-x32.d: Likewise.
* testsuite/ld-x86-64/dt-relr-1b.d: Likewise.
* testsuite/ld-x86-64/ibt-plt-2a-x32.d: Likewise.
* testsuite/ld-x86-64/ibt-plt-2a.d: Likewise.
* testsuite/ld-x86-64/ibt-plt-3a-x32.d: Likewise.
* testsuite/ld-x86-64/ibt-plt-3a.d: Likewise.
* testsuite/ld-x86-64/pr19636-2d.d: Likewise.
* testsuite/ld-x86-64/pr19636-2e.d: Likewise.
* testsuite/ld-x86-64/pr19636-2f.d: Likewise.
* testsuite/ld-x86-64/pr19636-2l.d: Likewise.
* testsuite/ld-x86-64/x86-64.exp: Pass -z nomark-plt to linker
in 6 tests.
Diffstat (limited to 'ld/testsuite/ld-elf')
-rw-r--r-- | ld/testsuite/ld-elf/indirect-extern-access-2.rd | 2 | ||||
-rw-r--r-- | ld/testsuite/ld-elf/pr23161d.rd | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/ld/testsuite/ld-elf/indirect-extern-access-2.rd b/ld/testsuite/ld-elf/indirect-extern-access-2.rd index 9c7d72f..89c9e2e 100644 --- a/ld/testsuite/ld-elf/indirect-extern-access-2.rd +++ b/ld/testsuite/ld-elf/indirect-extern-access-2.rd @@ -1,5 +1,5 @@ #... -[a-f0-9]+ +[0-9a-f]+ +R_.*_JUMP_SLO(T|) +[a-f0-9]+ +indirect_extern_access( \+ 0|) +[a-f0-9]+ +[0-9a-f]+ +R_.*_JUMP_SLO(T|) +[a-f0-9]+ +indirect_extern_access( \+ [a-f0-9]+|) #... Displaying notes found in: .note.gnu.property [ ]+Owner[ ]+Data size[ ]+Description diff --git a/ld/testsuite/ld-elf/pr23161d.rd b/ld/testsuite/ld-elf/pr23161d.rd index 338cfad..e7756b3 100644 --- a/ld/testsuite/ld-elf/pr23161d.rd +++ b/ld/testsuite/ld-elf/pr23161d.rd @@ -1,6 +1,6 @@ Relocation section '\.rel(a|)\.plt' at offset 0x[0-9a-f]+ contains 1 entry: +Offset +Info +Type +Sym.* Value +Sym.* Name( \+ Addend|) -[a-f0-9]+ +[0-9a-f]+ +R_.*_JUMP_SLOT +[a-f0-9]+ +foo( \+ 0|) +[a-f0-9]+ +[0-9a-f]+ +R_.*_JUMP_SLOT +[a-f0-9]+ +foo( \+ [a-f0-9]+|) Symbol table '\.dynsym' contains [0-9]+ entries: +Num: +Value +Size Type +Bind +Vis +Ndx Name |