mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-08-27 15:29:51 +00:00
Use SUBREG_TO_REG instead of INSERT_SUBREG to model x86-64's
implicit zero-extend. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86196 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
eb3567cd49
commit
7289ed2ee7
@ -1949,14 +1949,12 @@ SDNode *X86DAGToDAGISel::Select(SDValue N) {
|
|||||||
0);
|
0);
|
||||||
// We just did a 32-bit clear, insert it into a 64-bit register to
|
// We just did a 32-bit clear, insert it into a 64-bit register to
|
||||||
// clear the whole 64-bit reg.
|
// clear the whole 64-bit reg.
|
||||||
SDValue Undef =
|
SDValue Zero = CurDAG->getTargetConstant(0, MVT::i64);
|
||||||
SDValue(CurDAG->getMachineNode(TargetInstrInfo::IMPLICIT_DEF,
|
|
||||||
dl, MVT::i64), 0);
|
|
||||||
SDValue SubRegNo =
|
SDValue SubRegNo =
|
||||||
CurDAG->getTargetConstant(X86::SUBREG_32BIT, MVT::i32);
|
CurDAG->getTargetConstant(X86::SUBREG_32BIT, MVT::i32);
|
||||||
ClrNode =
|
ClrNode =
|
||||||
SDValue(CurDAG->getMachineNode(TargetInstrInfo::INSERT_SUBREG, dl,
|
SDValue(CurDAG->getMachineNode(TargetInstrInfo::SUBREG_TO_REG, dl,
|
||||||
MVT::i64, Undef, ClrNode, SubRegNo),
|
MVT::i64, Zero, ClrNode, SubRegNo),
|
||||||
0);
|
0);
|
||||||
} else {
|
} else {
|
||||||
ClrNode = SDValue(CurDAG->getMachineNode(ClrOpcode, dl, NVT), 0);
|
ClrNode = SDValue(CurDAG->getMachineNode(ClrOpcode, dl, NVT), 0);
|
||||||
|
Loading…
Reference in New Issue
Block a user