2 # RUN: split-file %s %t
3 # RUN: llvm-mc -filetype=obj -triple=powerpc64le %t/initexec -o %t/initexec.o
4 # RUN: llvm-mc -filetype=obj -triple=powerpc64le %t/defs -o %t/defs.o
5 # RUN: ld.lld %t/initexec.o %t/defs.o -o %t/out
6 # RUN: llvm-objdump -d --no-show-raw-insn %t/out | FileCheck %s
8 # CHECK-LABEL: <GetAddrT>:
10 # CHECK-NEXT: std 30, -16(1)
11 # CHECK-NEXT: std 0, 16(1)
12 # CHECK-NEXT: stdu 1, -48(1)
13 # CHECK-NEXT: paddi 3, 13, -28672, 0
14 # CHECK-NEXT: mr 30, 3
15 # CHECK-NEXT: mr 3, 30
17 # CHECK-NEXT: mr 4, 30
18 # CHECK-NEXT: addi 1, 1, 48
19 # CHECK-NEXT: ld 0, 16(1)
20 # CHECK-NEXT: ld 30, -16(1)
25 ## extern __thread unsigned TGlobal;
26 ## unsigned getConst(unsigned*);
27 ## unsigned addVal(unsigned, unsigned*);
29 ## unsigned GetAddrT() {
30 ## return addVal(getConst(&TGlobal), &TGlobal);
39 pld
3, TGlobal@got@tprel@pcrel
(0), 1
40 add 30, 3, TGlobal@tls@pcrel
51 ## __thread unsigned TGlobal;
53 ## unsigned getConst(unsigned* A) {
57 ## unsigned addVal(unsigned A, unsigned* B) {
76 .section .tbss,"awT",@nobits