mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-10 02:36:06 +00:00
Prevent PPC::BCC first operand, the PRED number, from being isel'd into a LI instruction.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37790 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
ca6c31cc41
commit
2bda17c922
@ -1080,7 +1080,10 @@ SDNode *PPCDAGToDAGISel::Select(SDOperand Op) {
|
|||||||
// Op #2 is the CR#
|
// Op #2 is the CR#
|
||||||
// Op #3 is the Dest MBB
|
// Op #3 is the Dest MBB
|
||||||
AddToISelQueue(N->getOperand(4)); // Op #4 is the Flag.
|
AddToISelQueue(N->getOperand(4)); // Op #4 is the Flag.
|
||||||
SDOperand Ops[] = { N->getOperand(1), N->getOperand(2), N->getOperand(3),
|
// Prevent PPC::PRED_* from being selected into LI.
|
||||||
|
SDOperand Pred =
|
||||||
|
getI32Imm(cast<ConstantSDNode>(N->getOperand(1))->getValue());
|
||||||
|
SDOperand Ops[] = { Pred, N->getOperand(2), N->getOperand(3),
|
||||||
N->getOperand(0), N->getOperand(4) };
|
N->getOperand(0), N->getOperand(4) };
|
||||||
return CurDAG->SelectNodeTo(N, PPC::BCC, MVT::Other, Ops, 5);
|
return CurDAG->SelectNodeTo(N, PPC::BCC, MVT::Other, Ops, 5);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user