[memprof] Remove an unused using directive (#117004)
[llvm-project.git] / lld / test / ELF / mips-64.s
blobebfad068b572465fe52b8ef88ccc890eb529b048
1 # REQUIRES: mips
2 # Check R_MIPS_64 relocation calculation.
4 # RUN: llvm-mc -filetype=obj -triple=mips64-unknown-linux %s -o %t-be.o
5 # RUN: ld.lld -shared %t-be.o -o %t-be.so
6 # RUN: llvm-objdump -s -t %t-be.so | FileCheck --check-prefixes=SYM,SYM-BE %s
7 # RUN: llvm-readelf --dynamic-table -r -s -A %t-be.so | FileCheck %s
9 # RUN: llvm-mc -filetype=obj -triple=mips64el-unknown-linux %s -o %t-el.o
10 # RUN: ld.lld -shared %t-el.o -o %t-el.so
11 # RUN: llvm-objdump -s -t %t-el.so | FileCheck --check-prefixes=SYM,SYM-EL %s
12 # RUN: llvm-readelf --dynamic-table -r -s -A %t-el.so | FileCheck %s
14 .data
15 .globl v2
16 v1:
17 .quad v2+8 # R_MIPS_64 target v2 addend 8
18 v2:
19 .quad v1 # R_MIPS_64 target v1 addend 0
21 # SYM: SYMBOL TABLE:
22 # SYM: 00000000000203b0 l .data 0000000000000000 v1
24 # SYM-BE: Contents of section .data:
25 # SYM-BE-NEXT: {{.*}} 00000000 00000008 00000000 000203b0
27 # SYM-EL: Contents of section .data:
28 # SYM-EL-NEXT: {{.*}} 08000000 00000000 b0030200 00000000
30 # CHECK: Dynamic section
31 # CHECK: (RELSZ) 32 (bytes)
32 # CHECK: (RELENT) 16 (bytes)
34 # CHECK: Relocation section
35 # CHECK: [[V1:[0-9a-f]+]] {{.*}} R_MIPS_REL32/R_MIPS_64/R_MIPS_NONE [[V2:[0-9a-f]+]] v2
36 # CHECK-NEXT: [[V2]] {{.*}} R_MIPS_REL32/R_MIPS_64/R_MIPS_NONE {{$}}
38 # CHECK: Symbol table '.symtab'
39 # CHECK: {{.*}}: [[V1]] {{.*}} v1
40 # CHECK: {{.*}}: [[V2]] {{.*}} v2
42 # CHECK: Primary GOT:
43 # CHECK: Global entries:
44 # CHECK: {{.*}} -32736(gp) [[V2]] [[V2]] {{.*}} v2