diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2017-12-18 20:12:21 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2017-12-18 20:12:21 +0000 |
commit | eb1ff93d02b5f17b6b409e83c6d9be585f4a04b3 (patch) | |
tree | 7490b4a8943293f251ad733465936e6ec302b3e9 /test/COFF/lto-reloc-model.ll | |
parent | bafea25f368c63f0b39789906adfed6e39219e64 (diff) |
Notes
Diffstat (limited to 'test/COFF/lto-reloc-model.ll')
-rw-r--r-- | test/COFF/lto-reloc-model.ll | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/test/COFF/lto-reloc-model.ll b/test/COFF/lto-reloc-model.ll new file mode 100644 index 0000000000000..bea19e9ce3e9e --- /dev/null +++ b/test/COFF/lto-reloc-model.ll @@ -0,0 +1,19 @@ +; RUN: llvm-as -o %t %s +; RUN: lld-link /entry:main /subsystem:console /out:%t.exe %t +; RUN: llvm-objdump -d %t.exe | FileCheck %s + +target datalayout = "e-m:x-p:32:32-i64:64-f80:32-n8:16:32-a:0:32-S32" +target triple = "i686-pc-windows-msvc" + +@foo = thread_local global i8 0 + +module asm "__tls_index = 1" +module asm "__tls_array = 2" + +define i8* @main() { + ; CHECK: movl 1, %eax + ; CHECK: movl %fs:2, %ecx + ; CHECK: movl (%ecx,%eax,4), %eax + ; CHECK: leal (%eax), %eax + ret i8* @foo +} |