llvm.org GIT mirror llvm / a3b56b2
[InstCombine, NewGVN] remove FP undef from tests I'm trying to preserve the intent of these tests by using non-undef operands; if we fix FP undef folding these tests will not pass. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@327004 91177308-0d34-0410-b5e6-96231b3b80d8 Sanjay Patel 1 year, 8 months ago
2 changed file(s) with 3 addition(s) and 3 deletion(s). Raw diff Collapse all Expand all
1414 %cmp86 = fcmp ogt double %highlights, 0.000000e+00
1515 %cond90 = select i1 %cmp86, double %sub24, double %add26
1616 %mul91 = fmul double %highlights, %cond90
17 %add94 = fadd double undef, %mul91
17 %add94 = fadd double %mul91, %mul91
1818 ret double %add94
1919 }
2020
55 ; CHECK-NEXT: br label [[IF:%.*]]
66 ; CHECK: if:
77 ; CHECK-NEXT: [[TMP0:%.*]] = phi double [ [[TMP1:%.*]], [[IF]] ], [ undef, [[TOP:%.*]] ]
8 ; CHECK-NEXT: [[TMP1]] = fadd double [[TMP0]], undef
8 ; CHECK-NEXT: [[TMP1]] = fadd double [[TMP0]], 1.000000e+00
99 ; CHECK-NEXT: br i1 false, label [[L50:%.*]], label [[IF]]
1010 ; CHECK: L50:
1111 ; CHECK-NEXT: store i8 undef, i8* null
2121
2222 if: ; preds = %if, %top
2323 %0 = phi double [ %1, %if ], [ %.promoted, %top ]
24 %1 = fadd double %0, undef
24 %1 = fadd double %0, 1.0
2525 br i1 false, label %L50, label %if
2626
2727 L50: ; preds = %if