summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2003-12-11 22:15:11 +0000
committerChris Lattner <sabre@nondot.org>2003-12-11 22:15:11 +0000
commit99146bb2a7c24bea64d14c08e6a7f5448e4dc4ab (patch)
tree5368c50f04f7eb4a4b023d29ac07edb6f55205cd
parent62aff8412a36ab1bfd26a4b513ab86c8df29d3fb (diff)
downloadbcm5719-llvm-99146bb2a7c24bea64d14c08e6a7f5448e4dc4ab.tar.gz
bcm5719-llvm-99146bb2a7c24bea64d14c08e6a7f5448e4dc4ab.zip
New testcase that LICM is breaking crafty on
llvm-svn: 10408
-rw-r--r--llvm/test/Regression/Transforms/LICM/2003-12-11-SinkingToPHI.ll20
1 files changed, 20 insertions, 0 deletions
diff --git a/llvm/test/Regression/Transforms/LICM/2003-12-11-SinkingToPHI.ll b/llvm/test/Regression/Transforms/LICM/2003-12-11-SinkingToPHI.ll
new file mode 100644
index 00000000000..ecbc130e873
--- /dev/null
+++ b/llvm/test/Regression/Transforms/LICM/2003-12-11-SinkingToPHI.ll
@@ -0,0 +1,20 @@
+; RUN: llvm-as < %s | opt -licm | lli
+
+implementation ; Functions:
+
+int %main() {
+entry:
+ br label %Loop
+
+Loop:
+ br bool true, label %LoopCont, label %Out
+LoopCont:
+ %X = add int 1, 0
+ br bool true, label %Out, label %Loop
+
+Out:
+ %V = phi int [ 2, %Loop], [ %X, %LoopCont]
+ %V2 = sub int %V, 1
+ ret int %V2
+}
+
OpenPOWER on IntegriCloud