Changing the scheduling algorithm
The MachineSchedStrategy
class represents the scheduling algorithm used by a ScheduleDAGInstrs
class. You set up your strategy while you create your ScheduleDAGInstrs
instance in your TargetPassConfig::createMachineScheduler
method.
This class offers all the entry points to tweak every aspect of the scheduling algorithm, such as what to do when you start processing a new basic block (with the enterMBB
method) and what to do when you pick the next instruction to schedule (with the pickNode
method).
This class is a pure abstract class, and if you want to tweak the scheduling algorithm, we recommend that you start from its concrete subclasses that are used by default, respectively, for the pre-register-allocation scheduling with the GenericScheduler
class and for the post-register-allocation scheduling with the PostGenericScheduler
class.
These classes offer easier-to-override methods thanks to the strategically newly exposed methods. For...