summaryrefslogtreecommitdiffstats
path: root/llvm
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2004-12-10 22:28:49 +0000
committerChris Lattner <sabre@nondot.org>2004-12-10 22:28:49 +0000
commitf92cc45975bf950228cfb78e5dde4da1d3c52a70 (patch)
tree342a705b4fae5c88404710659b1a1bbe27806f9d /llvm
parent2da81ceb3d123bb9cff64329bee2fba318a0a44d (diff)
downloadbcm5719-llvm-f92cc45975bf950228cfb78e5dde4da1d3c52a70.tar.gz
bcm5719-llvm-f92cc45975bf950228cfb78e5dde4da1d3c52a70.zip
New testcase
llvm-svn: 18780
Diffstat (limited to 'llvm')
-rw-r--r--llvm/test/Regression/Transforms/SCCP/ipsccp-conditional.ll19
1 files changed, 19 insertions, 0 deletions
diff --git a/llvm/test/Regression/Transforms/SCCP/ipsccp-conditional.ll b/llvm/test/Regression/Transforms/SCCP/ipsccp-conditional.ll
new file mode 100644
index 00000000000..a3282119766
--- /dev/null
+++ b/llvm/test/Regression/Transforms/SCCP/ipsccp-conditional.ll
@@ -0,0 +1,19 @@
+; RUN: llvm-as < %s | opt -ipsccp | llvm-dis | grep -v 'ret int 0' | not grep ret
+
+implementation
+
+internal int %bar(int %A) {
+ %C = seteq int %A, 0
+ br bool %C, label %T, label %F
+T:
+ %B = call int %bar(int 0)
+ ret int 0
+F: ; unreachable
+ %C = call int %bar(int 1)
+ ret int %C
+}
+
+int %foo() {
+ %X = call int %bar(int 0)
+ ret int %X
+}
OpenPOWER on IntegriCloud