mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-12-29 06:53:53 +00:00
Add patterns for v16i16 and v32i8 immAllZerosV to select VPXOR to match v4i64 and v8i32.
llvm-svn: 148106
This commit is contained in:
parent
85c44d1485
commit
71ea42cc29
@ -289,6 +289,14 @@ def AVX_SET0PDY : PDI<0x57, MRMInitReg, (outs VR256:$dst), (ins), "",
|
||||
|
||||
// AVX has no support for 256-bit integer instructions, but since the 128-bit
|
||||
// VPXOR instruction writes zero to its upper part, it's safe build zeros.
|
||||
def : Pat<(v32i8 immAllZerosV), (SUBREG_TO_REG (i8 0), (V_SET0), sub_xmm)>;
|
||||
def : Pat<(bc_v32i8 (v8f32 immAllZerosV)),
|
||||
(SUBREG_TO_REG (i8 0), (V_SET0), sub_xmm)>;
|
||||
|
||||
def : Pat<(v16i16 immAllZerosV), (SUBREG_TO_REG (i16 0), (V_SET0), sub_xmm)>;
|
||||
def : Pat<(bc_v16i16 (v8f32 immAllZerosV)),
|
||||
(SUBREG_TO_REG (i16 0), (V_SET0), sub_xmm)>;
|
||||
|
||||
def : Pat<(v8i32 immAllZerosV), (SUBREG_TO_REG (i32 0), (V_SET0), sub_xmm)>;
|
||||
def : Pat<(bc_v8i32 (v8f32 immAllZerosV)),
|
||||
(SUBREG_TO_REG (i32 0), (V_SET0), sub_xmm)>;
|
||||
|
@ -231,7 +231,7 @@ define <32 x i8> @sra_v32i8_7(<32 x i8> %A) nounwind {
|
||||
%B = ashr <32 x i8> %A, <i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7, i8 7>
|
||||
ret <32 x i8> %B
|
||||
; CHECK: sra_v32i8_7:
|
||||
; CHECK: vxorps
|
||||
; CHECK: vpxor
|
||||
; CHECK: vpcmpgtb
|
||||
; CHECK: ret
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user