mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-02-01 05:01:59 +01:00
[AArch64] Fix a fencepost error in lowering for llvm.aarch64.neon.uqshl.
Patch by Jiangning Liu! llvm-svn: 211014
This commit is contained in:
parent
679bcf9838
commit
d8293dd333
@ -7007,7 +7007,7 @@ static SDValue tryCombineShiftImm(unsigned IID, SDNode *N, SelectionDAG &DAG) {
|
|||||||
if (IsRightShift && ShiftAmount <= -1 && ShiftAmount >= -(int)ElemBits)
|
if (IsRightShift && ShiftAmount <= -1 && ShiftAmount >= -(int)ElemBits)
|
||||||
return DAG.getNode(Opcode, SDLoc(N), N->getValueType(0), N->getOperand(1),
|
return DAG.getNode(Opcode, SDLoc(N), N->getValueType(0), N->getOperand(1),
|
||||||
DAG.getConstant(-ShiftAmount, MVT::i32));
|
DAG.getConstant(-ShiftAmount, MVT::i32));
|
||||||
else if (!IsRightShift && ShiftAmount >= 0 && ShiftAmount <= ElemBits)
|
else if (!IsRightShift && ShiftAmount >= 0 && ShiftAmount < ElemBits)
|
||||||
return DAG.getNode(Opcode, SDLoc(N), N->getValueType(0), N->getOperand(1),
|
return DAG.getNode(Opcode, SDLoc(N), N->getValueType(0), N->getOperand(1),
|
||||||
DAG.getConstant(ShiftAmount, MVT::i32));
|
DAG.getConstant(ShiftAmount, MVT::i32));
|
||||||
|
|
||||||
|
@ -1313,6 +1313,15 @@ define <8 x i8> @uqshli8b(<8 x i8>* %A) nounwind {
|
|||||||
ret <8 x i8> %tmp3
|
ret <8 x i8> %tmp3
|
||||||
}
|
}
|
||||||
|
|
||||||
|
define <8 x i8> @uqshli8b_1(<8 x i8>* %A) nounwind {
|
||||||
|
;CHECK-LABEL: uqshli8b_1:
|
||||||
|
;CHECK: movi.8b [[REG:v[0-9]+]], #0x8
|
||||||
|
;CHECK: uqshl.8b v0, v0, [[REG]]
|
||||||
|
%tmp1 = load <8 x i8>* %A
|
||||||
|
%tmp3 = call <8 x i8> @llvm.aarch64.neon.uqshl.v8i8(<8 x i8> %tmp1, <8 x i8> <i8 8, i8 8, i8 8, i8 8, i8 8, i8 8, i8 8, i8 8>)
|
||||||
|
ret <8 x i8> %tmp3
|
||||||
|
}
|
||||||
|
|
||||||
define <4 x i16> @uqshli4h(<4 x i16>* %A) nounwind {
|
define <4 x i16> @uqshli4h(<4 x i16>* %A) nounwind {
|
||||||
;CHECK-LABEL: uqshli4h:
|
;CHECK-LABEL: uqshli4h:
|
||||||
;CHECK: uqshl.4h v0, {{v[0-9]+}}, #1
|
;CHECK: uqshl.4h v0, {{v[0-9]+}}, #1
|
||||||
|
Loading…
x
Reference in New Issue
Block a user