mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-27 14:34:58 +00:00
test vperm promotion
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27454 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
58d665c182
commit
c0d2021f0a
@ -1,4 +1,5 @@
|
||||
; RUN: llvm-as < %s | llc -march=ppc32 -mcpu=g5 | grep vsldoi | wc -l | grep 2
|
||||
; RUN: llvm-as < %s | opt -instcombine | llc -march=ppc32 -mcpu=g5 | not grep vperm
|
||||
|
||||
void %VSLDOI_xy(<8 x short>* %A, <8 x short>* %B) {
|
||||
entry:
|
||||
@ -84,3 +85,18 @@ void %VSLDOI_xx(<8 x short>* %A, <8 x short>* %B) {
|
||||
store <8 x short> %tmp33, <8 x short>* %A
|
||||
ret void
|
||||
}
|
||||
|
||||
void %VPERM_promote(<8 x short>* %A, <8 x short>* %B) {
|
||||
entry:
|
||||
%tmp = load <8 x short>* %A ; <<8 x short>> [#uses=1]
|
||||
%tmp = cast <8 x short> %tmp to <4 x int> ; <<4 x int>> [#uses=1]
|
||||
%tmp2 = load <8 x short>* %B ; <<8 x short>> [#uses=1]
|
||||
%tmp2 = cast <8 x short> %tmp2 to <4 x int> ; <<4 x int>> [#uses=1]
|
||||
%tmp3 = call <4 x int> %llvm.ppc.altivec.vperm( <4 x int> %tmp, <4 x int> %tmp2, <16 x sbyte> < sbyte 14, sbyte 14, sbyte 14, sbyte 14, sbyte 14, sbyte 14, sbyte 14, sbyte 14, sbyte 14, sbyte 14, sbyte 14, sbyte 14, sbyte 14, sbyte 14, sbyte 14, sbyte 14 > ) ; <<4 x int>> [#uses=1]
|
||||
%tmp3 = cast <4 x int> %tmp3 to <8 x short> ; <<8 x short>> [#uses=1]
|
||||
store <8 x short> %tmp3, <8 x short>* %A
|
||||
ret void
|
||||
}
|
||||
|
||||
declare <4 x int> %llvm.ppc.altivec.vperm(<4 x int>, <4 x int>, <16 x sbyte>)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user