]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - ld/testsuite/ld-aarch64/emit-relocs-morello-6.d
d97a59a916bda27854933362ba00afa174bb6886
[thirdparty/binutils-gdb.git] / ld / testsuite / ld-aarch64 / emit-relocs-morello-6.d
1 # Check handling relocations into the got that require a GOT entry.
2 # This case handles PIE binaries.
3 #
4 # This testcase uses exact values in order to check that of the two GOT entries
5 # created, the one that is referenced by the first instruction in _start is
6 # the one which has the LSB set in its value.
7 #
8 # It's difficult to check this in the DejaGNU testsuite without checking for
9 # specific values that we know are good. However this is susceptible to
10 # defaults changing where the .text and .got sections end up.
11 #
12 # If this testcase prooves to be too flaky while the linker gets updated then
13 # we should look harder for some solution, but for now we'll take this
14 # tradeoff.
15 #source: emit-relocs-morello-6.s
16 #as: -march=morello+c64
17 #ld: -Ttext-segment 0x0 -pie -static
18 #objdump: -DR -j .got -j .text
19
20
21 .*: file format .*
22
23
24 Disassembly of section \.text:
25
26 00000000000001e8 <_start>:
27 1e8: c240c400 ldr c0, \[c0, #784\]
28 1ec: c240c000 ldr c0, \[c0, #768\]
29
30 Disassembly of section \.got:
31
32 00000000000102f0 <\.got>:
33 102f0: 000101f0 \.inst 0x000101f0 ; undefined
34 \.\.\.
35 10300: 000001e8 udf #488
36 10300: R_MORELLO_RELATIVE \*ABS\*
37 10304: 00000000 udf #0
38 10308: .*
39 1030c: .*
40 10310: 000001e9 udf #489
41 10310: R_MORELLO_RELATIVE \*ABS\*
42 10314: .*
43 10318: .*
44 1031c: .*