diff options
author | Chris Lattner <sabre@nondot.org> | 2006-04-04 01:02:22 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2006-04-04 01:02:22 +0000 |
commit | a9e77d14c742603528ba6bc403da5a5566fb6c26 (patch) | |
tree | 5746fb5a34e2c1fdd26cdf7406adbdd5e4f81338 /llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | |
parent | b290906304b49d74e1186c1f863310dc2651e42d (diff) | |
download | bcm5719-llvm-a9e77d14c742603528ba6bc403da5a5566fb6c26.tar.gz bcm5719-llvm-a9e77d14c742603528ba6bc403da5a5566fb6c26.zip |
Constant fold bitconvert(undef)
llvm-svn: 27391
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp')
-rw-r--r-- | llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp index 6eb6570467f..a2b575ff31d 100644 --- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp @@ -1167,6 +1167,8 @@ SDOperand SelectionDAG::getNode(unsigned Opcode, MVT::ValueType VT, if (VT == Operand.getValueType()) return Operand; // noop conversion. if (OpOpcode == ISD::BIT_CONVERT) // bitconv(bitconv(x)) -> bitconv(x) return getNode(ISD::BIT_CONVERT, VT, Operand.getOperand(0)); + if (OpOpcode == ISD::UNDEF) + return getNode(ISD::UNDEF, VT); break; case ISD::SCALAR_TO_VECTOR: assert(MVT::isVector(VT) && !MVT::isVector(Operand.getValueType()) && |