summaryrefslogtreecommitdiffstats
path: root/llvm/test/CodeGen/X86/system-intrinsics-xsaveopt.ll
diff options
context:
space:
mode:
authorAmjad Aboud <amjad.aboud@intel.com>2015-10-12 11:47:46 +0000
committerAmjad Aboud <amjad.aboud@intel.com>2015-10-12 11:47:46 +0000
commit1db6d7af46276ff65dc267e7bf2d424993b95d6b (patch)
tree96e84e53a625a320e1f81aca30658f1e4b8ea206 /llvm/test/CodeGen/X86/system-intrinsics-xsaveopt.ll
parent9b278a16958c7d1526eea23cdcd8f603b308ae0b (diff)
downloadbcm5719-llvm-1db6d7af46276ff65dc267e7bf2d424993b95d6b.tar.gz
bcm5719-llvm-1db6d7af46276ff65dc267e7bf2d424993b95d6b.zip
[X86] Add XSAVE intrinsic family
Add intrinsics for the XSAVE instructions (XSAVE/XSAVE64/XRSTOR/XRSTOR64) XSAVEOPT instructions (XSAVEOPT/XSAVEOPT64) XSAVEC instructions (XSAVEC/XSAVEC64) XSAVES instructions (XSAVES/XSAVES64/XRSTORS/XRSTORS64) Differential Revision: http://reviews.llvm.org/D13012 llvm-svn: 250029
Diffstat (limited to 'llvm/test/CodeGen/X86/system-intrinsics-xsaveopt.ll')
-rw-r--r--llvm/test/CodeGen/X86/system-intrinsics-xsaveopt.ll12
1 files changed, 12 insertions, 0 deletions
diff --git a/llvm/test/CodeGen/X86/system-intrinsics-xsaveopt.ll b/llvm/test/CodeGen/X86/system-intrinsics-xsaveopt.ll
new file mode 100644
index 00000000000..f9bd7acd5a7
--- /dev/null
+++ b/llvm/test/CodeGen/X86/system-intrinsics-xsaveopt.ll
@@ -0,0 +1,12 @@
+; RUN: llc < %s -mtriple=i686-unknown-unknown -mattr=+xsave,+xsaveopt | FileCheck %s
+
+define void @test_xsaveopt(i8* %ptr, i32 %hi, i32 %lo) {
+; CHECK-LABEL: test_xsaveopt
+; CHECK: movl 8(%esp), %edx
+; CHECK: movl 12(%esp), %eax
+; CHECK: movl 4(%esp), %ecx
+; CHECK: xsaveopt (%ecx)
+ call void @llvm.x86.xsaveopt(i8* %ptr, i32 %hi, i32 %lo)
+ ret void;
+}
+declare void @llvm.x86.xsaveopt(i8*, i32, i32)
OpenPOWER on IntegriCloud