gem5 v24.0.0.0
Loading...
Searching...
No Matches
gem5::PM4PacketProcessor Class Reference

#include <pm4_packet_processor.hh>

Inheritance diagram for gem5::PM4PacketProcessor:
gem5::DmaVirtDevice gem5::DmaDevice gem5::PioDevice gem5::ClockedObject gem5::SimObject gem5::Clocked gem5::EventManager gem5::Serializable gem5::Drainable gem5::statistics::Group gem5::Named

Public Member Functions

 PM4PacketProcessor (const PM4PacketProcessorParams &p)
 
void setGPUDevice (AMDGPUDevice *gpu_device)
 
Tick write (PacketPtr pkt) override
 Inherited methods.
 
Tick read (PacketPtr pkt) override
 Pure virtual function that the device must implement.
 
AddrRangeList getAddrRanges () const override
 Every PIO device is obliged to provide an implementation that returns the address ranges the device responds to.
 
void serialize (CheckpointOut &cp) const override
 Serialize an object.
 
void unserialize (CheckpointIn &cp) override
 Unserialize an object.
 
TranslationGenPtr translate (Addr vaddr, Addr size) override
 Method for functional translation.
 
uint32_t getKiqDoorbellOffset ()
 
uint32_t getPqDoorbellOffset ()
 
Addr getGARTAddr (Addr addr) const
 
PM4QueuegetQueue (Addr offset, bool gfx=false)
 Based on an offset communicated through doorbell write, the PM4PacketProcessor identifies which queue needs processing.
 
void mapPq (Addr offset)
 The first graphics queue, the Primary Queueu a.k.a.
 
void mapKiq (Addr offset)
 The first compute queue, the Kernel Interface Queueu a.k.a.
 
void newQueue (QueueDesc *q, Addr offset, PM4MapQueues *pkt=nullptr, int id=-1)
 This method creates a new PM4Queue based on a queue descriptor and an offset.
 
void process (PM4Queue *q, Addr wptrOffset)
 This method start processing a PM4Queue from the current read pointer to the newly communicated write pointer (i.e., wptrOffset).
 
void updateReadIndex (Addr offset, uint64_t rd_idx)
 Update read index on doorbell rings.
 
void decodeNext (PM4Queue *q)
 This method decodes the next packet in a PM4Queue.
 
void decodeHeader (PM4Queue *q, PM4Header header)
 This method calls other PM4 packet processing methods based on the header of a PM4 packet.
 
void writeData (PM4Queue *q, PM4WriteData *pkt, PM4Header header)
 
void writeDataDone (PM4Queue *q, PM4WriteData *pkt, Addr addr)
 
void mapQueues (PM4Queue *q, PM4MapQueues *pkt)
 
void unmapQueues (PM4Queue *q, PM4UnmapQueues *pkt)
 
void doneMQDWrite (Addr mqdAddr, Addr addr)
 
void mapProcess (uint32_t pasid, uint64_t ptBase, uint32_t shMemBases)
 
void mapProcessV1 (PM4Queue *q, PM4MapProcess *pkt)
 
void mapProcessV2 (PM4Queue *q, PM4MapProcessV2 *pkt)
 
void processMQD (PM4MapQueues *pkt, PM4Queue *q, Addr addr, QueueDesc *mqd, uint16_t vmid)
 
void processSDMAMQD (PM4MapQueues *pkt, PM4Queue *q, Addr addr, SDMAQueueDesc *mqd, uint16_t vmid)
 
void releaseMem (PM4Queue *q, PM4ReleaseMem *pkt)
 
void releaseMemDone (PM4Queue *q, PM4ReleaseMem *pkt, Addr addr)
 
void runList (PM4Queue *q, PM4RunList *pkt)
 
void indirectBuffer (PM4Queue *q, PM4IndirectBuf *pkt)
 
void switchBuffer (PM4Queue *q, PM4SwitchBuf *pkt)
 
void setUconfigReg (PM4Queue *q, PM4SetUconfigReg *pkt)
 
void waitRegMem (PM4Queue *q, PM4WaitRegMem *pkt)
 
void queryStatus (PM4Queue *q, PM4QueryStatus *pkt)
 
