aboutsummaryrefslogtreecommitdiffstats
path: root/test/Transforms
diff options
context:
space:
mode:
Diffstat (limited to 'test/Transforms')
-rw-r--r--test/Transforms/SCCP/2008-03-10-sret.ll12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/Transforms/SCCP/2008-03-10-sret.ll b/test/Transforms/SCCP/2008-03-10-sret.ll
new file mode 100644
index 0000000..284a590
--- /dev/null
+++ b/test/Transforms/SCCP/2008-03-10-sret.ll
@@ -0,0 +1,12 @@
+; RUN: llvm-as < %s | opt -ipsccp -disable-output
+
+define internal {i32, i32} @bar(i32 %A) {
+ %X = add i32 1, 2
+ ret i32 %A, i32 %A
+}
+
+define i32 @foo() {
+ %X = call {i32, i32} @bar(i32 17)
+ %Y = getresult {i32, i32} %X, 0
+ ret i32 %Y
+}