LLVM: llvm::ModuloSchedule Class Reference (original) (raw)
Represents a schedule for a single-block loop. More...
#include "[llvm/CodeGen/ModuloSchedule.h](ModuloSchedule%5F8h%5Fsource.html)"
Public Member Functions | |
---|---|
ModuloSchedule (MachineFunction &MF, MachineLoop *Loop, std::vector< MachineInstr * > ScheduledInstrs, DenseMap< MachineInstr *, int > Cycle, DenseMap< MachineInstr *, int > Stage) | |
Create a new ModuloSchedule. | |
MachineLoop * | getLoop () const |
Return the single-block loop being scheduled. | |
int | getNumStages () const |
Return the number of stages contained in this schedule, which is the largest stage index + 1. | |
int | getFirstCycle () |
Return the first cycle in the schedule, which is the cycle index of the first instruction. | |
int | getFinalCycle () |
Return the final cycle in the schedule, which is the cycle index of the last instruction. | |
int | getStage (MachineInstr *MI) |
Return the stage that MI is scheduled in, or -1. | |
int | getCycle (MachineInstr *MI) |
Return the cycle that MI is scheduled at, or -1. | |
void | setStage (MachineInstr *MI, int MIStage) |
Set the stage of a newly created instruction. | |
ArrayRef< MachineInstr * > | getInstructions () |
Return the rescheduled instructions in order. | |
void | dump () |
void | print (raw_ostream &OS) |
Represents a schedule for a single-block loop.
For every instruction we maintain a Cycle and Stage.
Definition at line 80 of file ModuloSchedule.h.
Create a new ModuloSchedule.
- ScheduledInstrs The new loop instructions, in total resequenced order.
- Cycle Cycle index for all instructions in ScheduledInstrs. Cycle does not need to start at zero. ScheduledInstrs must be partially ordered by Cycle.
- Stage Stage index for all instructions in ScheduleInstrs.
Definition at line 107 of file ModuloSchedule.h.
◆ dump()
void llvm::ModuloSchedule::dump ( ) | inline |
---|
◆ getCycle()
int llvm::ModuloSchedule::getCycle ( MachineInstr * MI) | inline |
---|
◆ getFinalCycle()
int llvm::ModuloSchedule::getFinalCycle ( ) | inline |
---|
Return the final cycle in the schedule, which is the cycle index of the last instruction.
Definition at line 132 of file ModuloSchedule.h.
◆ getFirstCycle()
int llvm::ModuloSchedule::getFirstCycle ( ) | inline |
---|
Return the first cycle in the schedule, which is the cycle index of the first instruction.
Definition at line 128 of file ModuloSchedule.h.
◆ getInstructions()
◆ getLoop()
MachineLoop * llvm::ModuloSchedule::getLoop ( ) const | inline |
---|
◆ getNumStages()
int llvm::ModuloSchedule::getNumStages ( ) const | inline |
---|
◆ getStage()
int llvm::ModuloSchedule::getStage ( MachineInstr * MI) | inline |
---|
Return the stage that MI is scheduled in, or -1.
Definition at line 135 of file ModuloSchedule.h.
References llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT, BucketT >::end(), llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT, BucketT >::find(), I, and MI.
Referenced by llvm::ModuloScheduleTestAnnotater::annotate(), llvm::ModuloScheduleExpander::expand(), llvm::PeelingModuloScheduleExpander::getStage(), and print().
◆ print()
◆ setStage()
void llvm::ModuloSchedule::setStage ( MachineInstr * MI, int MIStage ) | inline |
---|
The documentation for this class was generated from the following files:
- include/llvm/CodeGen/ModuloSchedule.h
- lib/CodeGen/ModuloSchedule.cpp