void queryStatusDone (PM4Queue *q, PM4QueryStatus *pkt)
 
void writeMMIO (PacketPtr pkt, Addr mmio_offset)
 
void setHqdVmid (uint32_t data)
 
void setHqdActive (uint32_t data)
 
void setHqdPqBase (uint32_t data)
 
void setHqdPqBaseHi (uint32_t data)
 
void setHqdPqDoorbellCtrl (uint32_t data)
 
void setHqdPqPtr (uint32_t data)
 
void setHqdPqWptrLo (uint32_t data)
 
void setHqdPqWptrHi (uint32_t data)
 
void setHqdPqRptrReportAddr (uint32_t data)
 
void setHqdPqRptrReportAddrHi (uint32_t data)
 
void setHqdPqWptrPollAddr (uint32_t data)
 
void setHqdPqWptrPollAddrHi (uint32_t data)
 
void setHqdPqControl (uint32_t data)
 
void setHqdIbCtrl (uint32_t data)
 
void setRbVmid (uint32_t data)
 
void setRbCntl (uint32_t data)
 
void setRbWptrLo (uint32_t data)
 
void setRbWptrHi (uint32_t data)
 
void setRbRptrAddrLo (uint32_t data)
 
void setRbRptrAddrHi (uint32_t data)
 
void setRbWptrPollAddrLo (uint32_t data)
 
void setRbWptrPollAddrHi (uint32_t data)
 
void setRbBaseLo (uint32_t data)
 
void setRbBaseHi (uint32_t data)
 
void setRbDoorbellCntrl (uint32_t data)
 
void setRbDoorbellRangeLo (uint32_t data)
 
void setRbDoorbellRangeHi (uint32_t data)
 
int getIpId () const
 
AddrRange getMMIORange () const
 
- Public Member Functions inherited from gem5::DmaVirtDevice
 DmaVirtDevice (const Params &p)
 
virtual ~DmaVirtDevice ()
 
void dmaReadVirt (Addr host_addr, unsigned size, DmaCallback *cb, void *data, Tick delay=0)
 Initiate a DMA read from virtual address host_addr.
 
void dmaWriteVirt (Addr host_addr, unsigned size, DmaCallback *b, void *data, Tick delay=0)
 Initiate a DMA write from virtual address host_addr.
 
void dmaVirt (DmaFnPtr dmaFn, Addr host_addr, unsigned size, DmaCallback *cb, void *data, Tick delay=0)
 Initiate a call to DmaDevice using DmaFnPtr do a DMA starting from virtual address host_addr for size number of bytes on the data.
 
- Public Member Functions inherited from gem5::DmaDevice
 DmaDevice (const Params &p)
 
virtual ~DmaDevice ()=default
 
void dmaWrite (Addr addr, int size, Event *event, uint8_t *data, uint32_t sid, uint32_t ssid, Tick delay=0)
 
void dmaWrite (Addr addr, int size, Event *event, uint8_t *data, Tick delay=0)
 
void dmaRead (Addr addr, int size, Event *event, uint8_t *data, uint32_t sid, uint32_t ssid, Tick delay=0)
 
void dmaRead (Addr addr, int size, Event *event, uint8_t *data, Tick delay=0)
 
bool dmaPending () const
 
void init () override
 init() is called after all C++ SimObjects have been created and all ports are connected.
 
Addr cacheBlockSize () const
 
PortgetPort (const std::string &if_name, PortID idx=InvalidPortID) override
 Get a port with a given name and index.
 
- Public Member Functions inherited from gem5::PioDevice
 PioDevice (const Params &p)
 
virtual ~PioDevice ()
 
void init () override
 init() is called after all C++ SimObjects have been created and all ports are connected.
 
PortgetPort (const std::string &if_name, PortID idx=InvalidPortID) override
 Get a port with a given name and index.
 
- Public Member Functions inherited from gem5::ClockedObject
 ClockedObject (const ClockedObjectParams &p)
 
- Public Member Functions inherited from gem5::SimObject
const Paramsparams () const
 
 SimObject (const Params &p)
 
virtual ~SimObject ()
 
virtual void loadState (CheckpointIn &cp)
 loadState() is called on each SimObject when restoring from a checkpoint.
 
