Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / bolt / test / RISCV / reloc-abs.s
blob5b728f092b3c9f587d063db38f85cda7605b0866
1 // RUN: %clang %cflags -Wl,--defsym='__global_pointer$'=0x2800 -o %t %s
2 // RUN: llvm-bolt --print-cfg --print-only=_start -o /dev/null %t \
3 // RUN: | FileCheck %s
5 .data
6 .globl d
7 .p2align 3
8 d:
9 .dword 0
11 .text
12 .globl _start
13 .p2align 1
14 // CHECK: Binary Function "_start" after building cfg {
15 _start:
16 nop
17 .option push
18 .option norelax
20 // CHECK: auipc gp, %pcrel_hi(__global_pointer$) # Label: .Ltmp0
21 // CHECK-NEXT: addi gp, gp, %pcrel_lo(.Ltmp0)
22 auipc gp, %pcrel_hi(__global_pointer$)
23 addi gp, gp, %pcrel_lo(1b)
24 .option pop
25 .size _start, .-_start