[llvm-commits] [llvm] r102820 - /llvm/trunk/lib/CodeGen/SelectionDAG/InstrEmitter.cpp
Dan Gohman
gohman at apple.com
Fri Apr 30 17:50:53 PDT 2010
Author: djg
Date: Fri Apr 30 19:50:53 2010
New Revision: 102820
URL: http://llvm.org/viewvc/llvm-project?rev=102820&view=rev
Log:
Re-enable kill flags from SelectionDAGISel, with a fix: don't
try to put a kill flag on a DBG_INFO instruction.
Modified:
llvm/trunk/lib/CodeGen/SelectionDAG/InstrEmitter.cpp
Modified: llvm/trunk/lib/CodeGen/SelectionDAG/InstrEmitter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/InstrEmitter.cpp?rev=102820&r1=102819&r2=102820&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/InstrEmitter.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/InstrEmitter.cpp Fri Apr 30 19:50:53 2010
@@ -296,7 +296,6 @@
}
}
-#if 0
// If this value has only one use, that use is a kill. This is a
// conservative approximation. Tied operands are never killed, so we need
// to check that. And that means we need to determine the index of the
@@ -306,10 +305,7 @@
MI->getOperand(Idx-1).isReg() && MI->getOperand(Idx-1).isImplicit())
--Idx;
bool isTied = MI->getDesc().getOperandConstraint(Idx, TOI::TIED_TO) != -1;
- bool isKill = Op.hasOneUse() && !isTied;
-#else
- bool isKill = false;
-#endif
+ bool isKill = Op.hasOneUse() && !isTied && !IsDebug;
MI->addOperand(MachineOperand::CreateReg(VReg, isOptDef,
false/*isImp*/, isKill,
More information about the llvm-commits
mailing list