virtual void initState ()
 initState() is called on each SimObject when not restoring from a checkpoint.
 
virtual void regProbePoints ()
 Register probe points for this object.
 
virtual void regProbeListeners ()
 Register probe listeners for this object.
 
ProbeManagergetProbeManager ()
 Get the probe manager for this object.
 
virtual void startup ()
 startup() is the final initialization call before simulation.
 
DrainState drain () override
 Provide a default implementation of the drain interface for objects that don't need draining.
 
virtual void memWriteback ()
 Write back dirty buffers to memory using functional writes.
 
virtual void memInvalidate ()
 Invalidate the contents of memory buffers.
 
void serialize (CheckpointOut &cp) const override
 Serialize an object.
 
void unserialize (CheckpointIn &cp) override
 Unserialize an object.
 
- Public Member Functions inherited from gem5::EventManager
EventQueueeventQueue () const
 
void schedule (Event &event, Tick when)
 
void deschedule (Event &event)
 
void reschedule (Event &event, Tick when, bool always=false)
 
void schedule (Event *event, Tick when)
 
void deschedule (Event *event)
 
void reschedule (Event *event, Tick when, bool always=false)
 
void wakeupEventQueue (Tick when=(Tick) -1)
 This function is not needed by the usual gem5 event loop but may be necessary in derived EventQueues which host gem5 on other schedulers.
 
void setCurTick (Tick newVal)
 
 EventManager (EventManager &em)
 Event manger manages events in the event queue.
 
 EventManager (EventManager *em)
 
 EventManager (EventQueue *eq)
 
- Public Member Functions inherited from gem5::Serializable
 Serializable ()
 
virtual ~Serializable ()
 
void serializeSection (CheckpointOut &cp, const char *name) const
 Serialize an object into a new section.
 
void serializeSection (CheckpointOut &cp, const std::string &name) const
 
void unserializeSection (CheckpointIn &cp, const char *name)
 Unserialize an a child object.
 
void unserializeSection (CheckpointIn &cp, const std::string &name)
 
- Public Member Functions inherited from gem5::Drainable
DrainState drainState () const
 Return the current drain state of an object.
 
virtual void notifyFork ()
 Notify a child process of a fork.
 
- Public Member Functions inherited from gem5::statistics::Group
 Group (Group *parent, const char *name=nullptr)
 Construct a new statistics group.
 
virtual ~Group ()
 
virtual void regStats ()
 Callback to set stat parameters.
 
virtual void resetStats ()
 Callback to reset stats.
 
virtual void preDumpStats ()
 Callback before stats are dumped.
 
void addStat (statistics::Info *info)
 Register a stat with this group.
 
const std::map< std::string, Group * > & getStatGroups () const
 Get all child groups associated with this object.
 
const std::vector< Info * > & getStats () const
 Get all stats associated with this object.
 
void addStatGroup (const char *name, Group *block)
 Add a stat block as a child of this block.
 
const InforesolveStat (std::string name) const
 Resolve a stat by its name within this group.
 
void mergeStatGroup (Group *block)
 Merge the contents (stats & children) of a block to this block.
 
 Group ()=delete
 
 Group (const Group &)=delete
 
Groupoperator= (const Group &)=delete
 
- Public Member Functions inherited from gem5::Named
 Named (const std::string &name_)
 
virtual ~Named ()=default
 
virtual std::string name () const
 
- Public Member Functions inherited from gem5::Clocked
void updateClockPeriod ()
 Update the tick to the current tick.
 
Tick clockEdge (Cycles cycles=Cycles(0)) const
 Determine the tick when a cycle begins, by default the current one, but the argument also enables the caller to determine a future cycle.
 
Cycles curCycle () const
 Determine the current cycle, corresponding to a tick aligned to a clock edge.
 
Tick nextCycle () const
 Based on the clock of the object, determine the start tick of the first cycle that is at least one cycle in the future.
 
uint64_t frequency () const
 
Tick clockPeriod () const
 
double voltage () const
 
Cycles ticksToCycles (Tick t) const
 
Tick cyclesToTicks (Cycles c) const
 

Private Attributes

