Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / llvm / test / MC / CSKY / tls_ld.s
blobb0a026f0e75702b3f60b9304acf2160a6054a8cc
1 # RUN: llvm-mc -filetype=obj -triple=csky -mattr=+2e3 < %s \
2 # RUN: | llvm-objdump --mattr=+2e3 --no-show-raw-insn -M no-aliases -d -r - | FileCheck %s
4 .LTLS0:
5 lrw16 r0, xxx@TLSLDM32
6 grs32 r2, .LTLS0
7 addu16 r0, r0, r2
8 lrw16 r3, __tls_get_addr@PLT
9 ldr32.w r3, (rgb, r3 << 0)
10 jsr16 r3
11 lrw16 r3, xxx@TLSLDO32
12 str32.w r4, (r0, r3 << 0)
14 # CHECK: 0: lrw16 r0, 0x18
15 # CHECK-NEXT: 2: grs32 r2, 0x0
16 # CHECK-NEXT: 6: addu16 r0, r0, r2
17 # CHECK-NEXT: 8: lrw16 r3, 0x1c
18 # CHECK-NEXT: a: ldr32.w r3, (r28, r3 << 0)
19 # CHECK-NEXT: e: jsr16 r3
20 # CHECK-NEXT: 10: lrw16 r3, 0x20
21 # CHECK-NEXT: 12: str32.w r4, (r0, r3 << 0)
22 # CHECK-NEXT: 16: bkpt
24 # CHECK: 18: 00 00 00 00 .word 0x00000000
25 # CHECK-NEXT: 00000018: R_CKCORE_TLS_LDM32 xxx+0x18
26 # CHECK-NEXT: 1c: 00 00 00 00 .word 0x00000000
27 # CHECK-NEXT: 0000001c: R_CKCORE_PLT32 __tls_get_addr
28 # CHECK-NEXT: 20: 00 00 00 00 .word 0x00000000
29 # CHECK-NEXT: 00000020: R_CKCORE_TLS_LDO32 xxx