summaryrefslogtreecommitdiffstats
path: root/test/CodeGen/SystemZ/frame-10.ll
diff options
context:
space:
mode:
Diffstat (limited to 'test/CodeGen/SystemZ/frame-10.ll')
-rw-r--r--test/CodeGen/SystemZ/frame-10.ll14
1 files changed, 14 insertions, 0 deletions
diff --git a/test/CodeGen/SystemZ/frame-10.ll b/test/CodeGen/SystemZ/frame-10.ll
new file mode 100644
index 0000000..399a412
--- /dev/null
+++ b/test/CodeGen/SystemZ/frame-10.ll
@@ -0,0 +1,14 @@
+; Test the stacksave builtin.
+;
+; RUN: llc < %s -mtriple=s390x-linux-gnu | FileCheck %s
+
+declare i8 *@llvm.stacksave()
+
+define void @f1(i8 **%dest) {
+; CHECK: f1:
+; CHECK: stg %r15, 0(%r2)
+; CHECK: br %r14
+ %addr = call i8 *@llvm.stacksave()
+ store volatile i8 *%addr, i8 **%dest
+ ret void
+}
OpenPOWER on IntegriCloud