diff options
Diffstat (limited to 'ld/testsuite/ld-x86-64')
-rw-r--r-- | ld/testsuite/ld-x86-64/pr22115-1.s | 7 | ||||
-rw-r--r-- | ld/testsuite/ld-x86-64/pr22115-1a-x32.d | 13 | ||||
-rw-r--r-- | ld/testsuite/ld-x86-64/pr22115-1a.d | 13 | ||||
-rw-r--r-- | ld/testsuite/ld-x86-64/pr22115-1b-x32.d | 6 | ||||
-rw-r--r-- | ld/testsuite/ld-x86-64/pr22115-1b.d | 6 | ||||
-rw-r--r-- | ld/testsuite/ld-x86-64/pr22115-1c-x32.d | 13 | ||||
-rw-r--r-- | ld/testsuite/ld-x86-64/pr22115-1c.d | 13 | ||||
-rw-r--r-- | ld/testsuite/ld-x86-64/pr22115-1d-x32.d | 6 | ||||
-rw-r--r-- | ld/testsuite/ld-x86-64/pr22115-1d.d | 6 | ||||
-rw-r--r-- | ld/testsuite/ld-x86-64/x86-64.exp | 8 |
10 files changed, 91 insertions, 0 deletions
diff --git a/ld/testsuite/ld-x86-64/pr22115-1.s b/ld/testsuite/ld-x86-64/pr22115-1.s new file mode 100644 index 0000000..8c01e50 --- /dev/null +++ b/ld/testsuite/ld-x86-64/pr22115-1.s @@ -0,0 +1,7 @@ + .text + .globl _start + .type _start, @function +_start: + movq __ehdr_start@GOTPCREL(%rip), %rax + .size _start, .-_start + .weak __ehdr_start diff --git a/ld/testsuite/ld-x86-64/pr22115-1a-x32.d b/ld/testsuite/ld-x86-64/pr22115-1a-x32.d new file mode 100644 index 0000000..8232589 --- /dev/null +++ b/ld/testsuite/ld-x86-64/pr22115-1a-x32.d @@ -0,0 +1,13 @@ +#source: pr22115-1.s +#as: --x32 -mrelax-relocations=yes +#ld: -pie -z text -m elf32_x86_64 +#objdump: -dw + +.*: +file format .* + + +Disassembly of section .text: + +[a-f0-9]+ <_start>: + +[a-f0-9]+: 48 8d 05 ([0-9a-f]{2} ){4} * lea -?0x[a-f0-9]+\(%rip\),%rax # [a-f0-9]+ <__ehdr_start> +#pass diff --git a/ld/testsuite/ld-x86-64/pr22115-1a.d b/ld/testsuite/ld-x86-64/pr22115-1a.d new file mode 100644 index 0000000..43dc787 --- /dev/null +++ b/ld/testsuite/ld-x86-64/pr22115-1a.d @@ -0,0 +1,13 @@ +#source: pr22115-1.s +#as: --64 -mrelax-relocations=yes +#ld: -pie -z text -m elf_x86_64 +#objdump: -dw + +.*: +file format .* + + +Disassembly of section .text: + +[a-f0-9]+ <_start>: + +[a-f0-9]+: 48 8d 05 ([0-9a-f]{2} ){4} * lea -?0x[a-f0-9]+\(%rip\),%rax # [a-f0-9]+ <__ehdr_start> +#pass diff --git a/ld/testsuite/ld-x86-64/pr22115-1b-x32.d b/ld/testsuite/ld-x86-64/pr22115-1b-x32.d new file mode 100644 index 0000000..949dc5f --- /dev/null +++ b/ld/testsuite/ld-x86-64/pr22115-1b-x32.d @@ -0,0 +1,6 @@ +#source: pr22115-1.s +#as: --x32 -mrelax-relocations=yes +#ld: -pie -z text -m elf32_x86_64 +#readelf: -r + +There are no relocations in this file. diff --git a/ld/testsuite/ld-x86-64/pr22115-1b.d b/ld/testsuite/ld-x86-64/pr22115-1b.d new file mode 100644 index 0000000..f1aaf72 --- /dev/null +++ b/ld/testsuite/ld-x86-64/pr22115-1b.d @@ -0,0 +1,6 @@ +#source: pr22115-1.s +#as: --64 -mrelax-relocations=yes +#ld: -pie -z text -m elf_x86_64 +#readelf: -r + +There are no relocations in this file. diff --git a/ld/testsuite/ld-x86-64/pr22115-1c-x32.d b/ld/testsuite/ld-x86-64/pr22115-1c-x32.d new file mode 100644 index 0000000..384f8f4 --- /dev/null +++ b/ld/testsuite/ld-x86-64/pr22115-1c-x32.d @@ -0,0 +1,13 @@ +#source: pr22115-1.s +#as: --x32 -mrelax-relocations=yes +#ld: -pie -z text -m elf32_x86_64 --no-dynamic-linker +#objdump: -dw + +.*: +file format .* + + +Disassembly of section .text: + +[a-f0-9]+ <_start>: + +[a-f0-9]+: 48 8d 05 ([0-9a-f]{2} ){4} * lea -?0x[a-f0-9]+\(%rip\),%rax # [a-f0-9]+ <__ehdr_start> +#pass diff --git a/ld/testsuite/ld-x86-64/pr22115-1c.d b/ld/testsuite/ld-x86-64/pr22115-1c.d new file mode 100644 index 0000000..ac147f8 --- /dev/null +++ b/ld/testsuite/ld-x86-64/pr22115-1c.d @@ -0,0 +1,13 @@ +#source: pr22115-1.s +#as: --64 -mrelax-relocations=yes +#ld: -pie -z text -m elf_x86_64 --no-dynamic-linker +#objdump: -dw + +.*: +file format .* + + +Disassembly of section .text: + +[a-f0-9]+ <_start>: + +[a-f0-9]+: 48 8d 05 ([0-9a-f]{2} ){4} * lea -?0x[a-f0-9]+\(%rip\),%rax # [a-f0-9]+ <__ehdr_start> +#pass diff --git a/ld/testsuite/ld-x86-64/pr22115-1d-x32.d b/ld/testsuite/ld-x86-64/pr22115-1d-x32.d new file mode 100644 index 0000000..755c827 --- /dev/null +++ b/ld/testsuite/ld-x86-64/pr22115-1d-x32.d @@ -0,0 +1,6 @@ +#source: pr22115-1.s +#as: --x32 -mrelax-relocations=yes +#ld: -pie -z text -m elf32_x86_64 --no-dynamic-linker +#readelf: -r + +There are no relocations in this file. diff --git a/ld/testsuite/ld-x86-64/pr22115-1d.d b/ld/testsuite/ld-x86-64/pr22115-1d.d new file mode 100644 index 0000000..2cb1c65 --- /dev/null +++ b/ld/testsuite/ld-x86-64/pr22115-1d.d @@ -0,0 +1,6 @@ +#source: pr22115-1.s +#as: --64 -mrelax-relocations=yes +#ld: -pie -z text -m elf_x86_64 --no-dynamic-linker +#readelf: -r + +There are no relocations in this file. diff --git a/ld/testsuite/ld-x86-64/x86-64.exp b/ld/testsuite/ld-x86-64/x86-64.exp index 46b3ec7..edf8896 100644 --- a/ld/testsuite/ld-x86-64/x86-64.exp +++ b/ld/testsuite/ld-x86-64/x86-64.exp @@ -369,6 +369,14 @@ run_dump_test "property-x86-shstk5-x32" run_dump_test "pr21884" run_dump_test "pr21884-nacl" run_dump_test "pr22071" +run_dump_test "pr22115-1a" +run_dump_test "pr22115-1a-x32" +run_dump_test "pr22115-1b" +run_dump_test "pr22115-1b-x32" +run_dump_test "pr22115-1c" +run_dump_test "pr22115-1c-x32" +run_dump_test "pr22115-1d" +run_dump_test "pr22115-1d-x32" if { ![istarget "x86_64-*-linux*"] && ![istarget "x86_64-*-nacl*"]} { return |