|
LLVM 24.0.0git
|
HardwareUnitInfo is a wrapper class which maps to some real hardware resource. More...
#include "Target/AMDGPU/AMDGPUCoExecSchedStrategy.h"
Public Member Functions | |
| HardwareUnitInfo () | |
| unsigned | size () |
| unsigned | getTotalCycles () |
| void | setType (unsigned TheType) |
| AMDGPU::InstructionFlavor | getType () const |
| bool | producesCoexecWindow () const |
| void | setProducesCoexecWindow (bool Val) |
| bool | contains (SUnit *SU) const |
| void | setBufferSize (unsigned Size) |
| unsigned | getBufferSize () |
| unsigned | getBufferAvailableCycle (unsigned CurrCycle) |
| SUnit * | getLastScheduledSU () |
| SUnit * | getHigherPriority (SUnit *SU, SUnit *Other) const |
| void | reset () |
| SUnit * | getNextTargetSU (bool LookDeep=false) const |
| void | insert (SUnit *SU, unsigned BlockingCycles) |
Insert the SU into AllSUs and account its BlockingCycles into the TotalCycles. | |
| void | markScheduled (SUnit *SU, unsigned BlockingCycles) |
Update the state for SU being scheduled by removing it from the AllSUs and reducing its BlockingCycles from the TotalCycles. | |
| void | finalizeCycles () |
| After we've collected all the region pressure for this HWUI, correct for any specifics of the behavior of this resource. | |
HardwareUnitInfo is a wrapper class which maps to some real hardware resource.
This is used to model hardware resource pressure per region, and guide scheduling heuristics.
Definition at line 68 of file AMDGPUCoExecSchedStrategy.h.
|
inline |
Definition at line 113 of file AMDGPUCoExecSchedStrategy.h.
Definition at line 130 of file AMDGPUCoExecSchedStrategy.h.
Referenced by llvm::CandidateHeuristics::tryCriticalResource().
| void HardwareUnitInfo::finalizeCycles | ( | ) |
After we've collected all the region pressure for this HWUI, correct for any specifics of the behavior of this resource.
For example, if the HardwareUnit can hold N instructions simultaneously, then there is no penalty for scheduling N instructions back to back.
Definition at line 532 of file AMDGPUCoExecSchedStrategy.cpp.
Definition at line 137 of file AMDGPUCoExecSchedStrategy.h.
Referenced by llvm::CandidateHeuristics::getStallCosts().
|
inline |
Definition at line 134 of file AMDGPUCoExecSchedStrategy.h.
Referenced by llvm::CandidateHeuristics::getStallCosts().
Definition at line 163 of file AMDGPUCoExecSchedStrategy.h.
References llvm::Other.
Referenced by llvm::CandidateHeuristics::tryCriticalResource().
|
inline |
Definition at line 151 of file AMDGPUCoExecSchedStrategy.h.
Referenced by llvm::CandidateHeuristics::getStallCosts().
LookDeep is set, we will look beyond the PrioritySUs (if all the PrioritySUs are ready) to AllSUs to attempt to find a target SU. When looking through AllSUs we sort pick the target SU by minimal depth for top-down scheduling. getNextTargetSU is useful for determining which SU on this HardwareUnit we are trying to schedule - this info helps us determine which dependencies to schedule. LookDeep is useful if the dependencies are long latency (e.g. memory instructions). If we have many long latency dependencies, it is beneficial to enable SUs multiple levels ahead. Definition at line 440 of file AMDGPUCoExecSchedStrategy.cpp.
Referenced by llvm::CandidateHeuristics::tryCriticalResourceDependency().
|
inline |
Definition at line 117 of file AMDGPUCoExecSchedStrategy.h.
|
inline |
Definition at line 124 of file AMDGPUCoExecSchedStrategy.h.
Referenced by llvm::CandidateHeuristics::tryCriticalResource(), and llvm::CandidateHeuristics::tryCriticalResourceDependency().
Insert the SU into AllSUs and account its BlockingCycles into the TotalCycles.
This maintains the list of PrioritySUs.
Definition at line 466 of file AMDGPUCoExecSchedStrategy.cpp.
References llvm::SUnit::getDepth(), and llvm_unreachable.
Update the state for SU being scheduled by removing it from the AllSUs and reducing its BlockingCycles from the TotalCycles.
This maintains the list of PrioritySUs.
Definition at line 491 of file AMDGPUCoExecSchedStrategy.cpp.
References llvm::SUnit::getDepth().
Referenced by llvm::CandidateHeuristics::updateForScheduling().
|
inline |
Definition at line 126 of file AMDGPUCoExecSchedStrategy.h.
|
inline |
Definition at line 174 of file AMDGPUCoExecSchedStrategy.h.
References llvm::AMDGPU::Other.
|
inline |
Definition at line 132 of file AMDGPUCoExecSchedStrategy.h.
References Size.
|
inline |
Definition at line 128 of file AMDGPUCoExecSchedStrategy.h.
|
inline |
Definition at line 119 of file AMDGPUCoExecSchedStrategy.h.
References assert(), and llvm::AMDGPU::NUM_FLAVORS.
|
inline |
Definition at line 115 of file AMDGPUCoExecSchedStrategy.h.