Go to the documentation of this file.
34 #ifndef TTA_BB_SCHEDULER_HH
35 #define TTA_BB_SCHEDULER_HH
37 #include <boost/timer.hpp>
38 #include <boost/progress.hpp>
78 bool testOnly =
false)
override;
106 MoveNode& move,
int earliestCycle,
bool allowPredicationAndRenaming);
130 bool resetCounter =
false)
const;
143 std::set<std::pair<TTAProgram::Move*, int> > removedMoves);
DataDependenceGraph * ddg_
DDG of the currently scheduled BB.
void unschedule(MoveNode &moveNode)
virtual ~BasicBlockScheduler()
MoveNode * succeedingTempMove(MoveNode ¤t)
TTAMachine::Machine * machine
the architecture definition of the estimated processor
MoveNodeSelector * selector_
void scheduleResultReadTempMoves(MoveNode &resultMove, MoveNode &resultRead, int lastUse)
void unscheduleResultReadTempMoves(MoveNode &resultMove)
BasicBlockScheduler(InterPassData &data, SoftwareBypasser *bypasser=NULL, RegisterRenamer *renamer=NULL)
virtual std::string longDescription() const
virtual DataDependenceGraphBuilder & ddgBuilder()
LLVMTCECmdLineOptions * options_
static MoveNode * findTriggerFromUnit(const ProgramOperation &po, const TTAMachine::Unit &unit)
virtual int handleLoopDDG(DataDependenceGraph &ddg, SimpleResourceManager &rm, const TTAMachine::Machine &targetMachine, int tripCount, SimpleResourceManager *prologRM, bool testOnly=false) override
void scheduleMove(MoveNode &move, int earliestCycle, bool allowPredicationAndRenaming)
int minCycle_
The earliest cycle to schedule moves in. Used to leave room for sched_yield() by the sched_yield() em...
int scheduleOperandWrites(int &cycle, MoveNodeGroup &moves)
static MoveNode * findTrigger(const ProgramOperation &po, const TTAMachine::Machine &mach)
void scheduleRRMove(MoveNode &moveNode)
const TTAMachine::Machine * targetMachine_
The target machine we are scheduling the program against.
virtual std::string shortDescription() const
void ddgSnapshot(DataDependenceGraph &ddg, const std::string &name, DataDependenceGraph::DumpFileFormat format, bool final, bool resetCounter=false) const
virtual void printStats() const
void handleRemovedResultMoves(std::set< std::pair< TTAProgram::Move *, int > > removedMoves)
void unscheduleInputOperandTempMoves(MoveNode &operandMove)
void scheduleRRTempMoves(MoveNode ®ToRegMove, MoveNode &firstMove, int lastUse)
void unscheduleAllNodes()
virtual int handleDDG(DataDependenceGraph &ddg, SimpleResourceManager &rm, const TTAMachine::Machine &targetMachine, int minCycle=0, bool testOnly=false) override
void scheduleInputOperandTempMoves(MoveNode &operandMove, MoveNode &operandWrite)
RegisterRenamer * renamer_
SimpleResourceManager * rm_
Resource Manager of the currently scheduled BB.
int getTriggerOperand(const Operation &operation, const TTAMachine::Machine &machine)
SoftwareBypasser * softwareBypasser_
The software bypasser to use to bypass registers when possible.
std::map< const MoveNode *, DataDependenceGraph::NodeSet > scheduledTempMoves_
Stores the MoveNodes that were scheduled as temp moves during scheduling of the operand move.
bool scheduleResultReads(MoveNodeGroup &moves)
bool tryToSwitchInputs(ProgramOperation &op)
bool tryToOptimizeWaw(const MoveNode &moveNode)
void tryToDelayOperands(MoveNodeGroup &moves)
void notifyScheduled(MoveNodeGroup &moves, MoveNodeSelector &selector)
void scheduleOperation(MoveNodeGroup &moves)
boost::timer schedulingTime_
Time for getting the scheduling time for current basic block.