class MachineSchedStrategy

Declaration

class MachineSchedStrategy { /* full declaration omitted */ };

Description

MachineSchedStrategy - Interface to the scheduling algorithm used by ScheduleDAGMI. Initialization sequence: initPolicy -> shouldTrackPressure -> initialize(DAG) -> registerRoots

Declared at: llvm/include/llvm/CodeGen/MachineScheduler.h:197

Method Overview

Methods

virtual bool doMBBSchedRegionsTopDown() const

Declared at: llvm/include/llvm/CodeGen/MachineScheduler.h:222

virtual void dumpPolicy() const

Declared at: llvm/include/llvm/CodeGen/MachineScheduler.h:208

virtual void enterMBB(
    llvm::MachineBasicBlock* MBB)

Description

Tell the strategy that MBB is about to be processed.

Declared at: llvm/include/llvm/CodeGen/MachineScheduler.h:228

Parameters

llvm::MachineBasicBlock* MBB

virtual void initPolicy(
    MachineBasicBlock::iterator Begin,
    MachineBasicBlock::iterator End,
    unsigned int NumRegionInstrs)

Description

Optionally override the per-region scheduling policy.

Declared at: llvm/include/llvm/CodeGen/MachineScheduler.h:204

Parameters

MachineBasicBlock::iterator Begin
MachineBasicBlock::iterator End
unsigned int NumRegionInstrs

virtual void initialize(llvm::ScheduleDAGMI* DAG)

Description

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

Declared at: llvm/include/llvm/CodeGen/MachineScheduler.h:225

Parameters

llvm::ScheduleDAGMI* DAG

virtual void leaveMBB()

Description

Tell the strategy that current MBB is done.

Declared at: llvm/include/llvm/CodeGen/MachineScheduler.h:231

virtual llvm::SUnit* pickNode(bool& IsTopNode)

Description

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.

Declared at: llvm/include/llvm/CodeGen/MachineScheduler.h:240

Parameters

bool& IsTopNode

virtual void registerRoots()

Description

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

Declared at: llvm/include/llvm/CodeGen/MachineScheduler.h:235

virtual void releaseBottomNode(llvm::SUnit* SU)

Description

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

Declared at: llvm/include/llvm/CodeGen/MachineScheduler.h:255

Parameters

llvm::SUnit* SU

virtual void releaseTopNode(llvm::SUnit* SU)

Description

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

Declared at: llvm/include/llvm/CodeGen/MachineScheduler.h:251

Parameters

llvm::SUnit* SU

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

Description

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

Declared at: llvm/include/llvm/CodeGen/MachineScheduler.h:247

Parameters

llvm::SUnit* SU
bool IsTopNode

virtual void scheduleTree(unsigned int SubtreeID)

Description

Scheduler callback to notify that a new subtree is scheduled.

Declared at: llvm/include/llvm/CodeGen/MachineScheduler.h:243

Parameters

unsigned int SubtreeID

virtual bool shouldTrackLaneMasks() const

Description

Returns true if lanemasks should be tracked. LaneMask tracking is necessary to reorder independent subregister defs for the same vreg. This has to be enabled in combination with shouldTrackPressure().

Declared at: llvm/include/llvm/CodeGen/MachineScheduler.h:217

virtual bool shouldTrackPressure() const

Description

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

Declared at: llvm/include/llvm/CodeGen/MachineScheduler.h:212

virtual ~MachineSchedStrategy()

Declared at: llvm/include/llvm/CodeGen/MachineScheduler.h:201