brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.0 KiB · 353e34b Raw
31 lines · plain
1// REQUIRES: arm2// RUN: llvm-mc -filetype=obj -triple=armv7a-none-linux-gnueabi %p/Inputs/arm-tls-get-addr.s -o %t1.o3// RUN: ld.lld %t1.o --shared -soname=t1.so -o %t1.so4// RUN: llvm-mc %s -o %t.o -filetype=obj -triple=armv7a-linux-gnueabi5// RUN: ld.lld %t1.so %t.o -o %t6// RUN: llvm-readobj -S --dyn-relocations %t | FileCheck %s7 8/// This tls global-dynamic sequence is with respect to a preemptible symbol but9/// is in an application so a relaxation to Initial Exec would normally be10/// possible. This would result in an assertion failure on ARM as the11/// relaxation functions can't be implemented on ARM. Check that the sequence12/// is handled as global dynamic13 14 .text15 .syntax unified16 .globl  func17 .p2align        218 .type   func,%function19func:20.L0:21 .globl __tls_get_addr22 bl __tls_get_addr23 bx lr24 .p2align 225 .Lt0: .word   y(TLSGD) + (. - .L0 - 8)26 27// CHECK: Dynamic Relocations {28// CHECK-NEXT:   0x30290 R_ARM_TLS_DTPMOD32 y29// CHECK-NEXT:   0x30294 R_ARM_TLS_DTPOFF32 y30// CHECK-NEXT:   0x402A4 R_ARM_JUMP_SLOT __tls_get_addr31