26 lines · plain
1// RUN: %clang %cflags -Wl,--defsym='__global_pointer$'=0x2800 -o %t %s2// RUN: llvm-bolt --print-cfg --print-only=_start -o %t.null %t \3// RUN: | FileCheck %s4 5 .data6 .globl d7 .p2align 38d:9 .dword 010 11 .text12 .globl _start13 .p2align 114// CHECK: Binary Function "_start" after building cfg {15_start:16 nop17 .option push18 .option norelax191:20// CHECK: auipc gp, %pcrel_hi(__global_pointer$) # Label: .Ltmp021// CHECK-NEXT: addi gp, gp, %pcrel_lo(.Ltmp0)22 auipc gp, %pcrel_hi(__global_pointer$)23 addi gp, gp, %pcrel_lo(1b)24 .option pop25 .size _start, .-_start26