mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-14 11:32:34 +00:00
Support targets that do not use i8 shift amounts.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@19707 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
6fb5a4a5f8
commit
2c49f27955
@ -450,6 +450,10 @@ void SelectionDAGLowering::visitBr(BranchInst &I) {
|
||||
void SelectionDAGLowering::visitBinary(User &I, unsigned Opcode) {
|
||||
SDOperand Op1 = getValue(I.getOperand(0));
|
||||
SDOperand Op2 = getValue(I.getOperand(1));
|
||||
|
||||
if (isa<ShiftInst>(I))
|
||||
Op2 = DAG.getNode(ISD::ZERO_EXTEND, TLI.getShiftAmountTy(), Op2);
|
||||
|
||||
setValue(&I, DAG.getNode(Opcode, Op1.getValueType(), Op1, Op2));
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user