From 62fbfe4e21fc0e2e57bea6880aa0332b5cec531a Mon Sep 17 00:00:00 2001 From: Sanjay Patel Date: Tue, 25 Oct 2016 13:30:19 +0000 Subject: [PATCH] [InstCombine] fix checks for previous commit (r285069) Accidentally put in the hoped-for checks ahead of the transform! llvm-svn: 285070 --- llvm/test/Transforms/InstCombine/minmax-fold.ll | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/llvm/test/Transforms/InstCombine/minmax-fold.ll b/llvm/test/Transforms/InstCombine/minmax-fold.ll index aa1ab6d..9cbaed3 100644 --- a/llvm/test/Transforms/InstCombine/minmax-fold.ll +++ b/llvm/test/Transforms/InstCombine/minmax-fold.ll @@ -144,8 +144,9 @@ define <4 x i32> @bitcasts_fcmp_1(<2 x i64> %a, <2 x i64> %b) { ; CHECK-NEXT: [[T0:%.*]] = bitcast <2 x i64> %a to <4 x float> ; CHECK-NEXT: [[T1:%.*]] = bitcast <2 x i64> %b to <4 x float> ; CHECK-NEXT: [[T2:%.*]] = fcmp olt <4 x float> [[T1]], [[T0]] -; CHECK-NEXT: [[TMP1:%.*]] = select <4 x i1> [[T2]], <4 x float> [[T0]], <4 x float> [[T1]] -; CHECK-NEXT: [[T5:%.*]] = bitcast <4 x float> [[TMP1]] to <4 x i32> +; CHECK-NEXT: [[T3:%.*]] = bitcast <2 x i64> %a to <4 x i32> +; CHECK-NEXT: [[T4:%.*]] = bitcast <2 x i64> %b to <4 x i32> +; CHECK-NEXT: [[T5:%.*]] = select <4 x i1> [[T2]], <4 x i32> [[T3]], <4 x i32> [[T4]] ; CHECK-NEXT: ret <4 x i32> [[T5]] ; %t0 = bitcast <2 x i64> %a to <4 x float> @@ -164,8 +165,9 @@ define <4 x i32> @bitcasts_fcmp_2(<2 x i64> %a, <2 x i64> %b) { ; CHECK-NEXT: [[T0:%.*]] = bitcast <2 x i64> %a to <4 x float> ; CHECK-NEXT: [[T1:%.*]] = bitcast <2 x i64> %b to <4 x float> ; CHECK-NEXT: [[T2:%.*]] = fcmp olt <4 x float> [[T0]], [[T1]] -; CHECK-NEXT: [[TMP1:%.*]] = select <4 x i1> [[T2]], <4 x float> [[T0]], <4 x float> [[T1]] -; CHECK-NEXT: [[T5:%.*]] = bitcast <4 x float> [[TMP1]] to <4 x i32> +; CHECK-NEXT: [[T3:%.*]] = bitcast <2 x i64> %a to <4 x i32> +; CHECK-NEXT: [[T4:%.*]] = bitcast <2 x i64> %b to <4 x i32> +; CHECK-NEXT: [[T5:%.*]] = select <4 x i1> [[T2]], <4 x i32> [[T3]], <4 x i32> [[T4]] ; CHECK-NEXT: ret <4 x i32> [[T5]] ; %t0 = bitcast <2 x i64> %a to <4 x float> @@ -184,8 +186,9 @@ define <4 x float> @bitcasts_icmp(<2 x i64> %a, <2 x i64> %b) { ; CHECK-NEXT: [[T0:%.*]] = bitcast <2 x i64> %a to <4 x i32> ; CHECK-NEXT: [[T1:%.*]] = bitcast <2 x i64> %b to <4 x i32> ; CHECK-NEXT: [[T2:%.*]] = icmp slt <4 x i32> [[T1]], [[T0]] -; CHECK-NEXT: [[TMP1:%.*]] = select <4 x i1> [[T2]], <4 x i32> [[T0]], <4 x i32> [[T1]] -; CHECK-NEXT: [[T5:%.*]] = bitcast <4 x i32> [[TMP1]] to <4 x float> +; CHECK-NEXT: [[T3:%.*]] = bitcast <2 x i64> %a to <4 x float> +; CHECK-NEXT: [[T4:%.*]] = bitcast <2 x i64> %b to <4 x float> +; CHECK-NEXT: [[T5:%.*]] = select <4 x i1> [[T2]], <4 x float> [[T3]], <4 x float> [[T4]] ; CHECK-NEXT: ret <4 x float> [[T5]] ; %t0 = bitcast <2 x i64> %a to <4 x i32> -- 2.7.4