36 lines · plain
1# REQUIRES: ppc2# RUN: llvm-mc -filetype=obj -triple=ppc64le %s -o %t.o3# RUN: ld.lld %t.o -shared -o %t.so4# RUN: llvm-objdump -d --no-show-raw-insn %t.so | FileCheck %s5# RUN: llvm-nm %t.so | FileCheck --check-prefix=NM %s6# RUN: llvm-readelf -x .rodata %t.so | FileCheck --check-prefix=RODATA %s7 8# 0x2a - 0x8000 = -327269# CHECK: addis 4, 3, 010# CHECK-NEXT: addi 4, 4, -3272611# CHECK-NEXT: lis 5, 012# CHECK-NEXT: ori 5, 5, 013 14# NM: 000000000000002a B i15# RODATA: 2a000000 0000000016 17# We used to error on R_PPC64_DTPREL* to preemptable symbols.18# i is STB_GLOBAL and preemptable.19.globl foo20foo:21 addis 4, 3, i@dtprel@ha # R_PPC64_DTPREL16_HA22 addi 4, 4, i@dtprel@l # R_PPC64_DTPREL16_LO23 24 lis 5, i@dtprel@highesta # R_PPC64_DTPREL16_HIGHESTA25 ori 5, 5, i@dtprel@highera # R_PPC64_DTPREL16_HIGHERA26 27.section .rodata,"a",@progbits28 .quad i@dtprel+3276829 30.section .tbss,"awT",@nobits31 .space 0x2a32.globl i33i:34 .long 035 .size i, 436