diff options
author | Marcin Koscielnicki <koriakin@0x04.net> | 2016-04-26 10:37:01 +0000 |
---|---|---|
committer | Marcin Koscielnicki <koriakin@0x04.net> | 2016-04-26 10:37:01 +0000 |
commit | 79b1c77d1297f8a7d3788227e8f9d5c5c9b14b5c (patch) | |
tree | ff0bfb6c86ef67f2f8041653f496719ee91eb175 /test | |
parent | e1abe9da1be37a81567540757fd5f755897edb3e (diff) |
[SPARC] Add support for llvm.thread.pointer.
Differential Revision: http://reviews.llvm.org/D19387
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@267544 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r-- | test/CodeGen/SPARC/thread-pointer.ll | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/test/CodeGen/SPARC/thread-pointer.ll b/test/CodeGen/SPARC/thread-pointer.ll new file mode 100644 index 00000000000..33e99aa9474 --- /dev/null +++ b/test/CodeGen/SPARC/thread-pointer.ll @@ -0,0 +1,11 @@ +; RUN: llc < %s -mtriple=sparc-unknown-linux-gnu | FileCheck %s +; RUN: llc < %s -mtriple=sparc64-unknown-linux-gnu | FileCheck %s + +; Function Attrs: nounwind readnone +declare i8* @llvm.thread.pointer() #1 + +define i8* @thread_pointer() { +; CHECK: mov %g7, %o0 + %1 = tail call i8* @llvm.thread.pointer() + ret i8* %1 +} |