diff options
Diffstat (limited to 'llvm/lib/CodeGen')
-rw-r--r-- | llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp index 48e0f7bc9ad..4b3064593c7 100644 --- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp @@ -286,6 +286,7 @@ SelectionDAG::~SelectionDAG() { } SDOperand SelectionDAG::getZeroExtendInReg(SDOperand Op, MVT::ValueType VT) { + if (Op.getValueType() == VT) return Op; int64_t Imm = ~0ULL >> 64-MVT::getSizeInBits(VT); return getNode(ISD::AND, Op.getValueType(), Op, getConstant(Imm, Op.getValueType())); |