LLVM 24.0.0git
MachineScheduler.cpp File Reference
#include "llvm/CodeGen/MachineScheduler.h"
#include "CodeGenOptions.h"
#include "llvm/ADT/ArrayRef.h"
#include "llvm/ADT/BitVector.h"
#include "llvm/ADT/DenseMap.h"
#include "llvm/ADT/EquivalenceClasses.h"
#include "llvm/ADT/PriorityQueue.h"
#include "llvm/ADT/STLExtras.h"
#include "llvm/ADT/SmallVector.h"
#include "llvm/ADT/Statistic.h"
#include "llvm/ADT/iterator_range.h"
#include "llvm/Analysis/AliasAnalysis.h"
#include "llvm/CodeGen/LiveInterval.h"
#include "llvm/CodeGen/LiveIntervals.h"
#include "llvm/CodeGen/MachineBasicBlock.h"
#include "llvm/CodeGen/MachineFrameInfo.h"
#include "llvm/CodeGen/MachineFunction.h"
#include "llvm/CodeGen/MachineFunctionPass.h"
#include "llvm/CodeGen/MachineInstr.h"
#include "llvm/CodeGen/MachineLoopInfo.h"
#include "llvm/CodeGen/MachineOperand.h"
#include "llvm/CodeGen/MachinePassRegistry.h"
#include "llvm/CodeGen/MachineRegisterInfo.h"
#include "llvm/CodeGen/RegisterClassInfo.h"
#include "llvm/CodeGen/RegisterPressure.h"
#include "llvm/CodeGen/ScheduleDAG.h"
#include "llvm/CodeGen/ScheduleDAGInstrs.h"
#include "llvm/CodeGen/ScheduleDAGMutation.h"
#include "llvm/CodeGen/ScheduleDFS.h"
#include "llvm/CodeGen/ScheduleHazardRecognizer.h"
#include "llvm/CodeGen/SlotIndexes.h"
#include "llvm/CodeGen/TargetFrameLowering.h"
#include "llvm/CodeGen/TargetInstrInfo.h"
#include "llvm/CodeGen/TargetLowering.h"
#include "llvm/CodeGen/TargetPassConfig.h"
#include "llvm/CodeGen/TargetRegisterInfo.h"
#include "llvm/CodeGen/TargetSchedule.h"
#include "llvm/CodeGen/TargetSubtargetInfo.h"
#include "llvm/CodeGenTypes/MachineValueType.h"
#include "llvm/Config/llvm-config.h"
#include "llvm/InitializePasses.h"
#include "llvm/MC/LaneBitmask.h"
#include "llvm/Pass.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/Compiler.h"
#include "llvm/Support/Debug.h"
#include "llvm/Support/ErrorHandling.h"
#include "llvm/Support/GraphWriter.h"
#include "llvm/Support/raw_ostream.h"
#include "llvm/Target/TargetMachine.h"
#include <algorithm>
#include <cassert>
#include <cstdint>
#include <iterator>
#include <limits>
#include <memory>
#include <string>
#include <tuple>
#include <utility>
#include <vector>

Go to the source code of this file.

Classes

class  llvm::impl_detail::MachineSchedulerBase
 Base class for the machine scheduler classes. More...
class  llvm::impl_detail::MachineSchedulerImpl
 Impl class for MachineScheduler. More...
struct  llvm::impl_detail::MachineSchedulerImpl::RequiredAnalyses
class  llvm::impl_detail::SSAMachineSchedulerImpl
 Impl class for SSAMachineScheduler. More...
struct  llvm::impl_detail::SSAMachineSchedulerImpl::RequiredAnalyses
class  llvm::impl_detail::PostMachineSchedulerImpl
 Impl class for PostMachineScheduler. More...
struct  llvm::impl_detail::PostMachineSchedulerImpl::RequiredAnalyses

Namespaces

namespace  llvm
 This is an optimization pass for GlobalISel generic memory operations.
