1 ; RUN: llc -mtriple i686-windows-itanium -filetype asm -o - %s | FileCheck %s -check-prefix CHECK-ASM
2 ; RUN: llc -mtriple i686-windows-itanium -filetype obj -o - %s | llvm-readobj -r - | FileCheck %s -check-prefix CHECK-OBJ
4 @get_count_incremented.count = internal thread_local unnamed_addr global i32 0, align 4
6 define i32 @get_count_incremented() {
8 %0 = load i32, ptr @get_count_incremented.count, align 4
10 store i32 %inc, ptr @get_count_incremented.count, align 4
14 ; CHECK-ASM-LABEL: _get_count_incremented:
15 ; CHECK-ASM: movl __tls_index, %eax
16 ; CHECK-ASM: movl %fs:__tls_array, %ecx
17 ; CHECK-ASM: movl (%ecx,%eax,4), %ecx
18 ; CHECK-ASM: _get_count_incremented.count@SECREL32(%ecx), %eax
19 ; CHECK-ASM: incl %eax
20 ; CHECK-ASM: movl %eax, _get_count_incremented.count@SECREL32(%ecx)
23 ; CHECK-OBJ: Relocations [
24 ; CHECK-OBJ: Section ({{[0-9]+}}) .text {
25 ; CHECK-OBJ: 0x1 IMAGE_REL_I386_DIR32 __tls_index
26 ; CHECK-OBJ: 0x8 IMAGE_REL_I386_DIR32 __tls_array
27 ; CHECK-OBJ: 0x11 IMAGE_REL_I386_SECREL _get_count_incremented.count
28 ; CHECK-OBJ: 0x18 IMAGE_REL_I386_SECREL _get_count_incremented.count