brintos

brintos / llvm-project-archived public Read only

0
0
Text · 2.7 KiB · 66ad308 Raw
68 lines · plain
1; Test that llvm-reduce can reduce floating point operands2;3; RUN: llvm-reduce --abort-on-invalid-reduction --delta-passes=operands-one --test FileCheck --test-arg --check-prefixes=CHECK-INTERESTINGNESS --test-arg %s --test-arg --input-file %s -o %t4; RUN: FileCheck --check-prefixes=CHECK,ONE %s < %t5 6; RUN: llvm-reduce --abort-on-invalid-reduction --delta-passes=operands-zero --test FileCheck --test-arg --check-prefixes=CHECK-INTERESTINGNESS --test-arg %s --test-arg --input-file %s -o %t7; RUN: FileCheck --check-prefixes=CHECK,ZERO %s < %t8 9; RUN: llvm-reduce --abort-on-invalid-reduction --test FileCheck --test-arg --check-prefixes=CHECK-INTERESTINGNESS --test-arg %s --test-arg --input-file %s -o %t10; RUN: FileCheck --check-prefixes=CHECK,ZERO %s < %t11 12; CHECK-INTERESTINGNESS: = add i32 %13; CHECK-INTERESTINGNESS: = add i3214; CHECK-INTERESTINGNESS: = add i3215; CHECK-INTERESTINGNESS: = add i3216; CHECK-INTERESTINGNESS: = add i3217 18; CHECK-INTERESTINGNESS: = add <2 x i32> %19; CHECK-INTERESTINGNESS: = add <2 x i32>20; CHECK-INTERESTINGNESS: = add <2 x i32>21; CHECK-INTERESTINGNESS: = add <2 x i32>22; CHECK-INTERESTINGNESS: = add <2 x i32>23; CHECK-INTERESTINGNESS: = add <2 x i32>24 25; CHECK-LABEL: define {{(void|<2 x i32>)}} @foo(26 27 28; ONE: %add0 = add i32 %arg0, 129; ONE: %add1 = add i32 1, 130; ONE: %add2 = add i32 1, 031; ONE: %add3 = add i32 1, 132; ONE: %add4 = add i32 1, 133; ONE: %add5 = add <2 x i32> %arg2, splat (i32 1)34; ONE: %add6 = add <2 x i32> splat (i32 1), splat (i32 1)35; ONE: %add7 = add <2 x i32> splat (i32 1), zeroinitializer36; ONE: %add8 = add <2 x i32> splat (i32 1), splat (i32 1)37; ONE: %add9 = add <2 x i32> splat (i32 1), splat (i32 1)38; ONE: %add10 = add <2 x i32> splat (i32 1), splat (i32 1)39 40 41; ZERO: %add0 = add i32 %arg0, 042; ZERO: %add1 = add i32 0, 043; ZERO: %add2 = add i32 0, 044; ZERO: %add3 = add i32 0, 045; ZERO: %add4 = add i32 0, 046; ZERO: %add5 = add <2 x i32> %arg2, zeroinitializer47; ZERO: %add6 = add <2 x i32> zeroinitializer, zeroinitializer48; ZERO: %add7 = add <2 x i32> zeroinitializer, zeroinitializer49; ZERO: %add8 = add <2 x i32> zeroinitializer, zeroinitializer50; ZERO: %add9 = add <2 x i32> zeroinitializer, zeroinitializer51; ZERO: %add10 = add <2 x i32> zeroinitializer, zeroinitializer52 53define void @foo(i32 %arg0, i32 %arg1, <2 x i32> %arg2, <2 x i32> %arg3) {54bb0:55  %add0 = add i32 %arg0, %arg156  %add1 = add i32 %arg0, %arg157  %add2 = add i32 %arg0, 058  %add3 = add i32 %arg0, 159  %add4 = add i32 %arg0, undef60  %add5 = add <2 x i32> %arg2, %arg361  %add6 = add <2 x i32> %arg2, %arg362  %add7 = add <2 x i32> %arg2, zeroinitializer63  %add8 = add <2 x i32> %arg2, <i32 1, i32 1>64  %add9 = add <2 x i32> %arg2, undef65  %add10 = add <2 x i32> %arg2, <i32 4, i32 6>66  ret void67}68