Test Failure: Transforms/InstCombine/insert-extract-shuffle-inseltpoison.ll

Test source: git

Log:

Source: /home/nlopes/llvm/llvm/test/Transforms/InstCombine/insert-extract-shuffle-inseltpoison.ll

----------------------------------------
define <1 x i8> @test1(<8 x i8> %in) {
%0:
  %val = extractelement <8 x i8> %in, i32 5
  %vec = insertelement <1 x i8> poison, i8 %val, i32 0
  ret <1 x i8> %vec
}
=>
define <1 x i8> @test1(<8 x i8> %in) {
%0:
  %vec = shufflevector <8 x i8> %in, <8 x i8> undef, 5
  ret <1 x i8> %vec
}
Transformation seems to be correct!


----------------------------------------
define <4 x i16> @test2(<8 x i16> %in, <8 x i16> %in2) {
%0:
  %elt0 = extractelement <8 x i16> %in, i32 3
  %elt1 = extractelement <8 x i16> %in, i32 1
  %elt2 = extractelement <8 x i16> %in2, i32 0
  %elt3 = extractelement <8 x i16> %in, i32 2
  %vec.0 = insertelement <4 x i16> poison, i16 %elt0, i32 0
  %vec.1 = insertelement <4 x i16> %vec.0, i16 %elt1, i32 1
  %vec.2 = insertelement <4 x i16> %vec.1, i16 %elt2, i32 2
  %vec.3 = insertelement <4 x i16> %vec.2, i16 %elt3, i32 3
  ret <4 x i16> %vec.3
}
=>
define <4 x i16> @test2(<8 x i16> %in, <8 x i16> %in2) {
%0:
  %vec.3 = shufflevector <8 x i16> %in2, <8 x i16> %in, 11, 9, 0, 10
  ret <4 x i16> %vec.3
}
Transformation seems to be correct!


----------------------------------------
define <2 x i64> @test_vcopyq_lane_p64(<2 x i64> %a, <1 x i64> %b) {
%0:
  %elt = extractelement <1 x i64> %b, i32 0
  %res = insertelement <2 x i64> %a, i64 %elt, i32 1
  ret <2 x i64> %res
}
=>
define <2 x i64> @test_vcopyq_lane_p64(<2 x i64> %a, <1 x i64> %b) {
%0:
  %1 = shufflevector <1 x i64> %b, <1 x i64> poison, 0, 4294967295
  %res = shufflevector <2 x i64> %a, <2 x i64> %1, 0, 2
  ret <2 x i64> %res
}
Transformation seems to be correct!


----------------------------------------
define <4 x float> @widen_extract2(<4 x float> %ins, <2 x float> %ext) {
%0:
  %e1 = extractelement <2 x float> %ext, i32 0
  %e2 = extractelement <2 x float> %ext, i32 1
  %i1 = insertelement <4 x float> %ins, float %e1, i32 1
  %i2 = insertelement <4 x float> %i1, float %e2, i32 3
  ret <4 x float> %i2
}
=>
define <4 x float> @widen_extract2(<4 x float> %ins, <2 x float> %ext) {
%0:
  %1 = shufflevector <2 x float> %ext, <2 x float> poison, 0, 1, 4294967295, 4294967295
  %i2 = shufflevector <4 x float> %ins, <4 x float> %1, 0, 4, 2, 5
  ret <4 x float> %i2
}
Transformation seems to be correct!


----------------------------------------
define <4 x float> @widen_extract3(<4 x float> %ins, <3 x float> %ext) {
%0:
  %e1 = extractelement <3 x float> %ext, i32 0
  %e2 = extractelement <3 x float> %ext, i32 1
  %e3 = extractelement <3 x float> %ext, i32 2
  %i1 = insertelement <4 x float> %ins, float %e1, i32 2
  %i2 = insertelement <4 x float> %i1, float %e2, i32 1
  %i3 = insertelement <4 x float> %i2, float %e3, i32 0
  ret <4 x float> %i3
}
=>
define <4 x float> @widen_extract3(<4 x float> %ins, <3 x float> %ext) {
%0:
  %1 = shufflevector <3 x float> %ext, <3 x float> poison, 0, 1, 2, 4294967295
  %i3 = shufflevector <4 x float> %ins, <4 x float> %1, 6, 5, 4, 3
  ret <4 x float> %i3
}
Transformation seems to be correct!


