gem5 v24.0.0.0
Loading...
Searching...
No Matches
gem5::ruby::AbstractController Class Referenceabstract

#include <AbstractController.hh>

Inheritance diagram for gem5::ruby::AbstractController:
gem5::ClockedObject gem5::ruby::Consumer gem5::SimObject gem5::Clocked gem5::EventManager gem5::Serializable gem5::Drainable gem5::statistics::Group gem5::Named

Classes

struct  ControllerStats
 
class  MemoryPort
 Port that forwards requests and receives responses from the memory controller. More...
 
struct  SenderState
 
struct  TransMapPair
 

Public Member Functions

 PARAMS (RubyController)
 
 AbstractController (const Params &p)
 
void init ()
 init() is called after all C++ SimObjects have been created and all ports are connected.
 
NodeID getVersion () const
 
MachineType getType () const
 
void initNetworkPtr (Network *net_ptr)
 
void blockOnQueue (Addr, MessageBuffer *)
 
bool isBlocked (Addr) const
 
void unblock (Addr)
 
bool isBlocked (Addr)
 
virtual MessageBuffergetMandatoryQueue () const =0
 
virtual MessageBuffergetMemReqQueue () const =0
 
virtual MessageBuffergetMemRespQueue () const =0
 
void memRespQueueDequeued ()
 
void dequeueMemRespQueue ()
 
virtual AccessPermission getAccessPermission (const Addr &addr)=0
 
virtual void print (std::ostream &out) const =0
 
virtual void wakeup ()=0
 
virtual void resetStats ()=0
 Callback to reset stats.
 
virtual void regStats ()
 Callback to set stat parameters.
 
virtual void recordCacheTrace (int cntrl, CacheRecorder *tr)=0
 
virtual SequencergetCPUSequencer () const =0
 
virtual DMASequencergetDMASequencer () const =0
 
virtual GPUCoalescergetGPUCoalescer () const =0
 
virtual Cycles mandatoryQueueLatency (const RubyRequestType &param_type)
 
virtual bool functionalReadBuffers (PacketPtr &)=0
 These functions are used by ruby system to read/write the data blocks that exist with in the controller.
 
virtual void functionalRead (const Addr &addr, PacketPtr)
 
virtual bool functionalReadBuffers (PacketPtr &, WriteMask &mask)=0
 Functional read that reads only blocks not present in the mask.
 
virtual void functionalRead (const Addr &addr, PacketPtr pkt, WriteMask &mask)
 
void functionalMemoryRead (PacketPtr)
 
virtual int functionalWriteBuffers (PacketPtr &)=0
 The return value indicates the number of messages written with the data from the packet.
 
virtual int functionalWrite (const Addr &addr, PacketPtr)=0
 
int functionalMemoryWrite (PacketPtr)
 
virtual void enqueuePrefetch (const Addr &, const RubyRequestType &)
 Function for enqueuing a prefetch request.
 
virtual void notifyCoalesced (const Addr &addr, const RubyRequestType &type, const RequestPtr &req, const DataBlock &data_blk, const bool &was_miss)
 Notifies controller of a request coalesced at the sequencer.
 
virtual void collateStats ()
 Function for collating statistics from all the controllers of this particular type.
 
virtual void initNetQueues ()=0
 Initialize the message buffers.
 
PortgetPort (const std::string &if_name, PortID idx=InvalidPortID)
 A function used to return the port associated with this bus object.
 
bool recvTimingResp (PacketPtr pkt)
 
Tick recvAtomic (PacketPtr pkt)
 
const AddrRangeListgetAddrRanges () const
 
MachineID getMachineID () const
 
RequestorID getRequestorId () const
 
statistics::HistogramgetDelayHist ()
 
statistics::HistogramgetDelayVCHist (uint32_t index)
 
bool respondsTo (Addr addr)
 
MachineID mapAddressToMachine (Addr addr, MachineType mtype) const
 Map an address to the correct MachineID.
 