AMDGPUDevicegpuDevice
 
PrimaryQueue pq
 
PM4MapQueues pq_pkt
 
QueueDesc kiq
 
PM4MapQueues kiq_pkt
 
std::unordered_map< uint16_t, PM4Queue * > queues
 
std::unordered_map< uint32_t, PM4Queue * > queuesMap
 
int _ipId
 
AddrRange _mmioRange
 

Additional Inherited Members

- Public Types inherited from gem5::DmaVirtDevice
typedef void(DmaDevice::* DmaFnPtr) (Addr, int, Event *, uint8_t *, Tick)
 
- Public Types inherited from gem5::DmaDevice
typedef DmaDeviceParams Params
 
- Public Types inherited from gem5::PioDevice
using Params = PioDeviceParams
 
- Public Types inherited from gem5::ClockedObject
using Params = ClockedObjectParams
 Parameters of ClockedObject.
 
- Public Types inherited from gem5::SimObject
typedef SimObjectParams Params
 
- Static Public Member Functions inherited from gem5::SimObject
static void serializeAll (const std::string &cpt_dir)
 Create a checkpoint by serializing all SimObjects in the system.
 
static SimObjectfind (const char *name)
 Find the SimObject with the given name and return a pointer to it.
 
static void setSimObjectResolver (SimObjectResolver *resolver)
 There is a single object name resolver, and it is only set when simulation is restoring from checkpoints.
 
static SimObjectResolvergetSimObjectResolver ()
 There is a single object name resolver, and it is only set when simulation is restoring from checkpoints.
 
- Static Public Member Functions inherited from gem5::Serializable
static const std::string & currentSection ()
 Gets the fully-qualified name of the active section.
 
static void generateCheckpointOut (const std::string &cpt_dir, std::ofstream &outstream)
 Generate a checkpoint file so that the serialization can be routed to it.
 
- Public Attributes inherited from gem5::ClockedObject
PowerStatepowerState
 
- Protected Member Functions inherited from gem5::Drainable
 Drainable ()
 
virtual ~Drainable ()
 
virtual void drainResume ()
 Resume execution after a successful drain.
 
void signalDrainDone () const
 Signal that an object is drained.
 
- Protected Member Functions inherited from gem5::Clocked
 Clocked (ClockDomain &clk_domain)
 Create a clocked object and set the clock domain based on the parameters.
 
 Clocked (Clocked &)=delete
 
Clockedoperator= (Clocked &)=delete
 
virtual ~Clocked ()
 Virtual destructor due to inheritance.
 
void resetClock () const
 Reset the object's clock using the current global tick value.
 
virtual void clockPeriodUpdated ()
 A hook subclasses can implement so they can do any extra work that's needed when the clock rate is changed.
 
- Protected Attributes inherited from gem5::DmaDevice
DmaPort dmaPort
 
- Protected Attributes inherited from gem5::PioDevice
Systemsys
 
PioPort< PioDevicepioPort
 The pioPort that handles the requests for us and provides us requests that it sees.
 
- Protected Attributes inherited from gem5::SimObject
const SimObjectParams & _params
 Cached copy of the object parameters.
 
- Protected Attributes inherited from gem5::EventManager
EventQueueeventq
 A pointer to this object's event queue.
 

Detailed Description

Definition at line 52 of file pm4_packet_processor.hh.

Constructor & Destructor Documentation

◆ PM4PacketProcessor()

gem5::PM4PacketProcessor::PM4PacketProcessor ( const PM4PacketProcessorParams & p)

Definition at line 51 of file pm4_packet_processor.cc.

References kiq, and pq.

Member Function Documentation

◆ decodeHeader()

◆ decodeNext()

◆ doneMQDWrite()

void gem5::PM4PacketProcessor::doneMQDWrite ( Addr mqdAddr,
Addr addr )

Definition at line 679 of file pm4_packet_processor.cc.

References gem5::X86ISA::addr, and DPRINTF.

Referenced by unmapQueues().

◆ getAddrRanges()

AddrRangeList gem5::PM4PacketProcessor::getAddrRanges ( ) const
overridevirtual

Every PIO device is obliged to provide an implementation that returns the address ranges the device responds to.