----------------------------------------
define <8 x float> @widen_extract4(<8 x float> %ins, <2 x float> %ext) {
%0:
  %e1 = extractelement <2 x float> %ext, i32 0
  %i1 = insertelement <8 x float> %ins, float %e1, i32 2
  ret <8 x float> %i1
}
=>
define <8 x float> @widen_extract4(<8 x float> %ins, <2 x float> %ext) {
%0:
  %1 = shufflevector <2 x float> %ext, <2 x float> poison, 0, 4294967295, 4294967295, 4294967295, 4294967295, 4294967295, 4294967295, 4294967295
  %i1 = shufflevector <8 x float> %ins, <8 x float> %1, 0, 1, 8, 3, 4, 5, 6, 7
  ret <8 x float> %i1
}
Transformation doesn't verify!
ERROR: Timeout


----------------------------------------
define <8 x i16> @pr26015(<4 x i16> %t0) {
%0:
  %t1 = extractelement <4 x i16> %t0, i32 2
  %t2 = insertelement <8 x i16> { 0, 0, 0, 0, 0, 0, 0, 0 }, i16 %t1, i32 3
  %t3 = insertelement <8 x i16> %t2, i16 0, i32 6
  %t4 = extractelement <4 x i16> %t0, i32 3
  %t5 = insertelement <8 x i16> %t3, i16 %t4, i32 7
  ret <8 x i16> %t5
}
=>
define <8 x i16> @pr26015(<4 x i16> %t0) {
%0:
  %1 = shufflevector <4 x i16> %t0, <4 x i16> poison, 4294967295, 4294967295, 2, 3, 4294967295, 4294967295, 4294967295, 4294967295
  %t5 = shufflevector <8 x i16> { 0, 0, 0, poison, 0, 0, 0, poison }, <8 x i16> %1, 0, 1, 2, 10, 4, 5, 6, 11
  ret <8 x i16> %t5
}
Transformation seems to be correct!


----------------------------------------
define <8 x i16> @pr25999(<4 x i16> %t0, i1 %b) {
%0:
  %t1 = extractelement <4 x i16> %t0, i32 2
  br i1 %b, label %if, label %end

%end:
  %a1 = add i16 %t1, 4
  %t6 = insertelement <8 x i16> { 0, 0, 0, 0, 0, 0, 0, 0 }, i16 %a1, i32 0
  ret <8 x i16> %t6

%if:
  %t2 = insertelement <8 x i16> { 0, 0, 0, 0, 0, 0, 0, 0 }, i16 %t1, i32 3
  %t3 = insertelement <8 x i16> %t2, i16 0, i32 6
  %t4 = extractelement <4 x i16> %t0, i32 3
  %t5 = insertelement <8 x i16> %t3, i16 %t4, i32 7
  ret <8 x i16> %t5
}
=>
define <8 x i16> @pr25999(<4 x i16> %t0, i1 %b) {
%0:
  %t1 = extractelement <4 x i16> %t0, i32 2
  br i1 %b, label %if, label %end

%end:
  %a1 = add i16 %t1, 4
  %t6 = insertelement <8 x i16> { poison, 0, 0, 0, 0, 0, 0, 0 }, i16 %a1, i32 0
  ret <8 x i16> %t6

%if:
  %1 = shufflevector <4 x i16> %t0, <4 x i16> poison, 4294967295, 4294967295, 4294967295, 3, 4294967295, 4294967295, 4294967295, 4294967295
  %t3 = insertelement <8 x i16> { 0, 0, 0, poison, 0, 0, 0, poison }, i16 %t1, i32 3
  %t5 = shufflevector <8 x i16> %t3, <8 x i16> %1, 0, 1, 2, 3, 4, 5, 6, 11
  ret <8 x i16> %t5
}
Transformation doesn't verify!
ERROR: Timeout


----------------------------------------
define <4 x double> @pr25999_phis1(i1 %c, <2 x double> %a, <4 x double> %b) {
%bb1:
  br i1 %c, label %bb2, label %bb3

%bb2:
  %r = call <2 x double> @dummy(<2 x double> %a)
  br label %bb3

%bb3:
  %tmp1 = phi <2 x double> [ %a, %bb1 ], [ %r, %bb2 ]
  %tmp2 = phi <4 x double> [ %b, %bb1 ], [ { 0.000000, 0.000000, 0.000000, 0.000000 }, %bb2 ]
  %tmp3 = extractelement <2 x double> %tmp1, i32 0
  %tmp4 = insertelement <4 x double> %tmp2, double %tmp3, i32 2
  ret <4 x double> %tmp4
}
=>
define <4 x double> @pr25999_phis1(i1 %c, <2 x double> %a, <4 x double> %b) {
%bb1:
  br i1 %c, label %bb2, label %bb3

%bb2:
  %r = call <2 x double> @dummy(<2 x double> %a)
  br label %bb3

%bb3:
  %tmp1 = phi <2 x double> [ %a, %bb1 ], [ %r, %bb2 ]
  %tmp2 = phi <4 x double> [ %b, %bb1 ], [ { 0.000000, 0.000000, 0.000000, 0.000000 }, %bb2 ]
  %0 = shufflevector <2 x double> %tmp1, <2 x double> poison, 0, 4294967295, 4294967295, 4294967295
  %tmp4 = shufflevector <4 x double> %tmp2, <4 x double> %0, 0, 1, 4, 3
  ret <4 x double> %tmp4
}
Transformation seems to be correct!


----------------------------------------
define <4 x double> @pr25999_phis2(i1 %c, <2 x double> %a, <4 x double> %b) {
%bb1:
  br i1 %c, label %bb2, label %bb3

%bb2:
  %r = call <2 x double> @dummy(<2 x double> %a)
  br label %bb3

%bb3:
  %tmp1 = phi <2 x double> [ %a, %bb1 ], [ %r, %bb2 ]
  %tmp2 = phi <4 x double> [ %b, %bb1 ], [ { 0.000000, 0.000000, 0.000000, 0.000000 }, %bb2 ]
  %d = fadd <2 x double> %tmp1, %tmp1
  %tmp3 = extractelement <2 x double> %d, i32 0
  %tmp4 = insertelement <4 x double> %tmp2, double %tmp3, i32 2
  ret <4 x double> %tmp4
}
=>
define <4 x double> @pr25999_phis2(i1 %c, <2 x double> %a, <4 x double> %b) {
%bb1:
  br i1 %c, label %bb2, label %bb3

%bb2:
  %r = call <2 x double> @dummy(<2 x double> %a)
  br label %bb3

%bb3:
  %tmp1 = phi <2 x double> [ %a, %bb1 ], [ %r, %bb2 ]
  %tmp2 = phi <4 x double> [ %b, %bb1 ], [ { 0.000000, 0.000000, 0.000000, 0.000000 }, %bb2 ]
  %d = fadd <2 x double> %tmp1, %tmp1
  %0 = shufflevector <2 x double> %d, <2 x double> poison, 0, 4294967295, 4294967295, 4294967295
  %tmp4 = shufflevector <4 x double> %tmp2, <4 x double> %0, 0, 1, 4, 3
  ret <4 x double> %tmp4
}
Transformation doesn't verify!
ERROR: Timeout


