gem5  v21.1.0.2
Classes | Public Member Functions | Private Attributes | List of all members
gem5::HWScheduler Class Reference

#include <hw_scheduler.hh>

Classes

class  SchedulerWakeupEvent
 

Public Member Functions

 HWScheduler (HSAPacketProcessor *hsa_pp, Tick wakeup_delay)
 
void write (Addr db_addr, uint64_t doorbell_reg)
 
void registerNewQueue (uint64_t hostReadIndexPointer, uint64_t basePointer, uint64_t queue_id, uint32_t size, int doorbellSize)
 
void unregisterQueue (uint64_t queue_id, int doorbellSize)
 
void wakeup ()
 
void schedWakeup ()
 
bool isRLQIdle (uint32_t rl_idx)
 
bool findNextActiveALQ ()
 
bool findNextIdleRLQ ()
 
bool unmapQFromRQ ()
 
bool contextSwitchQ ()
 
bool findEmptyHWQ ()
 
bool mapQIfSlotAvlbl (uint32_t al_idx, AQLRingBuffer *aql_buf, HSAQueueDescriptor *q_desc)
 
void addQCntxt (uint32_t al_idx, AQLRingBuffer *aql_buf, HSAQueueDescriptor *q_desc)
 
void removeQCntxt ()
 
void scheduleAndWakeupMappedQ ()
 
void updateRRVars (uint32_t al_idx, uint32_t rl_idx)
 

Private Attributes

std::map< uint32_t, QCntxtactiveList
 
std::map< Addr, uint32_t > dbMap
 
std::map< uint32_t, uint32_t > regdListMap
 
HSAPacketProcessorhsaPP
 
uint32_t nextALId
 
uint32_t nextRLId
 
const Tick wakeupDelay
 
SchedulerWakeupEvent schedWakeupEvent
 

Detailed Description

Definition at line 51 of file hw_scheduler.hh.

Constructor & Destructor Documentation

◆ HWScheduler()

gem5::HWScheduler::HWScheduler ( HSAPacketProcessor hsa_pp,
Tick  wakeup_delay 
)
inline

Definition at line 54 of file hw_scheduler.hh.

Member Function Documentation

◆ addQCntxt()

void gem5::HWScheduler::addQCntxt ( uint32_t  al_idx,
AQLRingBuffer aql_buf,
HSAQueueDescriptor q_desc 
)

◆ contextSwitchQ()

bool gem5::HWScheduler::contextSwitchQ ( )

◆ findEmptyHWQ()

bool gem5::HWScheduler::findEmptyHWQ ( )

◆ findNextActiveALQ()

bool gem5::HWScheduler::findNextActiveALQ ( )

Definition at line 260 of file hw_scheduler.cc.

References activeList, DPRINTF, MAX_ACTIVE_QUEUES, nextALId, and regdListMap.

Referenced by contextSwitchQ().

◆ findNextIdleRLQ()

bool gem5::HWScheduler::findNextIdleRLQ ( )

Definition at line 282 of file hw_scheduler.cc.

References hsaPP, isRLQIdle(), nextRLId, and gem5::HSAPacketProcessor::numHWQueues.

Referenced by unmapQFromRQ().

◆ isRLQIdle()

bool gem5::HWScheduler::isRLQIdle ( uint32_t  rl_idx)

◆ mapQIfSlotAvlbl()

bool gem5::HWScheduler::mapQIfSlotAvlbl ( uint32_t  al_idx,
AQLRingBuffer aql_buf,
HSAQueueDescriptor q_desc 
)

◆ registerNewQueue()

void gem5::HWScheduler::registerNewQueue ( uint64_t  hostReadIndexPointer,
uint64_t  basePointer,
uint64_t  queue_id,
uint32_t  size,
int  doorbellSize 
)

◆ removeQCntxt()

void gem5::HWScheduler::removeQCntxt ( )

◆ scheduleAndWakeupMappedQ()

void gem5::HWScheduler::scheduleAndWakeupMappedQ ( )

◆ schedWakeup()

void gem5::HWScheduler::schedWakeup ( )

◆ unmapQFromRQ()

bool gem5::HWScheduler::unmapQFromRQ ( )

Definition at line 228 of file hw_scheduler.cc.

References findNextIdleRLQ(), and removeQCntxt().

Referenced by contextSwitchQ().

◆ unregisterQueue()

void gem5::HWScheduler::unregisterQueue ( uint64_t  queue_id,
int  doorbellSize 
)

◆ updateRRVars()

void gem5::HWScheduler::updateRRVars ( uint32_t  al_idx,
uint32_t  rl_idx 
)

◆ wakeup()

void gem5::HWScheduler::wakeup ( )

Definition at line 60 of file hw_scheduler.cc.

References contextSwitchQ(), and schedWakeup().

Referenced by gem5::HWScheduler::SchedulerWakeupEvent::process().

◆ write()

void gem5::HWScheduler::write ( Addr  db_addr,
uint64_t  doorbell_reg 
)

Member Data Documentation

◆ activeList

std::map<uint32_t, QCntxt> gem5::HWScheduler::activeList
private

◆ dbMap

std::map<Addr, uint32_t> gem5::HWScheduler::dbMap
private

Definition at line 94 of file hw_scheduler.hh.

Referenced by registerNewQueue(), removeQCntxt(), unregisterQueue(), and write().

◆ hsaPP

HSAPacketProcessor* gem5::HWScheduler::hsaPP
private

◆ nextALId

uint32_t gem5::HWScheduler::nextALId
private

Definition at line 106 of file hw_scheduler.hh.

Referenced by contextSwitchQ(), findNextActiveALQ(), and updateRRVars().

◆ nextRLId

uint32_t gem5::HWScheduler::nextRLId
private

◆ regdListMap

std::map<uint32_t, uint32_t> gem5::HWScheduler::regdListMap
private

◆ schedWakeupEvent

SchedulerWakeupEvent gem5::HWScheduler::schedWakeupEvent
private

Definition at line 109 of file hw_scheduler.hh.

Referenced by schedWakeup().

◆ wakeupDelay

const Tick gem5::HWScheduler::wakeupDelay
private

Definition at line 108 of file hw_scheduler.hh.

Referenced by schedWakeup().


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

Generated on Tue Sep 21 2021 12:27:42 for gem5 by doxygen 1.8.17