Returns
a list of non-overlapping address ranges

Implements gem5::PioDevice.

Definition at line 79 of file pm4_packet_processor.cc.

◆ getGARTAddr()

Addr gem5::PM4PacketProcessor::getGARTAddr ( Addr addr) const

◆ getIpId()

int gem5::PM4PacketProcessor::getIpId ( ) const
inline

Definition at line 196 of file pm4_packet_processor.hh.

References _ipId.

Referenced by newQueue(), processSDMAMQD(), setUconfigReg(), and writeMMIO().

◆ getKiqDoorbellOffset()

uint32_t gem5::PM4PacketProcessor::getKiqDoorbellOffset ( )
inline

Definition at line 89 of file pm4_packet_processor.hh.

References gem5::GEM5_PACKED::doorbell, and kiq.

Referenced by writeMMIO().

◆ getMMIORange()

AddrRange gem5::PM4PacketProcessor::getMMIORange ( ) const
inline

Definition at line 197 of file pm4_packet_processor.hh.

References _mmioRange.

◆ getPqDoorbellOffset()

uint32_t gem5::PM4PacketProcessor::getPqDoorbellOffset ( )
inline

Definition at line 90 of file pm4_packet_processor.hh.

References gem5::PrimaryQueue::doorbellOffset, and pq.

Referenced by writeMMIO().

◆ getQueue()

PM4Queue * gem5::PM4PacketProcessor::getQueue ( Addr offset,
bool gfx = false )

Based on an offset communicated through doorbell write, the PM4PacketProcessor identifies which queue needs processing.

Definition at line 102 of file pm4_packet_processor.cc.

References mapKiq(), mapPq(), gem5::ArmISA::offset, and queuesMap.

◆ indirectBuffer()

void gem5::PM4PacketProcessor::indirectBuffer ( PM4Queue * q,
PM4IndirectBuf * pkt )

◆ mapKiq()

void gem5::PM4PacketProcessor::mapKiq ( Addr offset)

The first compute queue, the Kernel Interface Queueu a.k.a.

KIQ, needs to be mapped since all queue details are communicated through MMIOs to special registers.

Definition at line 116 of file pm4_packet_processor.cc.

References DPRINTF, kiq, kiq_pkt, newQueue(), and gem5::ArmISA::offset.

Referenced by getQueue().

◆ mapPq()

void gem5::PM4PacketProcessor::mapPq ( Addr offset)

The first graphics queue, the Primary Queueu a.k.a.

RB0, needs to be mapped since all queue details are communicated through MMIOs to special registers.

Definition at line 123 of file pm4_packet_processor.cc.

References DPRINTF, newQueue(), gem5::ArmISA::offset, pq, and pq_pkt.

Referenced by getQueue().

◆ mapProcess()

◆ mapProcessV1()

◆ mapProcessV2()

◆ mapQueues()

◆ newQueue()

void gem5::PM4PacketProcessor::newQueue ( QueueDesc * q,
Addr offset,
PM4MapQueues * pkt = nullptr,
int id = -1 )

◆ process()

void gem5::PM4PacketProcessor::process ( PM4Queue * q,
Addr wptrOffset )

This method start processing a PM4Queue from the current read pointer to the newly communicated write pointer (i.e., wptrOffset).

Definition at line 155 of file pm4_packet_processor.cc.

References decodeNext(), and gem5::ArmISA::q.

◆ processMQD()

◆ processSDMAMQD()

◆ queryStatus()

◆ queryStatusDone()

void gem5::PM4PacketProcessor::queryStatusDone ( PM4Queue * q,
PM4QueryStatus * pkt )

Definition at line 842 of file pm4_packet_processor.cc.

References decodeNext(), DPRINTF, and gem5::ArmISA::q.

Referenced by queryStatus().

◆ read()

Tick gem5::PM4PacketProcessor::read ( PacketPtr pkt)
inlineoverridevirtual

Pure virtual function that the device must implement.

Called when a read command is recieved by the port.

Parameters
pktPacket describing this request
Returns
number of ticks it took to complete

Implements gem5::PioDevice.

Definition at line 79 of file pm4_packet_processor.hh.

◆ releaseMem()