----------------------------------------
define double @pr26354(* %tmp, i1 %B) {
%entry:
  %ld = load <2 x double>, * %tmp, align 16
  %e1 = extractelement <2 x double> %ld, i32 0
  %e2 = extractelement <2 x double> %ld, i32 1
  br i1 %B, label %if, label %end

%if:
  %i1 = insertelement <4 x double> { 0.000000, 0.000000, 0.000000, 0.000000 }, double %e2, i32 3
  br label %end

%end:
  %ph = phi <4 x double> [ undef, %entry ], [ %i1, %if ]
  %e3 = extractelement <4 x double> %ph, i32 1
  %mu = fmul double %e1, %e3
  ret double %mu
}
=>
define double @pr26354(* %tmp, i1 %B) {
%entry:
  %ld = load <2 x double>, * %tmp, align 16
  br i1 %B, label %if, label %end

%if:
  %e2 = extractelement <2 x double> %ld, i32 1
  %i1 = insertelement <4 x double> { 0.000000, 0.000000, 0.000000, poison }, double %e2, i32 3
  br label %end

%end:
  %ph = phi <4 x double> [ undef, %entry ], [ %i1, %if ]
  %e1 = extractelement <2 x double> %ld, i32 0
  %e3 = extractelement <4 x double> %ph, i32 1
  %mu = fmul double %e1, %e3
  ret double %mu
}
Transformation doesn't verify!
ERROR: Timeout


----------------------------------------
define <4 x float> @PR30923(<2 x float> %x) {
%bb1:
  %ext1 = extractelement <2 x float> %x, i32 1
  store float %ext1, * undef, align 4
  br label %bb2

%bb2:
  %widen = shufflevector <2 x float> %x, <2 x float> poison, 0, 1, 4294967295, 4294967295
  %ext2 = extractelement <4 x float> %widen, i32 0
  %ins1 = insertelement <4 x float> { 0.000000, 0.000000, undef, undef }, float %ext2, i32 2
  %ins2 = insertelement <4 x float> %ins1, float %ext1, i32 3
  ret <4 x float> %ins2
}
=>
define <4 x float> @PR30923(<2 x float> %x) {
%bb1:
  %ext1 = extractelement <2 x float> %x, i32 1
  store float %ext1, * undef, align 4
  br label %bb2

%bb2:
  %ext2 = extractelement <2 x float> %x, i32 0
  %ins1 = insertelement <4 x float> { 0.000000, 0.000000, poison, poison }, float %ext2, i32 2
  %ins2 = insertelement <4 x float> %ins1, float %ext1, i32 3
  ret <4 x float> %ins2
}
Transformation seems to be correct!


----------------------------------------
define <4 x i32> @extractelt_insertion(<2 x i32> %x, i32 %y) {
%entry:
  %a = extractelement <2 x i32> %x, i32 1
  %b = insertelement <4 x i32> { 0, 0, 0, 0 }, i32 %a, i64 3
  %c = add i32 %y, 3
  %d = extractelement <2 x i32> %x, i32 %c
  %e = icmp eq i32 %d, 0
  %ret = select i1 %e, <4 x i32> %b, <4 x i32> { 0, 0, 0, 0 }
  ret <4 x i32> %ret
}
=>
define <4 x i32> @extractelt_insertion(<2 x i32> %x, i32 %y) {
%entry:
  %0 = shufflevector <2 x i32> %x, <2 x i32> poison, 0, 1, 4294967295, 4294967295
  %b = shufflevector <4 x i32> { 0, 0, 0, poison }, <4 x i32> %0, 0, 1, 2, 5
  %c = add i32 %y, 3
  %1 = extractelement <4 x i32> %0, i32 %c
  %e = icmp eq i32 %1, 0
  %ret = select i1 %e, <4 x i32> %b, <4 x i32> { 0, 0, 0, 0 }
  ret <4 x i32> %ret
}
Transformation seems to be correct!


----------------------------------------
define <4 x float> @collectShuffleElts(<2 x float> %x, float %y) {
%0:
  %x0 = extractelement <2 x float> %x, i32 0
  %x1 = extractelement <2 x float> %x, i32 1
  %v1 = insertelement <4 x float> poison, float %x0, i32 1
  %v2 = insertelement <4 x float> %v1, float %x1, i32 2
  %v3 = insertelement <4 x float> %v2, float %y, i32 3
  ret <4 x float> %v3
}
=>
define <4 x float> @collectShuffleElts(<2 x float> %x, float %y) {
%0:
  %x0 = extractelement <2 x float> %x, i32 0
  %x1 = extractelement <2 x float> %x, i32 1
  %v1 = insertelement <4 x float> poison, float %x0, i32 1
  %v2 = insertelement <4 x float> %v1, float %x1, i32 2
  %v3 = insertelement <4 x float> %v2, float %y, i32 3
  ret <4 x float> %v3
}
Transformation seems to be correct! (syntactically equal)


