LLVM  10.0.0svn
Public Member Functions | List of all members
llvm::VLIWResourceModel Class Reference

#include "Target/Hexagon/HexagonMachineScheduler.h"

Public Member Functions

 VLIWResourceModel (const TargetSubtargetInfo &STI, const TargetSchedModel *SM)
 ~VLIWResourceModel ()
void resetPacketState ()
void resetDFA ()
void reset ()
bool isResourceAvailable (SUnit *SU, bool IsTop)
 Check if scheduling of this SU is possible in the current packet. More...
bool reserveResources (SUnit *SU, bool IsTop)
 Keep track of available resources. More...
unsigned getTotalPackets () const
bool isInPacket (SUnit *SU) const

Detailed Description

Definition at line 35 of file HexagonMachineScheduler.h.

Constructor & Destructor Documentation

◆ VLIWResourceModel()

llvm::VLIWResourceModel::VLIWResourceModel ( const TargetSubtargetInfo STI,
const TargetSchedModel SM 

◆ ~VLIWResourceModel()

llvm::VLIWResourceModel::~VLIWResourceModel ( )

Definition at line 64 of file HexagonMachineScheduler.h.

Member Function Documentation

◆ getTotalPackets()

unsigned llvm::VLIWResourceModel::getTotalPackets ( ) const

Definition at line 83 of file HexagonMachineScheduler.h.

◆ isInPacket()

bool llvm::VLIWResourceModel::isInPacket ( SUnit SU) const

Definition at line 84 of file HexagonMachineScheduler.h.

References llvm::is_contained().

◆ isResourceAvailable()

bool VLIWResourceModel::isResourceAvailable ( SUnit SU,
bool  IsTop 

Check if scheduling of this SU is possible in the current packet.

It is not precise (statefull), it is more like another heuristic. Many corner cases are figured empirically.

Definition at line 97 of file HexagonMachineScheduler.cpp.

References llvm::DFAPacketizer::canReserveResources(), llvm::numbers::e, llvm::SUnit::getInstr(), llvm::HexagonSubtarget::getInstrInfo(), llvm::MachineInstr::getOpcode(), llvm::MachineBasicBlock::getParent(), llvm::MachineInstr::getParent(), llvm::MachineFunction::getSubtarget(), hasDependence(), llvm::ISD::INLINEASM, and llvm::ISD::INLINEASM_BR.

Referenced by reserveResources(), and reset().

◆ reserveResources()

bool VLIWResourceModel::reserveResources ( SUnit SU,
bool  IsTop 

◆ reset()

void llvm::VLIWResourceModel::reset ( )

◆ resetDFA()

void llvm::VLIWResourceModel::resetDFA ( )

Definition at line 72 of file HexagonMachineScheduler.h.

References llvm::DFAPacketizer::clearResources().

◆ resetPacketState()

void llvm::VLIWResourceModel::resetPacketState ( )

Definition at line 68 of file HexagonMachineScheduler.h.

The documentation for this class was generated from the following files: