From 3e5215bf73401752282425e412fa16a6a6b2c7ae Mon Sep 17 00:00:00 2001 From: Chandler Carruth Date: Sat, 28 Jun 2014 05:46:28 +0000 Subject: [x86] Fix a bug in the v8i16 shuffling exposed by the new splat-like lowering for v16i8. ASan and some bots caught this bug with existing test cases. Fixing it even fixed a miscompile with one of the test cases. I'm still a bit suspicious of this test case as I've not taken a proper amount of time to think about it, but the fix here is strict goodness. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@211976 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/X86/X86ISelLowering.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/Target/X86/X86ISelLowering.cpp b/lib/Target/X86/X86ISelLowering.cpp index 8a00d6e2bc..8a12c03e07 100644 --- a/lib/Target/X86/X86ISelLowering.cpp +++ b/lib/Target/X86/X86ISelLowering.cpp @@ -7535,7 +7535,7 @@ static SDValue lowerV8I16BasicBlendVectorShuffle(SDLoc DL, SDValue V1, } else { // Otherwise pin the low inputs. for (int GoodInput : GoodInputs) - MoveMask[Mask[GoodInput]] = Mask[GoodInput] - MaskOffset; + MoveMask[Mask[GoodInput] - MaskOffset] = Mask[GoodInput] - MaskOffset; } int MoveMaskIdx = -- cgit v1.2.3