◆ releaseMemDone()

◆ runList()

void gem5::PM4PacketProcessor::runList ( PM4Queue * q,
PM4RunList * pkt )

◆ serialize()

void gem5::PM4PacketProcessor::serialize ( CheckpointOut & cp) const
overridevirtual

Serialize an object.

Output an object's state into the current checkpoint section.

Parameters
cpCheckpoint state

Reimplemented from gem5::ClockedObject.

Definition at line 1108 of file pm4_packet_processor.cc.

References gem5::X86ISA::base, gem5::ArmISA::i, gem5::PM4Queue::id(), gem5::PowerISA::me, gem5::ArmISA::offset, gem5::ArmISA::q, queues, gem5::ClockedObject::serialize(), SERIALIZE_ARRAY, and SERIALIZE_SCALAR.

◆ setGPUDevice()

void gem5::PM4PacketProcessor::setGPUDevice ( AMDGPUDevice * gpu_device)

Definition at line 86 of file pm4_packet_processor.cc.

References gpuDevice.

◆ setHqdActive()

void gem5::PM4PacketProcessor::setHqdActive ( uint32_t data)

Definition at line 951 of file pm4_packet_processor.cc.

References data, gem5::GEM5_PACKED::hqd_active, and kiq.

Referenced by writeMMIO().

◆ setHqdIbCtrl()

void gem5::PM4PacketProcessor::setHqdIbCtrl ( uint32_t data)

Definition at line 1023 of file pm4_packet_processor.cc.

References data, gem5::GEM5_PACKED::hqd_ib_control, and kiq.

Referenced by writeMMIO().

◆ setHqdPqBase()

void gem5::PM4PacketProcessor::setHqdPqBase ( uint32_t data)

Definition at line 957 of file pm4_packet_processor.cc.

References data, gem5::GEM5_PACKED::hqd_pq_base_lo, and kiq.

Referenced by writeMMIO().

◆ setHqdPqBaseHi()

void gem5::PM4PacketProcessor::setHqdPqBaseHi ( uint32_t data)

Definition at line 963 of file pm4_packet_processor.cc.

References data, gem5::GEM5_PACKED::hqd_pq_base_hi, and kiq.

Referenced by writeMMIO().

◆ setHqdPqControl()

void gem5::PM4PacketProcessor::setHqdPqControl ( uint32_t data)

Definition at line 1017 of file pm4_packet_processor.cc.

References data, gem5::GEM5_PACKED::hqd_pq_control, and kiq.

Referenced by writeMMIO().

◆ setHqdPqDoorbellCtrl()

void gem5::PM4PacketProcessor::setHqdPqDoorbellCtrl ( uint32_t data)

Definition at line 969 of file pm4_packet_processor.cc.

References data, gem5::GEM5_PACKED::hqd_pq_doorbell_control, and kiq.

Referenced by writeMMIO().

◆ setHqdPqPtr()

void gem5::PM4PacketProcessor::setHqdPqPtr ( uint32_t data)

Definition at line 975 of file pm4_packet_processor.cc.

References data, kiq, and gem5::GEM5_PACKED::rptr.

Referenced by writeMMIO().

◆ setHqdPqRptrReportAddr()

void gem5::PM4PacketProcessor::setHqdPqRptrReportAddr ( uint32_t data)

Definition at line 993 of file pm4_packet_processor.cc.

References data, gem5::GEM5_PACKED::hqd_pq_rptr_report_addr_lo, and kiq.

Referenced by writeMMIO().

◆ setHqdPqRptrReportAddrHi()

void gem5::PM4PacketProcessor::setHqdPqRptrReportAddrHi ( uint32_t data)

Definition at line 999 of file pm4_packet_processor.cc.

References data, gem5::GEM5_PACKED::hqd_pq_rptr_report_addr_hi, and kiq.

Referenced by writeMMIO().

◆ setHqdPqWptrHi()

void gem5::PM4PacketProcessor::setHqdPqWptrHi ( uint32_t data)

Definition at line 987 of file pm4_packet_processor.cc.

Referenced by writeMMIO().

◆ setHqdPqWptrLo()

void gem5::PM4PacketProcessor::setHqdPqWptrLo ( uint32_t data)

Definition at line 981 of file pm4_packet_processor.cc.

Referenced by writeMMIO().

◆ setHqdPqWptrPollAddr()

void gem5::PM4PacketProcessor::setHqdPqWptrPollAddr ( uint32_t data)

Definition at line 1005 of file pm4_packet_processor.cc.

References data, gem5::GEM5_PACKED::hqd_pq_wptr_poll_addr_lo, and kiq.

Referenced by writeMMIO().

◆ setHqdPqWptrPollAddrHi()

void gem5::PM4PacketProcessor::setHqdPqWptrPollAddrHi ( uint32_t data)

Definition at line 1011 of file pm4_packet_processor.cc.

References data, gem5::GEM5_PACKED::hqd_pq_wptr_poll_addr_hi, and kiq.

Referenced by writeMMIO().

◆ setHqdVmid()

void gem5::PM4PacketProcessor::setHqdVmid ( uint32_t data)

Definition at line 945 of file pm4_packet_processor.cc.

References data, gem5::GEM5_PACKED::hqd_vmid, and kiq.

Referenced by writeMMIO().

◆ setRbBaseHi()

void gem5::PM4PacketProcessor::setRbBaseHi ( uint32_t data)

Definition at line 1083 of file pm4_packet_processor.cc.

References data, gem5::GEM5_PACKED::hqd_pq_base_hi, and pq.

Referenced by writeMMIO().

◆ setRbBaseLo()

void gem5::PM4PacketProcessor::setRbBaseLo ( uint32_t data)

Definition at line 1077 of file pm4_packet_processor.cc.

References data, gem5::GEM5_PACKED::hqd_pq_base_lo, and pq.

Referenced by writeMMIO().

◆ setRbCntl()

void gem5::PM4PacketProcessor::setRbCntl ( uint32_t data)

Definition at line 1035 of file pm4_packet_processor.cc.

References data, gem5::GEM5_PACKED::hqd_pq_control, and pq.

Referenced by writeMMIO().

◆ setRbDoorbellCntrl()

void gem5::PM4PacketProcessor::setRbDoorbellCntrl ( uint32_t data)

◆ setRbDoorbellRangeHi()

void gem5::PM4PacketProcessor::setRbDoorbellRangeHi ( uint32_t data)

Definition at line 1102 of file pm4_packet_processor.cc.

References data, gem5::PrimaryQueue::doorbellRangeHi, and pq.

Referenced by writeMMIO().

◆ setRbDoorbellRangeLo()

void gem5::PM4PacketProcessor::setRbDoorbellRangeLo ( uint32_t data)

Definition at line 1096 of file pm4_packet_processor.cc.

References data, gem5::PrimaryQueue::doorbellRangeLo, and pq.

Referenced by writeMMIO().

◆ setRbRptrAddrHi()

void gem5::PM4PacketProcessor::setRbRptrAddrHi ( uint32_t data)

Definition at line 1059 of file pm4_packet_processor.cc.

References data, pq, and gem5::PrimaryQueue::queueRptrAddrHi.

Referenced by writeMMIO().

◆ setRbRptrAddrLo()

void gem5::PM4PacketProcessor::setRbRptrAddrLo ( uint32_t data)

Definition at line 1053 of file pm4_packet_processor.cc.

References data, pq, and gem5::PrimaryQueue::queueRptrAddrLo.

Referenced by writeMMIO().

◆ setRbVmid()

void gem5::PM4PacketProcessor::setRbVmid ( uint32_t data)

Definition at line 1029 of file pm4_packet_processor.cc.

References data, gem5::GEM5_PACKED::hqd_vmid, and pq.

Referenced by writeMMIO().

◆ setRbWptrHi()

void gem5::PM4PacketProcessor::setRbWptrHi ( uint32_t data)

Definition at line 1047 of file pm4_packet_processor.cc.

References data, pq, and gem5::PrimaryQueue::queueWptrHi.

Referenced by writeMMIO().

◆ setRbWptrLo()

void gem5::PM4PacketProcessor::setRbWptrLo ( uint32_t data)

Definition at line 1041 of file pm4_packet_processor.cc.

