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 | fafb44951ae43f198af0e6fa20c9ce60c394cdca (patch) | |
tree | c33574fd4c4ee397b4192d36ad4b672a214a192b /llvm/test/CodeGen | |
parent | aa309b1a81e669ee80754ed0fe2d30dc32bfb6ad (diff) | |
download | bcm5719-llvm-fafb44951ae43f198af0e6fa20c9ce60c394cdca.tar.gz bcm5719-llvm-fafb44951ae43f198af0e6fa20c9ce60c394cdca.zip |
[SPARC] Add support for llvm.thread.pointer.
Differential Revision: http://reviews.llvm.org/D19387
llvm-svn: 267544
Diffstat (limited to 'llvm/test/CodeGen')
-rw-r--r-- | llvm/test/CodeGen/SPARC/thread-pointer.ll | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/llvm/test/CodeGen/SPARC/thread-pointer.ll b/llvm/test/CodeGen/SPARC/thread-pointer.ll new file mode 100644 index 00000000000..33e99aa9474 --- /dev/null +++ b/llvm/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 +} |