From c3adf44885d75326b607b1772c5d3618b7f91ae2 Mon Sep 17 00:00:00 2001 From: Dale Johannesen Date: Tue, 9 Feb 2010 02:01:46 +0000 Subject: Skip DEBUG_VALUE in some places where it was affecting codegen. llvm-svn: 95647 --- llvm/lib/CodeGen/TwoAddressInstructionPass.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'llvm/lib/CodeGen/TwoAddressInstructionPass.cpp') diff --git a/llvm/lib/CodeGen/TwoAddressInstructionPass.cpp b/llvm/lib/CodeGen/TwoAddressInstructionPass.cpp index a3f6364aa8e..71d9b83f7bf 100644 --- a/llvm/lib/CodeGen/TwoAddressInstructionPass.cpp +++ b/llvm/lib/CodeGen/TwoAddressInstructionPass.cpp @@ -318,6 +318,8 @@ bool TwoAddressInstructionPass::NoUseAfterLastDef(unsigned Reg, MachineInstr *MI = MO.getParent(); if (MI->getParent() != MBB) continue; + if (MI->getOpcode() == TargetInstrInfo::DEBUG_VALUE) + continue; DenseMap::iterator DI = DistanceMap.find(MI); if (DI == DistanceMap.end()) continue; @@ -341,6 +343,8 @@ MachineInstr *TwoAddressInstructionPass::FindLastUseInMBB(unsigned Reg, MachineInstr *MI = MO.getParent(); if (MI->getParent() != MBB) continue; + if (MI->getOpcode() == TargetInstrInfo::DEBUG_VALUE) + continue; DenseMap::iterator DI = DistanceMap.find(MI); if (DI == DistanceMap.end()) continue; -- cgit v1.2.3