namespace  llvm::impl_detail

Macros

#define DEBUG_TYPE   "machine-scheduler"

Typedefs

using MBBRegionsVector = SmallVector<SchedRegion, 16>

Functions

 STATISTIC (NumInstrsInSourceOrderPreRA, "Number of instructions in source order after pre-RA scheduling")
 STATISTIC (NumInstrsInSourceOrderPostRA, "Number of instructions in source order after post-RA scheduling")
 STATISTIC (NumInstrsScheduledPreRA, "Number of instructions scheduled by pre-RA scheduler")
 STATISTIC (NumInstrsScheduledPostRA, "Number of instructions scheduled by post-RA scheduler")
 STATISTIC (NumClustered, "Number of load/store pairs clustered")
 STATISTIC (NumTopPreRA, "Number of scheduling units chosen from top queue pre-RA")
 STATISTIC (NumBotPreRA, "Number of scheduling units chosen from bottom queue pre-RA")
 STATISTIC (NumNoCandPreRA, "Number of scheduling units chosen for NoCand heuristic pre-RA")
 STATISTIC (NumOnly1PreRA, "Number of scheduling units chosen for Only1 heuristic pre-RA")
 STATISTIC (NumPhysRegPreRA, "Number of scheduling units chosen for PhysReg heuristic pre-RA")
 STATISTIC (NumRegExcessPreRA, "Number of scheduling units chosen for RegExcess heuristic pre-RA")
 STATISTIC (NumRegCriticalPreRA, "Number of scheduling units chosen for RegCritical heuristic pre-RA")
 STATISTIC (NumStallPreRA, "Number of scheduling units chosen for Stall heuristic pre-RA")
 STATISTIC (NumClusterPreRA, "Number of scheduling units chosen for Cluster heuristic pre-RA")
 STATISTIC (NumWeakPreRA, "Number of scheduling units chosen for Weak heuristic pre-RA")
 STATISTIC (NumRegMaxPreRA, "Number of scheduling units chosen for RegMax heuristic pre-RA")
 STATISTIC (NumResourceReducePreRA, "Number of scheduling units chosen for ResourceReduce heuristic pre-RA")
 STATISTIC (NumResourceDemandPreRA, "Number of scheduling units chosen for ResourceDemand heuristic pre-RA")
 STATISTIC (NumTopDepthReducePreRA, "Number of scheduling units chosen for TopDepthReduce heuristic pre-RA")
 STATISTIC (NumTopPathReducePreRA, "Number of scheduling units chosen for TopPathReduce heuristic pre-RA")
 STATISTIC (NumBotHeightReducePreRA, "Number of scheduling units chosen for BotHeightReduce heuristic pre-RA")
 STATISTIC (NumBotPathReducePreRA, "Number of scheduling units chosen for BotPathReduce heuristic pre-RA")
 STATISTIC (NumNodeOrderPreRA, "Number of scheduling units chosen for NodeOrder heuristic pre-RA")
 STATISTIC (NumFirstValidPreRA, "Number of scheduling units chosen for FirstValid heuristic pre-RA")
 STATISTIC (NumTopPostRA, "Number of scheduling units chosen from top queue post-RA")
 STATISTIC (NumBotPostRA, "Number of scheduling units chosen from bottom queue post-RA")
 STATISTIC (NumNoCandPostRA, "Number of scheduling units chosen for NoCand heuristic post-RA")
 STATISTIC (NumOnly1PostRA, "Number of scheduling units chosen for Only1 heuristic post-RA")
 STATISTIC (NumPhysRegPostRA, "Number of scheduling units chosen for PhysReg heuristic post-RA")
 STATISTIC (NumRegExcessPostRA, "Number of scheduling units chosen for RegExcess heuristic post-RA")
 STATISTIC (NumRegCriticalPostRA, "Number of scheduling units chosen for RegCritical heuristic post-RA")
 STATISTIC (NumStallPostRA, "Number of scheduling units chosen for Stall heuristic post-RA")
 STATISTIC (NumClusterPostRA, "Number of scheduling units chosen for Cluster heuristic post-RA")
 STATISTIC (NumWeakPostRA, "Number of scheduling units chosen for Weak heuristic post-RA")
 STATISTIC (NumRegMaxPostRA, "Number of scheduling units chosen for RegMax heuristic post-RA")
 STATISTIC (NumResourceReducePostRA, "Number of scheduling units chosen for ResourceReduce heuristic post-RA")
 STATISTIC (NumResourceDemandPostRA, "Number of scheduling units chosen for ResourceDemand heuristic post-RA")
 STATISTIC (NumTopDepthReducePostRA, "Number of scheduling units chosen for TopDepthReduce heuristic post-RA")
 STATISTIC (NumTopPathReducePostRA, "Number of scheduling units chosen for TopPathReduce heuristic post-RA")
 STATISTIC (NumBotHeightReducePostRA, "Number of scheduling units chosen for BotHeightReduce heuristic post-RA")
 STATISTIC (NumBotPathReducePostRA, "Number of scheduling units chosen for BotPathReduce heuristic post-RA")
 STATISTIC (NumNodeOrderPostRA, "Number of scheduling units chosen for NodeOrder heuristic post-RA")
 STATISTIC (NumFirstValidPostRA, "Number of scheduling units chosen for FirstValid heuristic post-RA")
 INITIALIZE_PASS_BEGIN (MachineSchedulerLegacy, DEBUG_TYPE, "Machine Instruction Scheduler", false, false) INITIALIZE_PASS_DEPENDENCY(MachineBlockFrequencyInfoWrapperPass)
 INITIALIZE_PASS_END (MachineSchedulerLegacy, DEBUG_TYPE, "Machine Instruction Scheduler", false, false) MachineSchedulerLegacy
 INITIALIZE_PASS_BEGIN (SSAMachineSchedulerLegacy, "ssa-machine-scheduler", "SSA Machine Instruction Scheduler", false, false) INITIALIZE_PASS_DEPENDENCY(MachineBlockFrequencyInfoWrapperPass)
 INITIALIZE_PASS_END (SSAMachineSchedulerLegacy, "ssa-machine-scheduler", "SSA Machine Instruction Scheduler", false, false) SSAMachineSchedulerLegacy
 INITIALIZE_PASS_BEGIN (PostMachineSchedulerLegacy, "postmisched", "PostRA Machine Instruction Scheduler", false, false) INITIALIZE_PASS_END(PostMachineSchedulerLegacy
static ScheduleDAGInstrs * useDefaultMachineSched (MachineSchedContext *C)
 A dummy default scheduler factory indicates whether the scheduler is overridden on the command line.
static MachineBasicBlock::const_iterator priorNonDebug (MachineBasicBlock::const_iterator I, MachineBasicBlock::const_iterator Beg)
 Decrement this iterator until reaching the top or a non-debug instr.
static MachineBasicBlock::iterator priorNonDebug (MachineBasicBlock::iterator I, MachineBasicBlock::const_iterator Beg)
 Non-const version.
static MachineBasicBlock::const_iterator nextIfDebug (MachineBasicBlock::const_iterator I, MachineBasicBlock::const_iterator End)
 If this iterator is a debug value, increment until reaching the End or a non-debug instruction.
static MachineBasicBlock::iterator nextIfDebug (MachineBasicBlock::iterator I, MachineBasicBlock::const_iterator End)
 Non-const version.
static bool isSchedBoundary (MachineBasicBlock::iterator MI, MachineBasicBlock *MBB, MachineFunction *MF, const TargetInstrInfo *TII)
 Return true of the given instruction should not be included in a scheduling region.
static void getSchedRegions (MachineBasicBlock *MBB, MBBRegionsVector &Regions, bool RegionsTopDown)
static bool checkResourceLimit (unsigned LFactor, unsigned Count, unsigned Latency, bool AfterSchedNode)
 Given a Count of resource usage and a Latency value, return true if a SchedBoundary becomes resource limited.
static void tracePick (const SUnit *SU, const GenericSchedulerBase::CandReason Reason, const bool IsTop, const bool IsPostRA=false)
static void tracePick (const GenericSchedulerBase::SchedCandidate &Cand, const bool IsPostRA=false)
static ScheduleDAGInstrs * createConvergingSched (MachineSchedContext *C)
static ScheduleDAGInstrs * createILPMaxScheduler (MachineSchedContext *C)
static ScheduleDAGInstrs * createILPMinScheduler (MachineSchedContext *C)
static ScheduleDAGInstrs * createInstructionShuffler (MachineSchedContext *C)
static bool sortIntervals (const ResourceSegments::IntervalTy &A, const ResourceSegments::IntervalTy &B)
 Sort predicate for the intervals stored in an instance of ResourceSegments.

Variables

static cl::opt< TargetSubtargetInfo::AntiDepBreakMode > PostRABreakAntiDeps ("misched-postra-break-antideps", cl::Hidden, cl::desc("Set the post-RA MISched anti-dependency break mode"), cl::init(TargetSubtargetInfo::ANTIDEP_NONE), cl::values(clEnumValN(TargetSubtargetInfo::ANTIDEP_NONE, "none", "No anti-dependency breaking"), clEnumValN(TargetSubtargetInfo::ANTIDEP_CRITICAL, "critical", "Break critical-path anti-dependencies"), clEnumValN(TargetSubtargetInfo::ANTIDEP_ALL, "all", "Break all anti-dependencies")))
static const unsigned MinSubtreeSize = 8
 postmisched
PostRA Machine Instruction Scheduler
PostRA Machine Instruction false
static cl::opt< MachineSchedRegistry::ScheduleDAGCtor, false, RegisterPassParser< MachineSchedRegistry > > MachineSchedOpt ("misched", cl::init(&useDefaultMachineSched), cl::Hidden, cl::desc("Machine instruction scheduler to use"))
 MachineSchedOpt allows command line selection of the scheduler.
static MachineSchedRegistry DefaultSchedRegistry ("default", "Use the target's default scheduler choice.", useDefaultMachineSched)
static const char * scheduleTableLegend = " i: issue\n x: resource booked"
static const unsigned InvalidCycle = ~0U
static MachineSchedRegistry GenericSchedRegistry ("converge", "Standard converging scheduler.", createConvergingSched)
static MachineSchedRegistry ILPMaxRegistry ("ilpmax", "Schedule bottom-up for max ILP", createILPMaxScheduler)
static MachineSchedRegistry ILPMinRegistry ("ilpmin", "Schedule bottom-up for min ILP", createILPMinScheduler)
static MachineSchedRegistry ShufflerRegistry ("shuffle", "Shuffle machine instructions alternating directions", createInstructionShuffler)

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "machine-scheduler"

Definition at line 77 of file MachineScheduler.cpp.

Typedef Documentation

◆ MBBRegionsVector

Definition at line 855 of file MachineScheduler.cpp.

Function Documentation

◆ checkResourceLimit()

bool checkResourceLimit ( unsigned LFactor,
unsigned Count,
unsigned Latency,
bool AfterSchedNode )
static

Given a Count of resource usage and a Latency value, return true if a SchedBoundary becomes resource limited.

If we are checking after scheduling a node, we should return true when we just reach the resource limit.

Definition at line 2758 of file MachineScheduler.cpp.

References llvm::Count, and llvm::Latency.

Referenced by llvm::SchedBoundary::bumpCycle(), llvm::SchedBoundary::bumpNode(), and llvm::GenericSchedulerBase::setPolicy().

◆ createConvergingSched()

ScheduleDAGInstrs * createConvergingSched ( MachineSchedContext * C)
static

Definition at line 4629 of file MachineScheduler.cpp.

References C(), and llvm::createSchedLive().

◆ createILPMaxScheduler()

ScheduleDAGInstrs * createILPMaxScheduler ( MachineSchedContext * C)
static

Definition at line 5044 of file MachineScheduler.cpp.

References C().

◆ createILPMinScheduler()

ScheduleDAGInstrs * createILPMinScheduler ( MachineSchedContext * C)
static

Definition at line 5047 of file MachineScheduler.cpp.

References C().

◆ createInstructionShuffler()

ScheduleDAGInstrs * createInstructionShuffler ( MachineSchedContext * C)
static

◆ getSchedRegions()

◆ INITIALIZE_PASS_BEGIN() [1/3]

INITIALIZE_PASS_BEGIN ( MachineSchedulerLegacy ,
DEBUG_TYPE ,
"Machine Instruction Scheduler" ,
false ,
false  )

◆ INITIALIZE_PASS_BEGIN() [2/3]

INITIALIZE_PASS_BEGIN ( PostMachineSchedulerLegacy ,
"postmisched" ,
"PostRA Machine Instruction Scheduler" ,
false ,
false  )

◆ INITIALIZE_PASS_BEGIN() [3/3]

INITIALIZE_PASS_BEGIN ( SSAMachineSchedulerLegacy ,
"ssa-machine-scheduler" ,
"SSA Machine Instruction Scheduler" ,
false ,
false  )

◆ INITIALIZE_PASS_END() [1/2]

INITIALIZE_PASS_END ( MachineSchedulerLegacy ,
DEBUG_TYPE ,
"Machine Instruction Scheduler" ,
false ,
false  )

Definition at line 378 of file MachineScheduler.cpp.

References DEBUG_TYPE, and INITIALIZE_PASS_END.

◆ INITIALIZE_PASS_END() [2/2]

INITIALIZE_PASS_END ( SSAMachineSchedulerLegacy ,
"ssa-machine-scheduler" ,
"SSA Machine Instruction Scheduler" ,
false ,
false  )

◆ isSchedBoundary()

bool isSchedBoundary ( MachineBasicBlock::iterator MI,
MachineBasicBlock * MBB,
MachineFunction * MF,
const TargetInstrInfo * TII )
static

Return true of the given instruction should not be included in a scheduling region.

MachineScheduler does not currently support scheduling across calls. To handle calls, the DAG builder needs to be modified to create register anti/output dependencies on the registers clobbered by the call's regmask operand. In PreRA scheduling, the stack pointer adjustment already prevents scheduling across calls. In PostRA scheduling, we need the isCall to enforce the boundary, but there would be no benefit to postRA scheduling across calls this late anyway.

Definition at line 848 of file MachineScheduler.cpp.

References MBB, MI, and TII.

Referenced by getSchedRegions().

◆ nextIfDebug() [1/2]

If this iterator is a debug value, increment until reaching the End or a non-debug instruction.

Definition at line 495 of file MachineScheduler.cpp.

References llvm::End, and I.

Referenced by llvm::ScheduleDAGMI::initQueues(), nextIfDebug(), llvm::ScheduleDAGMI::schedule(), llvm::ScheduleDAGMILive::scheduleMI(), and llvm::ScheduleDAGMILive::updatePressureDiffs().

◆ nextIfDebug() [2/2]

◆ priorNonDebug() [1/2]

Decrement this iterator until reaching the top or a non-debug instr.

Definition at line 474 of file MachineScheduler.cpp.

References assert(), and I.

Referenced by llvm::ScheduleDAGMILive::initRegPressure(), priorNonDebug(), llvm::ScheduleDAGMI::schedule(), and llvm::ScheduleDAGMILive::scheduleMI().

◆ priorNonDebug() [2/2]

◆ sortIntervals()

Sort predicate for the intervals stored in an instance of ResourceSegments.

Intervals are always disjoint (no intersection for any pairs of intervals), therefore we can sort the totality of the intervals by looking only at the left boundary.

Definition at line 5244 of file MachineScheduler.cpp.

References A(), and B().

◆ STATISTIC() [1/43]

STATISTIC ( NumBotHeightReducePostRA ,
"Number of scheduling units chosen for BotHeightReduce heuristic post-RA"  )

◆ STATISTIC() [2/43]

STATISTIC ( NumBotHeightReducePreRA ,
"Number of scheduling units chosen for BotHeightReduce heuristic pre-RA"  )

◆ STATISTIC() [3/43]

STATISTIC ( NumBotPathReducePostRA ,
"Number of scheduling units chosen for BotPathReduce heuristic post-RA"  )

◆ STATISTIC() [4/43]

STATISTIC ( NumBotPathReducePreRA ,
"Number of scheduling units chosen for BotPathReduce heuristic pre-RA"  )

◆ STATISTIC() [5/43]

STATISTIC ( NumBotPostRA ,
"Number of scheduling units chosen from bottom queue post-RA"  )

◆ STATISTIC() [6/43]

STATISTIC ( NumBotPreRA ,
"Number of scheduling units chosen from bottom queue pre-RA"  )

◆ STATISTIC() [7/43]

STATISTIC ( NumClustered ,
"Number of load/store pairs clustered"  )

◆ STATISTIC() [8/43]

STATISTIC ( NumClusterPostRA ,
"Number of scheduling units chosen for Cluster heuristic post-RA"  )

◆ STATISTIC() [9/43]

STATISTIC ( NumClusterPreRA ,
"Number of scheduling units chosen for Cluster heuristic pre-RA"  )

◆ STATISTIC() [10/43]

STATISTIC ( NumFirstValidPostRA ,
"Number of scheduling units chosen for FirstValid heuristic post-RA"  )

◆ STATISTIC() [11/43]

STATISTIC ( NumFirstValidPreRA ,
"Number of scheduling units chosen for FirstValid heuristic pre-RA"  )

◆ STATISTIC() [12/43]

STATISTIC ( NumInstrsInSourceOrderPostRA ,
"Number of instructions in source order after post-RA scheduling"  )

◆ STATISTIC() [13/43]

STATISTIC ( NumInstrsInSourceOrderPreRA ,
"Number of instructions in source order after pre-RA scheduling"  )

◆ STATISTIC() [14/43]

STATISTIC ( NumInstrsScheduledPostRA ,
"Number of instructions scheduled by post-RA scheduler"  )

◆ STATISTIC() [15/43]

STATISTIC ( NumInstrsScheduledPreRA ,
"Number of instructions scheduled by pre-RA scheduler"  )

◆ STATISTIC() [16/43]

STATISTIC ( NumNoCandPostRA ,
"Number of scheduling units chosen for NoCand heuristic post-RA"  )

◆ STATISTIC() [17/43]

STATISTIC ( NumNoCandPreRA ,
"Number of scheduling units chosen for NoCand heuristic pre-RA"  )

◆ STATISTIC() [18/43]

STATISTIC ( NumNodeOrderPostRA ,
"Number of scheduling units chosen for NodeOrder heuristic post-RA"  )

◆ STATISTIC() [19/43]

STATISTIC ( NumNodeOrderPreRA ,
"Number of scheduling units chosen for NodeOrder heuristic pre-RA"  )

◆ STATISTIC() [20/43]

STATISTIC ( NumOnly1PostRA ,
"Number of scheduling units chosen for Only1 heuristic post-RA"  )

◆ STATISTIC() [21/43]

STATISTIC ( NumOnly1PreRA ,
"Number of scheduling units chosen for Only1 heuristic pre-RA"  )

◆ STATISTIC() [22/43]

STATISTIC ( NumPhysRegPostRA ,
"Number of scheduling units chosen for PhysReg heuristic post-RA"  )

◆ STATISTIC() [23/43]

STATISTIC ( NumPhysRegPreRA ,
"Number of scheduling units chosen for PhysReg heuristic pre-RA"  )

◆ STATISTIC() [24/43]

STATISTIC ( NumRegCriticalPostRA ,
"Number of scheduling units chosen for RegCritical heuristic post-RA"  )

◆ STATISTIC() [25/43]

STATISTIC ( NumRegCriticalPreRA ,
"Number of scheduling units chosen for RegCritical heuristic pre-RA"  )

◆ STATISTIC() [26/43]

STATISTIC ( NumRegExcessPostRA ,
"Number of scheduling units chosen for RegExcess heuristic post-RA"  )

◆ STATISTIC() [27/43]

STATISTIC ( NumRegExcessPreRA ,
"Number of scheduling units chosen for RegExcess heuristic pre-RA"  )

◆ STATISTIC() [28/43]

STATISTIC ( NumRegMaxPostRA ,
"Number of scheduling units chosen for RegMax heuristic post-RA"  )

◆ STATISTIC() [29/43]

STATISTIC ( NumRegMaxPreRA ,
"Number of scheduling units chosen for RegMax heuristic pre-RA"  )

◆ STATISTIC() [30/43]

STATISTIC ( NumResourceDemandPostRA ,
"Number of scheduling units chosen for ResourceDemand heuristic post-RA"  )

◆ STATISTIC() [31/43]

STATISTIC ( NumResourceDemandPreRA ,
"Number of scheduling units chosen for ResourceDemand heuristic pre-RA"  )

◆ STATISTIC() [32/43]

STATISTIC ( NumResourceReducePostRA ,
"Number of scheduling units chosen for ResourceReduce heuristic post-RA"  )

◆ STATISTIC() [33/43]

STATISTIC ( NumResourceReducePreRA ,
"Number of scheduling units chosen for ResourceReduce heuristic pre-RA"  )

◆ STATISTIC() [34/43]

STATISTIC ( NumStallPostRA ,
"Number of scheduling units chosen for Stall heuristic post-RA"  )

◆ STATISTIC() [35/43]

STATISTIC ( NumStallPreRA ,
"Number of scheduling units chosen for Stall heuristic pre-RA"  )

◆ STATISTIC() [36/43]

STATISTIC ( NumTopDepthReducePostRA ,
"Number of scheduling units chosen for TopDepthReduce heuristic post-RA"  )

◆ STATISTIC() [37/43]

STATISTIC ( NumTopDepthReducePreRA ,
"Number of scheduling units chosen for TopDepthReduce heuristic pre-RA"  )

◆ STATISTIC() [38/43]

STATISTIC ( NumTopPathReducePostRA ,
"Number of scheduling units chosen for TopPathReduce heuristic post-RA"  )

◆ STATISTIC() [39/43]

STATISTIC ( NumTopPathReducePreRA ,
"Number of scheduling units chosen for TopPathReduce heuristic pre-RA"  )

◆ STATISTIC() [40/43]

STATISTIC ( NumTopPostRA ,
"Number of scheduling units chosen from top queue post-RA"  )

◆ STATISTIC() [41/43]

STATISTIC ( NumTopPreRA ,
"Number of scheduling units chosen from top queue pre-RA"  )

◆ STATISTIC() [42/43]

STATISTIC ( NumWeakPostRA ,
"Number of scheduling units chosen for Weak heuristic post-RA"  )

◆ STATISTIC() [43/43]

STATISTIC ( NumWeakPreRA ,
"Number of scheduling units chosen for Weak heuristic pre-RA"  )

◆ tracePick() [1/2]

◆ tracePick() [2/2]

◆ useDefaultMachineSched()

ScheduleDAGInstrs * useDefaultMachineSched ( MachineSchedContext * C)
static

A dummy default scheduler factory indicates whether the scheduler is overridden on the command line.

Definition at line 457 of file MachineScheduler.cpp.

References C().

Referenced by llvm::impl_detail::MachineSchedulerImpl::createMachineScheduler().

Variable Documentation

◆ DefaultSchedRegistry

MachineSchedRegistry DefaultSchedRegistry("default", "Use the target's default scheduler choice.", useDefaultMachineSched) ( "default" ,
"Use the target's default scheduler choice." ,
useDefaultMachineSched  )
static

◆ false

PostRA Machine Instruction false

Definition at line 438 of file MachineScheduler.cpp.

◆ GenericSchedRegistry

MachineSchedRegistry GenericSchedRegistry("converge", "Standard converging scheduler.", createConvergingSched) ( "converge" ,
"Standard converging scheduler." ,
createConvergingSched  )
static

◆ ILPMaxRegistry

MachineSchedRegistry ILPMaxRegistry("ilpmax", "Schedule bottom-up for max ILP", createILPMaxScheduler) ( "ilpmax" ,
"Schedule bottom-up for max ILP" ,
createILPMaxScheduler  )
static

◆ ILPMinRegistry

MachineSchedRegistry ILPMinRegistry("ilpmin", "Schedule bottom-up for min ILP", createILPMinScheduler) ( "ilpmin" ,
"Schedule bottom-up for min ILP" ,
createILPMinScheduler  )
static

◆ InvalidCycle

◆ MachineSchedOpt

cl::opt< MachineSchedRegistry::ScheduleDAGCtor, false, RegisterPassParser< MachineSchedRegistry > > MachineSchedOpt("misched", cl::init(&useDefaultMachineSched), cl::Hidden, cl::desc("Machine instruction scheduler to use")) ( "misched" ,
cl::init & useDefaultMachineSched,
cl::Hidden ,
cl::desc("Machine instruction scheduler to use")  )
static

MachineSchedOpt allows command line selection of the scheduler.

Referenced by llvm::impl_detail::MachineSchedulerImpl::createMachineScheduler().

◆ MinSubtreeSize

const unsigned MinSubtreeSize = 8
static

Definition at line 216 of file MachineScheduler.cpp.

Referenced by llvm::ScheduleDAGMILive::computeDFSResult().

◆ postmisched

postmisched

Definition at line 437 of file MachineScheduler.cpp.

◆ PostRABreakAntiDeps

cl::opt< TargetSubtargetInfo::AntiDepBreakMode > PostRABreakAntiDeps("misched-postra-break-antideps", cl::Hidden, cl::desc("Set the post-RA MISched anti-dependency break mode"), cl::init(TargetSubtargetInfo::ANTIDEP_NONE), cl::values(clEnumValN(TargetSubtargetInfo::ANTIDEP_NONE, "none", "No anti-dependency breaking"), clEnumValN(TargetSubtargetInfo::ANTIDEP_CRITICAL, "critical", "Break critical-path anti-dependencies"), clEnumValN(TargetSubtargetInfo::ANTIDEP_ALL, "all", "Break all anti-dependencies"))) ( "misched-postra-break-antideps" ,
cl::Hidden ,
cl::desc("Set the post-RA MISched anti-dependency break mode") ,
cl::init(TargetSubtargetInfo::ANTIDEP_NONE) ,
cl::values(clEnumValN(TargetSubtargetInfo::ANTIDEP_NONE, "none", "No anti-dependency breaking"), clEnumValN(TargetSubtargetInfo::ANTIDEP_CRITICAL, "critical", "Break critical-path anti-dependencies"), clEnumValN(TargetSubtargetInfo::ANTIDEP_ALL, "all", "Break all anti-dependencies"))  )
static

◆ Scheduler

◆ scheduleTableLegend

const char* scheduleTableLegend = " i: issue\n x: resource booked"
static

◆ ShufflerRegistry

MachineSchedRegistry ShufflerRegistry("shuffle", "Shuffle machine instructions alternating directions", createInstructionShuffler) ( "shuffle" ,
"Shuffle machine instructions alternating directions" ,
createInstructionShuffler  )
static