References data, pq, and gem5::PrimaryQueue::queueWptrLo.

Referenced by writeMMIO().

◆ setRbWptrPollAddrHi()

void gem5::PM4PacketProcessor::setRbWptrPollAddrHi ( uint32_t data)

Definition at line 1071 of file pm4_packet_processor.cc.

References data, gem5::GEM5_PACKED::hqd_pq_wptr_poll_addr_hi, and pq.

Referenced by writeMMIO().

◆ setRbWptrPollAddrLo()

void gem5::PM4PacketProcessor::setRbWptrPollAddrLo ( uint32_t data)

Definition at line 1065 of file pm4_packet_processor.cc.

References data, gem5::GEM5_PACKED::hqd_pq_wptr_poll_addr_lo, and pq.

Referenced by writeMMIO().

◆ setUconfigReg()

◆ switchBuffer()

void gem5::PM4PacketProcessor::switchBuffer ( PM4Queue * q,
PM4SwitchBuf * pkt )

Definition at line 768 of file pm4_packet_processor.cc.

References decodeNext(), DPRINTF, and gem5::ArmISA::q.

Referenced by decodeHeader().

◆ translate()

TranslationGenPtr gem5::PM4PacketProcessor::translate ( Addr vaddr,
Addr size )
overridevirtual

Method for functional translation.

AMDGPUDevice will perform DMA operations on VAs, and because page faults are not currently supported for Vega 10, we must be able to find the pages mapped for the process.

Implements gem5::DmaVirtDevice.

Definition at line 64 of file pm4_packet_processor.cc.

References gem5::AMDGPUDevice::getVM(), gpuDevice, gem5::AMDGPUVM::inAGP(), and gem5::MipsISA::vaddr.

◆ unmapQueues()

◆ unserialize()

◆ updateReadIndex()

void gem5::PM4PacketProcessor::updateReadIndex ( Addr offset,
uint64_t rd_idx )

Update read index on doorbell rings.

We use write index, however read index == write index when the queue is empty. This allows us to save previous read index when a queue is remapped. The remapped queue will read from the previous read index rather than reset to zero.

Definition at line 583 of file pm4_packet_processor.cc.

References gem5::ArmISA::offset, and queuesMap.

◆ waitRegMem()

◆ write()

Tick gem5::PM4PacketProcessor::write ( PacketPtr pkt)
inlineoverridevirtual

Inherited methods.

Implements gem5::PioDevice.

Definition at line 78 of file pm4_packet_processor.hh.

◆ writeData()

◆ writeDataDone()

void gem5::PM4PacketProcessor::writeDataDone ( PM4Queue * q,
PM4WriteData * pkt,
Addr addr )

◆ writeMMIO()

Member Data Documentation

◆ _ipId

int gem5::PM4PacketProcessor::_ipId
private

Definition at line 67 of file pm4_packet_processor.hh.

Referenced by getIpId().

◆ _mmioRange

AddrRange gem5::PM4PacketProcessor::_mmioRange
private

Definition at line 68 of file pm4_packet_processor.hh.

Referenced by getMMIORange().

◆ gpuDevice

◆ kiq

◆ kiq_pkt

PM4MapQueues gem5::PM4PacketProcessor::kiq_pkt
private

Definition at line 60 of file pm4_packet_processor.hh.

Referenced by mapKiq().

◆ pq

◆ pq_pkt

PM4MapQueues gem5::PM4PacketProcessor::pq_pkt
private

Definition at line 57 of file pm4_packet_processor.hh.

Referenced by mapPq().

◆ queues

std::unordered_map<uint16_t, PM4Queue *> gem5::PM4PacketProcessor::queues
private

Definition at line 63 of file pm4_packet_processor.hh.

Referenced by newQueue(), serialize(), unmapQueues(), and unserialize().

◆ queuesMap

std::unordered_map<uint32_t, PM4Queue *> gem5::PM4PacketProcessor::queuesMap
private

Definition at line 65 of file pm4_packet_processor.hh.

Referenced by getQueue(), newQueue(), processMQD(), and updateReadIndex().


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

Generated on Tue Jun 18 2024 16:24:13 for gem5 by doxygen 1.11.0