----------------------------------------
define <4 x float> @insert_shuffle(float %x, <4 x float> %y) {
%0:
  %xv = insertelement <4 x float> poison, float %x, i32 0
  %r = shufflevector <4 x float> %xv, <4 x float> %y, 0, 5, 6, 7
  ret <4 x float> %r
}
=>
define <4 x float> @insert_shuffle(float %x, <4 x float> %y) {
%0:
  %r = insertelement <4 x float> %y, float %x, i32 0
  ret <4 x float> %r
}
Transformation seems to be correct!


----------------------------------------
define <4 x float> @insert_shuffle_translate(float %x, <4 x float> %y) {
%0:
  %xv = insertelement <4 x float> poison, float %x, i32 0
  %r = shufflevector <4 x float> %xv, <4 x float> %y, 4, 0, 6, 7
  ret <4 x float> %r
}
=>
define <4 x float> @insert_shuffle_translate(float %x, <4 x float> %y) {
%0:
  %r = insertelement <4 x float> %y, float %x, i32 1
  ret <4 x float> %r
}
Transformation seems to be correct!


----------------------------------------
define <4 x float> @insert_not_undef_shuffle_translate(float %x, <4 x float> %y, <4 x float> %q) {
%0:
  %xv = insertelement <4 x float> %q, float %x, i32 3
  %r = shufflevector <4 x float> %xv, <4 x float> %y, 4, 5, 3, 7
  ret <4 x float> %r
}
=>
define <4 x float> @insert_not_undef_shuffle_translate(float %x, <4 x float> %y, <4 x float> %q) {
%0:
  %r = insertelement <4 x float> %y, float %x, i32 2
  ret <4 x float> %r
}
Transformation seems to be correct!


----------------------------------------
define <4 x float> @insert_not_undef_shuffle_translate_commute(float %x, <4 x float> %y, <4 x float> %q) {
%0:
  %xv = insertelement <4 x float> %q, float %x, i32 2
  %r = shufflevector <4 x float> %y, <4 x float> %xv, 0, 6, 2, 4294967295
  ret <4 x float> %r
}
=>
define <4 x float> @insert_not_undef_shuffle_translate_commute(float %x, <4 x float> %y, <4 x float> %q) {
%0:
  %r = insertelement <4 x float> %y, float %x, i32 1
  ret <4 x float> %r
}
Transformation doesn't verify!
ERROR: Target is more poisonous than source

Example:
float %x = poison
<4 x float> %y = < poison, poison, poison, poison >
<4 x float> %q = < poison, poison, poison, poison >

Source:
<4 x float> %xv = < poison, poison, poison, poison >
<4 x float> %r = < poison, poison, poison, any >

Target:
<4 x float> %r = < poison, poison, poison, poison >
Source value: < poison, poison, poison, any >
Target value: < poison, poison, poison, poison >


------------------- SMT STATS -------------------
Num queries: 79
Num invalid: 0
Num skips:   0
Num trivial: 50 (38.8%)
Num timeout: 4 (5.1%)
Num errors:  0 (0.0%)
Num SAT:     32 (40.5%)
Num UNSAT:   43 (54.4%)
Alive2: Transform doesn't verify; aborting!

stderr:

+ : 'RUN: at line 2'
+ /home/nlopes/alive2/build/opt-alive.sh -S -instcombine /home/nlopes/llvm/llvm/test/Transforms/InstCombine/insert-extract-shuffle-inseltpoison.ll
+ /home/nlopes/llvm/build/bin/FileCheck /home/nlopes/llvm/llvm/test/Transforms/InstCombine/insert-extract-shuffle-inseltpoison.ll

FileCheck error: '<stdin>' is empty.
FileCheck command line:  /home/nlopes/llvm/build/bin/FileCheck /home/nlopes/llvm/llvm/test/Transforms/InstCombine/insert-extract-shuffle-inseltpoison.ll

 

<-- Back