MachineID mapAddressToDownstreamMachine (Addr addr, MachineType mtype=MachineType_NUM) const
 Maps an address to the correct dowstream MachineID (i.e.
 
const NetDestallDownstreamDest () const
 List of downstream destinations (towards memory)
 
const NetDestallUpstreamDest () const
 List of upstream destinations (towards the CPU)
 
- Public Member Functions inherited from gem5::ClockedObject
 ClockedObject (const ClockedObjectParams &p)
 
void serialize (CheckpointOut &cp) const override
 Serialize an object.
 
void unserialize (CheckpointIn &cp) override
 Unserialize an object.
 
- 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 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
 
- Public Member Functions inherited from gem5::ruby::Consumer
 Consumer (ClockedObject *em, Event::Priority ev_prio=Event::Default_Pri)
 
virtual ~Consumer ()
 
virtual void storeEventInfo (int info)
 
bool alreadyScheduled (Tick time)
 
ClockedObjectgetObject ()
 
void scheduleEventAbsolute (Tick timeAbs)
 
void scheduleEvent (Cycles timeDelta)
 

Public Attributes

gem5::ruby::AbstractController::ControllerStats stats
 
- Public Attributes inherited from gem5::ClockedObject
PowerStatepowerState
 

Protected Types

typedef std::vector< MessageBuffer * > MsgVecType
 
typedef std::set< MessageBuffer * > MsgBufType
 
typedef std::map< Addr, MsgVecType * > WaitingBufType
 

Protected Member Functions

void profileRequest (const std::string &request)
 Profiles original cache requests including PUTs.
 
void profileMsgDelay (uint32_t virtualNetwork, Cycles delay)
 Profiles the delay associated with messages.
 
template<typename EventType , typename StateType >
void incomingTransactionStart (Addr addr, EventType type, StateType initialState, bool retried, bool isAddressed=true)
 Profiles an event that initiates a protocol transactions for a specific line (e.g.
 
template<typename StateType >
void incomingTransactionEnd (Addr addr, StateType finalState, bool isAddressed=true)
 Profiles an event that ends a transaction.
 
template<typename EventType >
void outgoingTransactionStart (Addr addr, EventType type, bool isAddressed=true)
 Profiles an event that initiates a transaction in a peer controller (e.g.
 
void outgoingTransactionEnd (Addr addr, bool retried, bool isAddressed=true)
 Profiles the end of an outgoing transaction.
 
void stallBuffer (MessageBuffer *buf, Addr addr)
 
void wakeUpBuffer (MessageBuffer *buf, Addr addr)
 
void wakeUpBuffers (Addr addr)
 
void wakeUpAllBuffers (Addr addr)
 
void wakeUpAllBuffers ()
 
bool serviceMemoryQueue ()
 
virtual bool inCache (const Addr &addr, const bool &is_secure)
 Functions needed by CacheAccessor.
 
virtual bool hasBeenPrefetched (const Addr &addr, const bool &is_secure)
 
virtual bool hasBeenPrefetched (const Addr &addr, const bool &is_secure, const RequestorID &requestor)
 
virtual bool inMissQueue (const Addr &addr, const bool &is_secure)
 
virtual bool coalesce ()
 
- 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

std::unordered_map< Addr, TransMapPairm_inTransAddressed
 
std::unordered_map< Addr, TransMapPairm_outTransAddressed
 
std::unordered_map< Addr, TransMapPairm_inTransUnaddressed
 
std::unordered_map< Addr, TransMapPairm_outTransUnaddressed
 
const NodeID m_version
 
MachineID m_machineID
 
const NodeID m_clusterID
 
const RequestorID m_id
 
Networkm_net_ptr
 
bool m_is_blocking
 
std::map< Addr, MessageBuffer * > m_block_map
 
WaitingBufType m_waiting_buffers
 
unsigned int m_in_ports
 
unsigned int m_cur_in_port
 
const int m_number_of_TBEs
 
const int m_transitions_per_cycle
 
const unsigned int m_buffer_size
 
Cycles m_recycle_latency
 
const Cycles m_mandatory_queue_latency
 
bool m_waiting_mem_retry
 
bool m_mem_ctrl_waiting_retry
 
MemoryPort memoryPort
 
- 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.
 

Private Member Functions

void sendRetryRespToMem ()
 

Private Attributes

const AddrRangeList addrRanges
 The address range to which the controller responds on the CPU side.
 
std::unordered_map< MachineType, AddrRangeMap< MachineID, 3 > > downstreamAddrMap
 
NetDest downstreamDestinations
 
NetDest upstreamDestinations
 
MemberEventWrapper<&AbstractController::sendRetryRespToMemmRetryRespEvent
 

Friends

class RubyPrefetcherProxy
 

Additional Inherited Members

- 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.
 

Detailed Description

Definition at line 83 of file AbstractController.hh.

Member Typedef Documentation

◆ MsgBufType

Definition at line 405 of file AbstractController.hh.

◆ MsgVecType

◆ WaitingBufType

Definition at line 406 of file AbstractController.hh.

Constructor & Destructor Documentation

◆ AbstractController()

gem5::ruby::AbstractController::AbstractController ( const Params & p)

Member Function Documentation

◆ allDownstreamDest()

const NetDest & gem5::ruby::AbstractController::allDownstreamDest ( ) const
inline

List of downstream destinations (towards memory)

Definition at line 227 of file AbstractController.hh.

References downstreamDestinations.

◆ allUpstreamDest()

const NetDest & gem5::ruby::AbstractController::allUpstreamDest ( ) const
inline

List of upstream destinations (towards the CPU)

Definition at line 230 of file AbstractController.hh.

References upstreamDestinations.

◆ blockOnQueue()

void gem5::ruby::AbstractController::blockOnQueue ( Addr addr,
MessageBuffer * port )

◆ coalesce()

virtual bool gem5::ruby::AbstractController::coalesce ( )
inlineprotectedvirtual

Definition at line 387 of file AbstractController.hh.

References fatal.

Referenced by gem5::ruby::RubyPrefetcherProxy::coalesce().

◆ collateStats()

virtual void gem5::ruby::AbstractController::collateStats ( )
inlinevirtual

Function for collating statistics from all the controllers of this particular type.

This function should only be called from the version 0 of this controller type.

Definition at line 167 of file AbstractController.hh.

References fatal.

Referenced by AbstractController().

◆ dequeueMemRespQueue()

void gem5::ruby::AbstractController::dequeueMemRespQueue ( )

◆ enqueuePrefetch()

virtual void gem5::ruby::AbstractController::enqueuePrefetch ( const Addr & ,
const RubyRequestType &  )
inlinevirtual

Function for enqueuing a prefetch request.

Definition at line 152 of file AbstractController.hh.

References fatal.

Referenced by gem5::ruby::RubyPrefetcher::initializeStream(), and gem5::ruby::RubyPrefetcher::issueNextPrefetch().

◆ functionalMemoryRead()

void gem5::ruby::AbstractController::functionalMemoryRead ( PacketPtr pkt)

◆ functionalMemoryWrite()

int gem5::ruby::AbstractController::functionalMemoryWrite ( PacketPtr pkt)

Definition at line 364 of file AbstractController.cc.

References memoryPort, and gem5::RequestPort::sendFunctional().

◆ functionalRead() [1/2]

virtual void gem5::ruby::AbstractController::functionalRead ( const Addr & addr,
PacketPtr pkt,
WriteMask & mask )
inlinevirtual

Definition at line 140 of file AbstractController.hh.

References panic.

◆ functionalRead() [2/2]

virtual void gem5::ruby::AbstractController::functionalRead ( const Addr & addr,
PacketPtr  )
inlinevirtual

Definition at line 134 of file AbstractController.hh.

References panic.

Referenced by gem5::ruby::RubySystem::functionalRead().

◆ functionalReadBuffers() [1/2]

virtual bool gem5::ruby::AbstractController::functionalReadBuffers ( PacketPtr & )
pure virtual

These functions are used by ruby system to read/write the data blocks that exist with in the controller.

◆ functionalReadBuffers() [2/2]

virtual bool gem5::ruby::AbstractController::functionalReadBuffers ( PacketPtr & ,
WriteMask & mask )
pure virtual

Functional read that reads only blocks not present in the mask.

Return number of bytes read.

◆ functionalWrite()

virtual int gem5::ruby::AbstractController::functionalWrite ( const Addr & addr,
PacketPtr  )
pure virtual

◆ functionalWriteBuffers()

virtual int gem5::ruby::AbstractController::functionalWriteBuffers ( PacketPtr & )
pure virtual

The return value indicates the number of messages written with the data from the packet.

◆ getAccessPermission()

virtual AccessPermission gem5::ruby::AbstractController::getAccessPermission ( const Addr & addr)
pure virtual

◆ getAddrRanges()

const AddrRangeList & gem5::ruby::AbstractController::getAddrRanges ( ) const
inline

Definition at line 180 of file AbstractController.hh.

References addrRanges.

Referenced by gem5::ruby::Network::Network().

◆ getCPUSequencer()

virtual Sequencer * gem5::ruby::AbstractController::getCPUSequencer ( ) const
pure virtual

◆ getDelayHist()

statistics::Histogram & gem5::ruby::AbstractController::getDelayHist ( )
inline

◆ getDelayVCHist()

statistics::Histogram & gem5::ruby::AbstractController::getDelayVCHist ( uint32_t index)
inline

◆ getDMASequencer()

virtual DMASequencer * gem5::ruby::AbstractController::getDMASequencer ( ) const
pure virtual

◆ getGPUCoalescer()

virtual GPUCoalescer * gem5::ruby::AbstractController::getGPUCoalescer ( ) const
pure virtual

◆ getMachineID()

MachineID gem5::ruby::AbstractController::getMachineID ( ) const
inline

◆ getMandatoryQueue()

virtual MessageBuffer * gem5::ruby::AbstractController::getMandatoryQueue ( ) const
pure virtual

◆ getMemReqQueue()

virtual MessageBuffer * gem5::ruby::AbstractController::getMemReqQueue ( ) const
pure virtual

◆ getMemRespQueue()

virtual MessageBuffer * gem5::ruby::AbstractController::getMemRespQueue ( ) const
pure virtual

◆ getPort()

Port & gem5::ruby::AbstractController::getPort ( const std::string & if_name,
PortID idx = InvalidPortID )
virtual

A function used to return the port associated with this bus object.

Reimplemented from gem5::SimObject.

Definition at line 349 of file AbstractController.cc.

References memoryPort.

◆ getRequestorId()

RequestorID gem5::ruby::AbstractController::getRequestorId ( ) const
inline

Definition at line 184 of file AbstractController.hh.

References m_id.

◆ getType()

MachineType gem5::ruby::AbstractController::getType ( ) const
inline

◆ getVersion()

NodeID gem5::ruby::AbstractController::getVersion ( ) const
inline

◆ hasBeenPrefetched() [1/2]

virtual bool gem5::ruby::AbstractController::hasBeenPrefetched ( const Addr & addr,
const bool & is_secure )
inlineprotectedvirtual

◆ hasBeenPrefetched() [2/2]

virtual bool gem5::ruby::AbstractController::hasBeenPrefetched ( const Addr & addr,
const bool & is_secure,
const RequestorID & requestor )
inlineprotectedvirtual

Definition at line 380 of file AbstractController.hh.

References fatal.

◆ inCache()

virtual bool gem5::ruby::AbstractController::inCache ( const Addr & addr,
const bool & is_secure )
inlineprotectedvirtual

Functions needed by CacheAccessor.

These are implemented in SLICC, thus the const& for all args to match the generated code.

Definition at line 374 of file AbstractController.hh.

References fatal.

Referenced by gem5::ruby::RubyPrefetcherProxy::inCache().

◆ incomingTransactionEnd()

template<typename StateType >
void gem5::ruby::AbstractController::incomingTransactionEnd ( Addr addr,
StateType finalState,
bool isAddressed = true )
inlineprotected

Profiles an event that ends a transaction.

This function also supports "unaddressed" transactions, those not associated with an address in memory but instead associated with a unique ID.

Parameters
addraddress or unique ID with an outstanding transaction
finalStatestate of the line after the transaction
isAddressedis addr a line address or a unique ID

Definition at line 284 of file AbstractController.hh.

References gem5::X86ISA::addr, gem5::curTick(), gem5_assert, gem5::ruby::AbstractController::ControllerStats::inTransLatHist, gem5::ruby::AbstractController::ControllerStats::inTransStateChanges, m_inTransAddressed, m_inTransUnaddressed, gem5::Named::name(), stats, and gem5::Clocked::ticksToCycles().

◆ incomingTransactionStart()

template<typename EventType , typename StateType >
void gem5::ruby::AbstractController::incomingTransactionStart ( Addr addr,
EventType type,
StateType initialState,
bool retried,
bool isAddressed = true )
inlineprotected

Profiles an event that initiates a protocol transactions for a specific line (e.g.

events triggered by incoming request messages). A histogram with the latency of the transactions is generated for all combinations of trigger event, initial state, and final state. This function also supports "unaddressed" transactions, those not associated with an address in memory but instead associated with a unique ID.

Parameters
addraddress of the line, or unique transaction ID
typeevent that started the transaction
initialStatestate of the line before the transaction
isAddressedis addr a line address or a unique ID

Definition at line 261 of file AbstractController.hh.

References gem5::X86ISA::addr, gem5::curTick(), gem5::ruby::AbstractController::ControllerStats::inTransRetryCnt, m_inTransAddressed, m_inTransUnaddressed, stats, and gem5::X86ISA::type.

◆ init()

void gem5::ruby::AbstractController::init ( )
virtual

◆ initNetQueues()

virtual void gem5::ruby::AbstractController::initNetQueues ( )
pure virtual

Initialize the message buffers.

◆ initNetworkPtr()

void gem5::ruby::AbstractController::initNetworkPtr ( Network * net_ptr)
inline

Definition at line 93 of file AbstractController.hh.

References m_net_ptr.

Referenced by gem5::ruby::Network::Network().

◆ inMissQueue()

virtual bool gem5::ruby::AbstractController::inMissQueue ( const Addr & addr,
const bool & is_secure )
inlineprotectedvirtual

Definition at line 384 of file AbstractController.hh.

References fatal.

Referenced by gem5::ruby::RubyPrefetcherProxy::inMissQueue().

◆ isBlocked() [1/2]

bool gem5::ruby::AbstractController::isBlocked ( Addr addr)

Definition at line 343 of file AbstractController.cc.

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

◆ isBlocked() [2/2]

bool gem5::ruby::AbstractController::isBlocked ( Addr addr) const

Definition at line 328 of file AbstractController.cc.

References gem5::X86ISA::addr, m_block_map, and m_is_blocking.

Referenced by gem5::ruby::Sequencer::makeRequest().

◆ mandatoryQueueLatency()

virtual Cycles gem5::ruby::AbstractController::mandatoryQueueLatency ( const RubyRequestType & param_type)
inlinevirtual

◆ mapAddressToDownstreamMachine()

MachineID gem5::ruby::AbstractController::mapAddressToDownstreamMachine ( Addr addr,
MachineType mtype = MachineType_NUM ) const

Maps an address to the correct dowstream MachineID (i.e.

the component in the next level of the cache hierarchy towards memory)

This function uses the local list of possible destinations instead of querying the network.

Parameters
thedestination address
thetype of the destination (optional)
Returns
the MachineID of the destination

Definition at line 427 of file AbstractController.cc.

References gem5::X86ISA::addr, downstreamAddrMap, fatal, gem5::ArmISA::i, and gem5::Named::name().

◆ mapAddressToMachine()

MachineID gem5::ruby::AbstractController::mapAddressToMachine ( Addr addr,
MachineType mtype ) const

Map an address to the correct MachineID.

This function querries the network for the NodeID of the destination for a given request using its address and the type of the destination. For example for a request with a given address to a directory it will return the MachineID of the authorative directory.

Parameters
thedestination address
thetype of the destination
Returns
the MachineID of the destination

Definition at line 419 of file AbstractController.cc.

References gem5::X86ISA::addr, gem5::ruby::Network::addressToNodeID(), and m_net_ptr.

◆ memRespQueueDequeued()

void gem5::ruby::AbstractController::memRespQueueDequeued ( )

◆ notifyCoalesced()

virtual void gem5::ruby::AbstractController::notifyCoalesced ( const Addr & addr,
const RubyRequestType & type,
const RequestPtr & req,
const DataBlock & data_blk,
const bool & was_miss )
inlinevirtual

Notifies controller of a request coalesced at the sequencer.

By default, it does nothing. Behavior is protocol-specific

Definition at line 157 of file AbstractController.hh.

Referenced by gem5::ruby::Sequencer::hitCallback().

◆ outgoingTransactionEnd()

void gem5::ruby::AbstractController::outgoingTransactionEnd ( Addr addr,
bool retried,
bool isAddressed = true )
inlineprotected

Profiles the end of an outgoing transaction.

(e.g. receiving the response for a requests) This function also supports "unaddressed" transactions, those not associated with an address in memory but instead associated with a unique ID.

Parameters
addraddress of the line with an outstanding transaction
isAddressedis addr a line address or a unique ID

Definition at line 342 of file AbstractController.hh.

References gem5::X86ISA::addr, gem5::curTick(), gem5_assert, m_outTransAddressed, m_outTransUnaddressed, gem5::Named::name(), gem5::ruby::AbstractController::ControllerStats::outTransLatHist, gem5::ruby::AbstractController::ControllerStats::outTransRetryCnt, stats, and gem5::Clocked::ticksToCycles().

◆ outgoingTransactionStart()

template<typename EventType >
void gem5::ruby::AbstractController::outgoingTransactionStart ( Addr addr,
EventType type,
bool isAddressed = true )
inlineprotected

Profiles an event that initiates a transaction in a peer controller (e.g.

an event that sends a request message) This function also supports "unaddressed" transactions, those not associated with an address in memory but instead associated with a unique ID.

Parameters
addraddress of the line or a unique transaction ID
typeevent that started the transaction
isAddressedis addr a line address or a unique ID

Definition at line 323 of file AbstractController.hh.

References gem5::X86ISA::addr, gem5::curTick(), m_outTransAddressed, m_outTransUnaddressed, and gem5::X86ISA::type.

◆ PARAMS()

gem5::ruby::AbstractController::PARAMS ( RubyController )

◆ print()

virtual void gem5::ruby::AbstractController::print ( std::ostream & out) const
pure virtual

Implements gem5::ruby::Consumer.

◆ profileMsgDelay()

void gem5::ruby::AbstractController::profileMsgDelay ( uint32_t virtualNetwork,
Cycles delay )
protected

◆ profileRequest()

void gem5::ruby::AbstractController::profileRequest ( const std::string & request)
protected

Profiles original cache requests including PUTs.

◆ recordCacheTrace()

virtual void gem5::ruby::AbstractController::recordCacheTrace ( int cntrl,
CacheRecorder * tr )
pure virtual

◆ recvAtomic()

Tick gem5::ruby::AbstractController::recvAtomic ( PacketPtr pkt)

◆ recvTimingResp()

◆ regStats()

void gem5::ruby::AbstractController::regStats ( )
virtual

Callback to set stat parameters.

This callback is typically used for complex stats (e.g., distributions) that need parameters in addition to a name and a description. Stat names and descriptions should typically be set from the constructor usingo from the constructor using the ADD_STAT macro.

Reimplemented from gem5::statistics::Group.

Definition at line 132 of file AbstractController.cc.

References gem5::statistics::Group::regStats().

◆ resetStats()

◆ respondsTo()

bool gem5::ruby::AbstractController::respondsTo ( Addr addr)
inline

Definition at line 190 of file AbstractController.hh.

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

◆ sendRetryRespToMem()

void gem5::ruby::AbstractController::sendRetryRespToMem ( )
private

◆ serviceMemoryQueue()

◆ stallBuffer()

void gem5::ruby::AbstractController::stallBuffer ( MessageBuffer * buf,
Addr addr )
protected

◆ unblock()

void gem5::ruby::AbstractController::unblock ( Addr addr)

◆ wakeup()

virtual void gem5::ruby::AbstractController::wakeup ( )
pure virtual

Implements gem5::ruby::Consumer.

◆ wakeUpAllBuffers() [1/2]

void gem5::ruby::AbstractController::wakeUpAllBuffers ( )
protected

Definition at line 223 of file AbstractController.cc.

References gem5::Clocked::clockEdge(), and m_waiting_buffers.

◆ wakeUpAllBuffers() [2/2]

void gem5::ruby::AbstractController::wakeUpAllBuffers ( Addr addr)
protected

◆ wakeUpBuffer()

void gem5::ruby::AbstractController::wakeUpBuffer ( MessageBuffer * buf,
Addr addr )
protected

◆ wakeUpBuffers()

void gem5::ruby::AbstractController::wakeUpBuffers ( Addr addr)
protected

Friends And Related Symbol Documentation

◆ RubyPrefetcherProxy

friend class RubyPrefetcherProxy
friend

Definition at line 390 of file AbstractController.hh.

Member Data Documentation

◆ addrRanges

const AddrRangeList gem5::ruby::AbstractController::addrRanges
private

The address range to which the controller responds on the CPU side.

Definition at line 457 of file AbstractController.hh.

Referenced by getAddrRanges(), and respondsTo().

◆ downstreamAddrMap

std::unordered_map<MachineType, AddrRangeMap<MachineID, 3> > gem5::ruby::AbstractController::downstreamAddrMap
private

Definition at line 460 of file AbstractController.hh.

Referenced by init(), and mapAddressToDownstreamMachine().

◆ downstreamDestinations

NetDest gem5::ruby::AbstractController::downstreamDestinations
private

Definition at line 462 of file AbstractController.hh.

Referenced by allDownstreamDest(), and init().

◆ m_block_map

std::map<Addr, MessageBuffer*> gem5::ruby::AbstractController::m_block_map
protected

Definition at line 402 of file AbstractController.hh.

Referenced by blockOnQueue(), isBlocked(), isBlocked(), and unblock().

◆ m_buffer_size

const unsigned int gem5::ruby::AbstractController::m_buffer_size
protected

Definition at line 413 of file AbstractController.hh.

◆ m_clusterID

const NodeID gem5::ruby::AbstractController::m_clusterID
protected

Definition at line 395 of file AbstractController.hh.

◆ m_cur_in_port

unsigned int gem5::ruby::AbstractController::m_cur_in_port
protected

Definition at line 410 of file AbstractController.hh.

Referenced by stallBuffer(), and wakeUpBuffers().

◆ m_id

const RequestorID gem5::ruby::AbstractController::m_id
protected

Definition at line 398 of file AbstractController.hh.

Referenced by getRequestorId(), and serviceMemoryQueue().

◆ m_in_ports

unsigned int gem5::ruby::AbstractController::m_in_ports
protected

Definition at line 409 of file AbstractController.hh.

Referenced by stallBuffer(), and wakeUpAllBuffers().

◆ m_inTransAddressed

std::unordered_map<Addr, TransMapPair> gem5::ruby::AbstractController::m_inTransAddressed
protected

Definition at line 240 of file AbstractController.hh.

Referenced by incomingTransactionEnd(), and incomingTransactionStart().

◆ m_inTransUnaddressed

std::unordered_map<Addr, TransMapPair> gem5::ruby::AbstractController::m_inTransUnaddressed
protected

Definition at line 243 of file AbstractController.hh.

Referenced by incomingTransactionEnd(), and incomingTransactionStart().

◆ m_is_blocking

bool gem5::ruby::AbstractController::m_is_blocking
protected

Definition at line 401 of file AbstractController.hh.

Referenced by blockOnQueue(), isBlocked(), and unblock().

◆ m_machineID

MachineID gem5::ruby::AbstractController::m_machineID
protected

Definition at line 394 of file AbstractController.hh.

Referenced by getMachineID(), getType(), getVersion(), and recvTimingResp().

◆ m_mandatory_queue_latency

const Cycles gem5::ruby::AbstractController::m_mandatory_queue_latency
protected

Definition at line 415 of file AbstractController.hh.

Referenced by mandatoryQueueLatency().

◆ m_mem_ctrl_waiting_retry

bool gem5::ruby::AbstractController::m_mem_ctrl_waiting_retry
protected

Definition at line 417 of file AbstractController.hh.

Referenced by memRespQueueDequeued(), recvTimingResp(), and sendRetryRespToMem().

◆ m_net_ptr

Network* gem5::ruby::AbstractController::m_net_ptr
protected

Definition at line 400 of file AbstractController.hh.

Referenced by initNetworkPtr(), and mapAddressToMachine().

◆ m_number_of_TBEs

const int gem5::ruby::AbstractController::m_number_of_TBEs
protected

Definition at line 411 of file AbstractController.hh.

◆ m_outTransAddressed

std::unordered_map<Addr, TransMapPair> gem5::ruby::AbstractController::m_outTransAddressed
protected

Definition at line 241 of file AbstractController.hh.

Referenced by outgoingTransactionEnd(), and outgoingTransactionStart().

◆ m_outTransUnaddressed

std::unordered_map<Addr, TransMapPair> gem5::ruby::AbstractController::m_outTransUnaddressed
protected

Definition at line 244 of file AbstractController.hh.

Referenced by outgoingTransactionEnd(), and outgoingTransactionStart().

◆ m_recycle_latency

Cycles gem5::ruby::AbstractController::m_recycle_latency
protected

Definition at line 414 of file AbstractController.hh.

◆ m_transitions_per_cycle

const int gem5::ruby::AbstractController::m_transitions_per_cycle
protected

Definition at line 412 of file AbstractController.hh.

◆ m_version

const NodeID gem5::ruby::AbstractController::m_version
protected

Definition at line 393 of file AbstractController.hh.

Referenced by AbstractController().

◆ m_waiting_buffers

WaitingBufType gem5::ruby::AbstractController::m_waiting_buffers
protected

◆ m_waiting_mem_retry

bool gem5::ruby::AbstractController::m_waiting_mem_retry
protected

Definition at line 416 of file AbstractController.hh.

Referenced by serviceMemoryQueue().

◆ memoryPort

MemoryPort gem5::ruby::AbstractController::memoryPort
protected

◆ mRetryRespEvent

MemberEventWrapper<&AbstractController::sendRetryRespToMem> gem5::ruby::AbstractController::mRetryRespEvent
private

Definition at line 466 of file AbstractController.hh.

Referenced by memRespQueueDequeued().

◆ stats

◆ upstreamDestinations

NetDest gem5::ruby::AbstractController::upstreamDestinations
private

Definition at line 463 of file AbstractController.hh.

Referenced by allUpstreamDest(), and init().


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

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