; RUN: llc -march=hexagon < %s | FileCheck %s ; Perfect shuffle with single input vector. Half of it first needs to be ; transposed into the other vector before the generated shuffles can take ; effect, lastly the first transpose needs to be undone (this last step ; was missing). ; CHECK-LABEL: f0: ; CHECK-DAG: r[[R0:[0-9]+]] = #66 ; CHECK-DAG: r[[R1:[0-9]+]] = #40 ; CHECK-DAG: r[[R2:[0-9]+]] = #85 ; CHECK: v1:0 = vdeal(v{{[0-9]+}},v0,r[[R0]]) ; CHECK: v1:0 = vshuff(v1,v0,r[[R1]]) ; CHECK: v1:0 = vshuff(v1,v0,r[[R2]]) ; CHECK-NOT: = v define <128 x i8> @f0(<128 x i8> %a0) #0 { %v0 = shufflevector <128 x i8> %a0, <128 x i8> undef, <128 x i32> ret <128 x i8> %v0 } attributes #0 = { nounwind readnone "target-cpu"="hexagonv66" "target-features"="+hvx,+hvx-length128b,-packets" }