mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-13 09:33:50 +00:00
Skip DEBUG_VALUE in some places where it was affecting codegen.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@95647 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
8581e0147c
commit
d94998f525
@ -64,6 +64,9 @@ bool CalculateSpillWeights::runOnMachineFunction(MachineFunction &fn) {
|
||||
if (mi->getOpcode() == TargetInstrInfo::IMPLICIT_DEF)
|
||||
continue;
|
||||
|
||||
if (mi->getOpcode() == TargetInstrInfo::DEBUG_VALUE)
|
||||
continue;
|
||||
|
||||
for (unsigned i = 0, e = mi->getNumOperands(); i != e; ++i) {
|
||||
const MachineOperand &mopi = mi->getOperand(i);
|
||||
if (!mopi.isReg() || mopi.getReg() == 0)
|
||||
|
@ -543,6 +543,8 @@ bool LiveVariables::runOnMachineFunction(MachineFunction &mf) {
|
||||
for (MachineBasicBlock::iterator I = MBB->begin(), E = MBB->end();
|
||||
I != E; ++I) {
|
||||
MachineInstr *MI = I;
|
||||
if (MI->getOpcode()==TargetInstrInfo::DEBUG_VALUE)
|
||||
continue;
|
||||
DistanceMap.insert(std::make_pair(MI, Dist++));
|
||||
|
||||
// Process all of the operands of the instruction...
|
||||
|
@ -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<MachineInstr*, unsigned>::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<MachineInstr*, unsigned>::iterator DI = DistanceMap.find(MI);
|
||||
if (DI == DistanceMap.end())
|
||||
continue;
|
||||
|
Loading…
x
Reference in New Issue
Block a user