llvm-project/llvm/test/CodeGen/PowerPC/aix-xcoff-tls-rename.ll
esmeyi dfe55cc1cd [AIX] use the original name as the input to create the new symbol for TLS symbol.
Summary: Currently, an error was reported when a thread local symbol has an invalid name. D100956 create a new symbol to prefix the TLS symbol name with a dot. When the symbol name is renamed, the error occurs. This patch uses the original symbol name (name in the symbol table) as the input for the symbol for TOC entry.

Reviewed By: shchenz, lkail

Differential Revision: https://reviews.llvm.org/D132348
2022-08-24 01:36:40 -04:00

16 lines
483 B
LLVM

; RUN: llc -verify-machineinstrs -mtriple powerpc64-ibm-aix-xcoff -mcpu=pwr4 \
; RUN: -mattr=-altivec -data-sections=false -xcoff-traceback-table=false < %s | FileCheck %s
; CHECK: .extern .__tls_get_addr[PR]
; CHECK-NEXT: .csect .tdata[TL],2
; CHECK-NEXT: .globl _Renamed..24f_f # @"f$f"
; CHECK-NEXT: .rename _Renamed..24f_f,"f$f"
@"f$f" = thread_local global i32 10, align 4
define void @fun() {
entry:
store i32 1, ptr @"f$f", align 4
ret void
}