[PATCH] D53823: [X86] In lowerVectorShuffleAsBroadcast, make peeking through CONCAT_VECTORS work correctly if we already walked through a bitcast that changed the element size.
Craig Topper via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 29 13:34:39 PDT 2018
craig.topper added a comment.
Here's a test case that crashes with -mattr=avx2
define <8 x float> @foo(<4 x float> %x, <4 x float> %y, float %z) {
entry:
%tmp = shufflevector <4 x float> %x, <4 x float> %y, <8 x i32> <i32 0, i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, i32 7>
%bc = bitcast <8 x float> %tmp to <4 x i64>
%tmp1 = extractelement <4 x i64> %bc, i32 3
%tmp2 = bitcast i64 %tmp1 to <2 x float>
%tmp4 = extractelement <2 x float> %tmp2, i32 1
%tmp5 = insertelement <8 x float> undef, float %tmp4, i32 4
%tmp6 = insertelement <8 x float> %tmp5, float %z, i32 5
ret <8 x float> %tmp6
}
https://reviews.llvm.org/D53823
More information about the llvm-commits
mailing list