LLVM API Documentation

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | List of all members
llvm::MachineSchedStrategy Class Referenceabstract

#include <MachineScheduler.h>

Inheritance diagram for llvm::MachineSchedStrategy:
Inheritance graph
[legend]

Public Member Functions

virtual ~MachineSchedStrategy ()
 
virtual void initPolicy (MachineBasicBlock::iterator Begin, MachineBasicBlock::iterator End, unsigned NumRegionInstrs)
 Optionally override the per-region scheduling policy. More...
 
virtual bool shouldTrackPressure () const
 
virtual void initialize (ScheduleDAGMI *DAG)=0
 Initialize the strategy after building the DAG for a new region. More...
 
virtual void registerRoots ()
 
virtual SUnitpickNode (bool &IsTopNode)=0
 
virtual void scheduleTree (unsigned SubtreeID)
 Scheduler callback to notify that a new subtree is scheduled. More...
 
virtual void schedNode (SUnit *SU, bool IsTopNode)=0
 
virtual void releaseTopNode (SUnit *SU)=0
 
virtual void releaseBottomNode (SUnit *SU)=0
 

Detailed Description

MachineSchedStrategy - Interface to the scheduling algorithm used by ScheduleDAGMI.

Initialization sequence: initPolicy -> shouldTrackPressure -> initialize(DAG) -> registerRoots

Definition at line 166 of file MachineScheduler.h.

Constructor & Destructor Documentation

virtual llvm::MachineSchedStrategy::~MachineSchedStrategy ( )
inlinevirtual

Definition at line 169 of file MachineScheduler.h.

Member Function Documentation

virtual void llvm::MachineSchedStrategy::initialize ( ScheduleDAGMI DAG)
pure virtual

Initialize the strategy after building the DAG for a new region.

Implemented in llvm::ConvergingVLIWScheduler, and llvm::R600SchedStrategy.

Referenced by llvm::VLIWMachineScheduler::schedule(), and llvm::ScheduleDAGMI::schedule().

virtual void llvm::MachineSchedStrategy::initPolicy ( MachineBasicBlock::iterator  Begin,
MachineBasicBlock::iterator  End,
unsigned  NumRegionInstrs 
)
inlinevirtual

Optionally override the per-region scheduling policy.

Definition at line 172 of file MachineScheduler.h.

Referenced by llvm::ScheduleDAGMI::enterRegion().

virtual SUnit* llvm::MachineSchedStrategy::pickNode ( bool IsTopNode)
pure virtual

Pick the next node to schedule, or return NULL. Set IsTopNode to true to schedule the node at the top of the unscheduled region. Otherwise it will be scheduled at the bottom.

Implemented in llvm::ConvergingVLIWScheduler, and llvm::R600SchedStrategy.

Referenced by llvm::VLIWMachineScheduler::schedule(), and llvm::ScheduleDAGMI::schedule().

virtual void llvm::MachineSchedStrategy::registerRoots ( )
inlinevirtual

Notify this strategy that all roots have been released (including those that depend on EntrySU or ExitSU).

Definition at line 185 of file MachineScheduler.h.

Referenced by llvm::ScheduleDAGMI::initQueues().

virtual void llvm::MachineSchedStrategy::releaseBottomNode ( SUnit SU)
pure virtual

When all successor dependencies have been resolved, free this node for bottom-up scheduling.

Implemented in llvm::ConvergingVLIWScheduler, and llvm::R600SchedStrategy.

Referenced by llvm::ScheduleDAGMI::initQueues(), and llvm::ScheduleDAGMI::releasePred().

virtual void llvm::MachineSchedStrategy::releaseTopNode ( SUnit SU)
pure virtual

When all predecessor dependencies have been resolved, free this node for top-down scheduling.

Implemented in llvm::ConvergingVLIWScheduler, and llvm::R600SchedStrategy.

Referenced by llvm::ScheduleDAGMI::initQueues(), and llvm::ScheduleDAGMI::releaseSucc().

virtual void llvm::MachineSchedStrategy::schedNode ( SUnit SU,
bool  IsTopNode 
)
pure virtual

Notify MachineSchedStrategy that ScheduleDAGMI has scheduled an instruction and updated scheduled/remaining flags in the DAG nodes.

Implemented in llvm::ConvergingVLIWScheduler, and llvm::R600SchedStrategy.

Referenced by llvm::ScheduleDAGMI::updateQueues().

virtual void llvm::MachineSchedStrategy::scheduleTree ( unsigned  SubtreeID)
inlinevirtual

Scheduler callback to notify that a new subtree is scheduled.

Definition at line 193 of file MachineScheduler.h.

Referenced by llvm::ScheduleDAGMI::updateQueues().

virtual bool llvm::MachineSchedStrategy::shouldTrackPressure ( ) const
inlinevirtual

Check if pressure tracking is needed before building the DAG and initializing this strategy. Called after initPolicy.

Definition at line 178 of file MachineScheduler.h.

Referenced by llvm::ScheduleDAGMI::enterRegion().


The documentation for this class was generated from the following files: