Go to the documentation of this file.
42 #ifndef __MEM_DRAMSIM2_HH__
43 #define __MEM_DRAMSIM2_HH__
46 #include <unordered_map>
51 #include "params/DRAMSim2.hh"
195 void init()
override;
207 #endif // __MEM_DRAMSIM2_HH__
std::deque< PacketPtr > responseQueue
Queue to hold response packets until we can send them back.
A ResponsePort is a specialization of a port.
Tick startTick
Keep track of when the wrapper is started.
void accessAndRespond(PacketPtr pkt)
When a packet is ready, use the "access()" method in AbstractMemory to actually create the response p...
const PortID InvalidPortID
unsigned int nbrOutstanding() const
void init() override
init() is called after all C++ SimObjects have been created and all ports are connected.
unsigned int nbrOutstandingWrites
bool retryResp
Are we waiting for a retry for sending a response.
void readComplete(unsigned id, uint64_t addr, uint64_t cycle)
Read completion callback.
uint64_t Tick
Tick count type.
int16_t PortID
Port index/ID type, and a symbolic name for an invalid port id.
MemoryPort(const std::string &_name, DRAMSim2 &_memory)
std::unordered_map< Addr, std::queue< PacketPtr > > outstandingReads
Keep track of what packets are outstanding per address, and do so separately for reads and writes.
DRAMSim2(const Params *p)
void recvFunctional(PacketPtr pkt)
Tick recvAtomic(PacketPtr pkt)
Receive an atomic request packet from the peer.
void tick()
Progress the controller one clock cycle.
DrainState
Object drain/handover states.
An abstract memory represents a contiguous block of physical memory, with an associated address range...
bool retryReq
Is the connected port waiting for a retry from us.
The memory port has to deal with its own flow control to avoid having unbounded storage that is impli...
Ports are used to interface objects to each other.
EventFunctionWrapper sendResponseEvent
Event to schedule sending of responses.
bool recvTimingReq(PacketPtr pkt)
Receive a timing request from the peer.
Tick recvAtomic(PacketPtr pkt)
void recvRespRetry()
Called by the peer if sendTimingResp was called on this protocol (causing recvTimingResp to be called...
Port & getPort(const std::string &if_name, PortID idx=InvalidPortID) override
Get a port with a given name and index.
void startup() override
startup() is the final initialization call before simulation.
A Packet is used to encapsulate a transfer between two objects in the memory system (e....
DrainState drain() override
Draining is the process of clearing out the states of SimObjects.These are the SimObjects that are pa...
void recvFunctional(PacketPtr pkt)
Receive a functional request packet from the peer.
bool recvTimingReq(PacketPtr pkt)
AbstractMemoryParams Params
std::unique_ptr< Packet > pendingDelete
Upstream caches need this packet until true is returned, so hold it for deletion until a subsequent c...
std::unordered_map< Addr, std::queue< PacketPtr > > outstandingWrites
void writeComplete(unsigned id, uint64_t addr, uint64_t cycle)
Write completion callback.
AddrRangeList getAddrRanges() const
Get a list of the non-overlapping address ranges the owner is responsible for.
unsigned int nbrOutstandingReads
Count the number of outstanding transactions so that we can block any further requests until there is...
EventFunctionWrapper tickEvent
Event to schedule clock ticks.
DRAMSim2Wrapper wrapper
The actual DRAMSim2 wrapper.
Wrapper class to avoid having DRAMSim2 names like ClockDomain etc clashing with the normal gem5 world...
Generated on Wed Sep 30 2020 14:02:13 for gem5 by doxygen 1.8.17