Address issues found by Duncan during post-commit review of r177856.
[oota-llvm.git] / test / Transforms / InstCombine / obfuscated_splat.ll
1 ; RUN: opt -instcombine -S < %s | FileCheck %s
2
3 define void @test(<4 x float> *%in_ptr, <4 x float> *%out_ptr) {
4   %A = load <4 x float>* %in_ptr, align 16
5   %B = shufflevector <4 x float> %A, <4 x float> undef, <4 x i32> <i32 0, i32 0, i32 undef, i32 undef>
6   %C = shufflevector <4 x float> %B, <4 x float> %A, <4 x i32> <i32 0, i32 1, i32 4, i32 undef>
7   %D = shufflevector <4 x float> %C, <4 x float> %A, <4 x i32> <i32 0, i32 1, i32 2, i32 4>
8 ; CHECK:  %D = shufflevector <4 x float> %A, <4 x float> undef, <4 x i32> zeroinitializer
9   store <4 x float> %D, <4 x float> *%out_ptr
10   ret void
11 }