From 0a985df8a6569f7aef61b9023c4aecf65f96756c Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Fri, 1 Apr 2005 07:19:06 +0000 Subject: [PATCH] new testcase llvm-svn: 20978 --- test/Regression/CodeGen/Generic/nested-select.ll | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 test/Regression/CodeGen/Generic/nested-select.ll diff --git a/test/Regression/CodeGen/Generic/nested-select.ll b/test/Regression/CodeGen/Generic/nested-select.ll new file mode 100644 index 00000000000..c2dd580a44e --- /dev/null +++ b/test/Regression/CodeGen/Generic/nested-select.ll @@ -0,0 +1,16 @@ +; RUN: llvm-as < %s | llc -o /dev/null -f + +; Test that select of a select works + +int %ic_test(double %p.0.2.0.val, double %p.0.2.1.val, double %p.0.2.2.val, %typedef.tree* %t) { + %result.1.0 = cast bool false to int ; [#uses=1] + %tmp.55 = setge double 0.000000e+00, 1.000000e+00 ; [#uses=1] + %tmp.66 = div double 0.000000e+00, 0.000000e+00 ; [#uses=1] + br label %N +N: + %result.1.1 = select bool %tmp.55, int 0, int %result.1.0 ; [#uses=1] + %tmp.75 = setge double %tmp.66, 1.000000e+00 ; [#uses=1] + %retval1 = select bool %tmp.75, int 0, int %result.1.1 ; [#uses=1] + ret int %retval1 +} +