[llvm-commits] CVS: llvm/lib/CodeGen/InstrSched/InstrScheduling.cpp
Brian Gaeke
gaeke at cs.uiuc.edu
Wed Aug 18 13:04:36 PDT 2004
Changes in directory llvm/lib/CodeGen/InstrSched:
InstrScheduling.cpp updated: 1.76 -> 1.77
---
Log message:
Instead of using isDummyPhiInstr, we just compare the opcode with V9::PHI.
Also, squash a use of TargetInstrInfo::isNop().
---
Diffs of the changes: (+3 -3)
Index: llvm/lib/CodeGen/InstrSched/InstrScheduling.cpp
diff -u llvm/lib/CodeGen/InstrSched/InstrScheduling.cpp:1.76 llvm/lib/CodeGen/InstrSched/InstrScheduling.cpp:1.77
--- llvm/lib/CodeGen/InstrSched/InstrScheduling.cpp:1.76 Mon Aug 16 16:55:01 2004
+++ llvm/lib/CodeGen/InstrSched/InstrScheduling.cpp Wed Aug 18 15:04:21 2004
@@ -19,6 +19,7 @@
#include "llvm/Target/TargetMachine.h"
#include "../../Target/SparcV9/MachineCodeForInstruction.h"
#include "../../Target/SparcV9/LiveVar/FunctionLiveVarInfo.h"
+#include "../../Target/SparcV9/SparcV9InstrInfo.h"
#include "Support/CommandLine.h"
#include <algorithm>
#include <iostream>
@@ -633,8 +634,7 @@
// some NOPs from delay slots. Also, PHIs are not included in the schedule.
unsigned numInstr = 0;
for (MachineBasicBlock::iterator I=MBB.begin(); I != MBB.end(); ++I)
- if (! mii.isNop(I->getOpcode()) &&
- ! mii.isDummyPhiInstr(I->getOpcode()))
+ if (!(I->getOpcode() == V9::NOP || I->getOpcode() == V9::PHI))
++numInstr;
assert(S.isched.getNumInstructions() >= numInstr &&
"Lost some non-NOP instructions during scheduling!");
@@ -645,7 +645,7 @@
// First find the dummy instructions at the start of the basic block
MachineBasicBlock::iterator I = MBB.begin();
for ( ; I != MBB.end(); ++I)
- if (! mii.isDummyPhiInstr(I->getOpcode()))
+ if (I->getOpcode() != V9::PHI)
break;
// Remove all except the dummy PHI instructions from MBB, and
More information about the llvm-commits
mailing list