14#ifndef LLVM_CODEGEN_MLREGALLOCEVICTIONADVISOR_H
15#define LLVM_CODEGEN_MLREGALLOCEVICTIONADVISOR_H
40 const int InstructionsIndex,
const int InstructionsMappingIndex,
41 const int MBBFreqIndex,
const int MBBMappingIndex,
45 const size_t CurrentInstructionIndex,
46 std::map<MachineBasicBlock *, size_t> &VisitedMBBs,
50 const int MBBMappingIndex);
MLModelRunner interface: abstraction of a mechanism for evaluating a ML model.
SlotIndex - An opaque wrapper around machine indexes.
This class consists of common code factored out of the SmallVector class to reduce code duplication b...
An efficient, type-erasing, non-owning reference to a callable.
This is an optimization pass for GlobalISel generic memory operations.
static const int ModelMaxSupportedInstructionCount
static const int64_t ModelMaxSupportedMBBCount
void extractInstructionFeatures(llvm::SmallVectorImpl< LRStartEndInfo > &LRPosInfo, MLModelRunner *RegallocRunner, function_ref< int(SlotIndex)> GetOpcode, function_ref< float(SlotIndex)> GetMBBFreq, function_ref< MachineBasicBlock *(SlotIndex)> GetMBBReference, const int InstructionsIndex, const int InstructionsMappingIndex, const int MBBFreqIndex, const int MBBMappingIndex, const SlotIndex LastIndex)
static const std::vector< int64_t > MBBFrequencyShape
static const int64_t MaxInterferences
static const std::vector< int64_t > InstructionsMappingShape
static const std::vector< int64_t > InstructionsShape
void extractMBBFrequency(const SlotIndex CurrentIndex, const size_t CurrentInstructionIndex, std::map< MachineBasicBlock *, size_t > &VisitedMBBs, function_ref< float(SlotIndex)> GetMBBFreq, MachineBasicBlock *CurrentMBBReference, MLModelRunner *RegallocRunner, const int MBBFreqIndex, const int MBBMappingIndex)
static const int64_t NumberOfInterferences
static const int64_t CandidateVirtRegPos