gem5  v21.0.1.0
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
AbstractController.cc
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2017,2019-2021 ARM Limited
3  * All rights reserved.
4  *
5  * The license below extends only to copyright in the software and shall
6  * not be construed as granting a license to any other intellectual
7  * property including but not limited to intellectual property relating
8  * to a hardware implementation of the functionality of the software
9  * licensed hereunder. You may use the software subject to the license
10  * terms below provided that you ensure that this notice is replicated
11  * unmodified and in its entirety in all distributions of the software,
12  * modified or unmodified, in source code or in binary form.
13  *
14  * Copyright (c) 2011-2014 Mark D. Hill and David A. Wood
15  * All rights reserved.
16  *
17  * Redistribution and use in source and binary forms, with or without
18  * modification, are permitted provided that the following conditions are
19  * met: redistributions of source code must retain the above copyright
20  * notice, this list of conditions and the following disclaimer;
21  * redistributions in binary form must reproduce the above copyright
22  * notice, this list of conditions and the following disclaimer in the
23  * documentation and/or other materials provided with the distribution;
24  * neither the name of the copyright holders nor the names of its
25  * contributors may be used to endorse or promote products derived from
26  * this software without specific prior written permission.
27  *
28  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
29  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
30  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
31  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
32  * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
33  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
34  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
35  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
36  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
37  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
38  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
39  */
40 
42 
43 #include "debug/RubyQueue.hh"
45 #include "mem/ruby/protocol/MemoryMsg.hh"
48 #include "sim/system.hh"
49 
51  : ClockedObject(p), Consumer(this), m_version(p.version),
52  m_clusterID(p.cluster_id),
53  m_id(p.system->getRequestorId(this)), m_is_blocking(false),
54  m_number_of_TBEs(p.number_of_TBEs),
55  m_transitions_per_cycle(p.transitions_per_cycle),
56  m_buffer_size(p.buffer_size), m_recycle_latency(p.recycle_latency),
57  m_mandatory_queue_latency(p.mandatory_queue_latency),
58  memoryPort(csprintf("%s.memory", name()), this),
59  addrRanges(p.addr_ranges.begin(), p.addr_ranges.end()),
60  stats(this)
61 {
62  if (m_version == 0) {
63  // Combine the statistics from all controllers
64  // of this particular type.
66  }
67 }
68 
69 void
71 {
73  uint32_t size = Network::getNumberOfVirtualNetworks();
74  for (uint32_t i = 0; i < size; i++) {
75  stats.delayVCHistogram.push_back(new Stats::Histogram(this));
76  stats.delayVCHistogram[i]->init(10);
77  }
78 
79  if (getMemReqQueue()) {
80  getMemReqQueue()->setConsumer(this);
81  }
82 
83  // Initialize the addr->downstream machine mappings. Multiple machines
84  // in downstream_destinations can have the same address range if they have
85  // different types. If this is the case, mapAddressToDownstreamMachine
86  // needs to specify the machine type
88  for (auto abs_cntrl : params().downstream_destinations) {
89  MachineID mid = abs_cntrl->getMachineID();
90  const AddrRangeList &ranges = abs_cntrl->getAddrRanges();
91  for (const auto &addr_range : ranges) {
92  auto i = downstreamAddrMap.intersects(addr_range);
93  if (i == downstreamAddrMap.end()) {
94  i = downstreamAddrMap.insert(addr_range, AddrMapEntry());
95  }
96  AddrMapEntry &entry = i->second;
97  fatal_if(entry.count(mid.getType()) > 0,
98  "%s: %s mapped to multiple machines of the same type\n",
99  name(), addr_range.to_string());
100  entry[mid.getType()] = mid;
101  }
103  }
104 
105 }
106 
107 void
109 {
111  uint32_t size = Network::getNumberOfVirtualNetworks();
112  for (uint32_t i = 0; i < size; i++) {
113  stats.delayVCHistogram[i]->reset();
114  }
115 }
116 
117 void
119 {
121 }
122 
123 void
124 AbstractController::profileMsgDelay(uint32_t virtualNetwork, Cycles delay)
125 {
126  assert(virtualNetwork < stats.delayVCHistogram.size());
127  stats.delayHistogram.sample(delay);
128  stats.delayVCHistogram[virtualNetwork]->sample(delay);
129 }
130 
131 void
133 {
134  if (m_waiting_buffers.count(addr) == 0) {
135  MsgVecType* msgVec = new MsgVecType;
136  msgVec->resize(m_in_ports, NULL);
137  m_waiting_buffers[addr] = msgVec;
138  }
139  DPRINTF(RubyQueue, "stalling %s port %d addr %#x\n", buf, m_cur_in_port,
140  addr);
141  assert(m_in_ports > m_cur_in_port);
142  (*(m_waiting_buffers[addr]))[m_cur_in_port] = buf;
143 }
144 
145 void
147 {
148  auto iter = m_waiting_buffers.find(addr);
149  if (iter != m_waiting_buffers.end()) {
150  bool has_other_msgs = false;
151  MsgVecType* msgVec = iter->second;
152  for (unsigned int port = 0; port < msgVec->size(); ++port) {
153  if ((*msgVec)[port] == buf) {
155  (*msgVec)[port] = NULL;
156  } else if ((*msgVec)[port] != NULL) {
157  has_other_msgs = true;
158  }
159  }
160  if (!has_other_msgs) {
161  delete msgVec;
162  m_waiting_buffers.erase(iter);
163  }
164  }
165 }
166 
167 void
169 {
170  if (m_waiting_buffers.count(addr) > 0) {
171  //
172  // Wake up all possible lower rank (i.e. lower priority) buffers that could
173  // be waiting on this message.
174  //
175  for (int in_port_rank = m_cur_in_port - 1;
176  in_port_rank >= 0;
177  in_port_rank--) {
178  if ((*(m_waiting_buffers[addr]))[in_port_rank] != NULL) {
179  (*(m_waiting_buffers[addr]))[in_port_rank]->
180  reanalyzeMessages(addr, clockEdge());
181  }
182  }
183  delete m_waiting_buffers[addr];
184  m_waiting_buffers.erase(addr);
185  }
186 }
187 
188 void
190 {
191  if (m_waiting_buffers.count(addr) > 0) {
192  //
193  // Wake up all possible buffers that could be waiting on this message.
194  //
195  for (int in_port_rank = m_in_ports - 1;
196  in_port_rank >= 0;
197  in_port_rank--) {
198  if ((*(m_waiting_buffers[addr]))[in_port_rank] != NULL) {
199  (*(m_waiting_buffers[addr]))[in_port_rank]->
200  reanalyzeMessages(addr, clockEdge());
201  }
202  }
203  delete m_waiting_buffers[addr];
204  m_waiting_buffers.erase(addr);
205  }
206 }
207 
208 void
210 {
211  //
212  // Wake up all possible buffers that could be waiting on any message.
213  //
214 
215  std::vector<MsgVecType*> wokeUpMsgVecs;
216  MsgBufType wokeUpMsgBufs;
217 
218  if (m_waiting_buffers.size() > 0) {
219  for (WaitingBufType::iterator buf_iter = m_waiting_buffers.begin();
220  buf_iter != m_waiting_buffers.end();
221  ++buf_iter) {
222  for (MsgVecType::iterator vec_iter = buf_iter->second->begin();
223  vec_iter != buf_iter->second->end();
224  ++vec_iter) {
225  //
226  // Make sure the MessageBuffer has not already be reanalyzed
227  //
228  if (*vec_iter != NULL &&
229  (wokeUpMsgBufs.count(*vec_iter) == 0)) {
230  (*vec_iter)->reanalyzeAllMessages(clockEdge());
231  wokeUpMsgBufs.insert(*vec_iter);
232  }
233  }
234  wokeUpMsgVecs.push_back(buf_iter->second);
235  }
236 
237  for (std::vector<MsgVecType*>::iterator wb_iter = wokeUpMsgVecs.begin();
238  wb_iter != wokeUpMsgVecs.end();
239  ++wb_iter) {
240  delete (*wb_iter);
241  }
242 
243  m_waiting_buffers.clear();
244  }
245 }
246 
247 bool
249 {
250  auto mem_queue = getMemReqQueue();
251  assert(mem_queue);
252  if (!mem_queue->isReady(clockEdge())) {
253  return false;
254  }
255 
256  const MemoryMsg *mem_msg = (const MemoryMsg*)mem_queue->peek();
257  unsigned int req_size = RubySystem::getBlockSizeBytes();
258  if (mem_msg->m_Len > 0) {
259  req_size = mem_msg->m_Len;
260  }
261 
262  RequestPtr req
263  = std::make_shared<Request>(mem_msg->m_addr, req_size, 0, m_id);
264  PacketPtr pkt;
265  if (mem_msg->getType() == MemoryRequestType_MEMORY_WB) {
266  pkt = Packet::createWrite(req);
267  pkt->allocate();
268  pkt->setData(mem_msg->m_DataBlk.getData(getOffset(mem_msg->m_addr),
269  req_size));
270  } else if (mem_msg->getType() == MemoryRequestType_MEMORY_READ) {
271  pkt = Packet::createRead(req);
272  uint8_t *newData = new uint8_t[req_size];
273  pkt->dataDynamic(newData);
274  } else {
275  panic("Unknown memory request type (%s) for addr %p",
276  MemoryRequestType_to_string(mem_msg->getType()),
277  mem_msg->m_addr);
278  }
279 
280  SenderState *s = new SenderState(mem_msg->m_Sender);
281  pkt->pushSenderState(s);
282 
284  // Use functional rather than timing accesses during warmup
285  mem_queue->dequeue(clockEdge());
287  // Since the queue was popped the controller may be able
288  // to make more progress. Make sure it wakes up
289  scheduleEvent(Cycles(1));
290  recvTimingResp(pkt);
291  } else if (memoryPort.sendTimingReq(pkt)) {
292  mem_queue->dequeue(clockEdge());
293  // Since the queue was popped the controller may be able
294  // to make more progress. Make sure it wakes up
295  scheduleEvent(Cycles(1));
296  } else {
297  scheduleEvent(Cycles(1));
298  delete pkt;
299  delete s;
300  }
301 
302  return true;
303 }
304 
305 void
307 {
308  m_is_blocking = true;
309  m_block_map[addr] = port;
310 }
311 
312 bool
314 {
315  return m_is_blocking && (m_block_map.find(addr) != m_block_map.end());
316 }
317 
318 void
320 {
321  m_block_map.erase(addr);
322  if (m_block_map.size() == 0) {
323  m_is_blocking = false;
324  }
325 }
326 
327 bool
329 {
330  return (m_block_map.count(addr) > 0);
331 }
332 
333 Port &
334 AbstractController::getPort(const std::string &if_name, PortID idx)
335 {
336  return memoryPort;
337 }
338 
339 void
341 {
342  // read from mem. req. queue if write data is pending there
343  MessageBuffer *req_queue = getMemReqQueue();
344  if (!req_queue || !req_queue->functionalRead(pkt))
346 }
347 
348 int
350 {
351  int num_functional_writes = 0;
352 
353  // Update memory itself.
355  return num_functional_writes + 1;
356 }
357 
358 void
360 {
361  assert(getMemRespQueue());
362  assert(pkt->isResponse());
363 
364  std::shared_ptr<MemoryMsg> msg = std::make_shared<MemoryMsg>(clockEdge());
365  (*msg).m_addr = pkt->getAddr();
366  (*msg).m_Sender = m_machineID;
367 
368  SenderState *s = dynamic_cast<SenderState *>(pkt->senderState);
369  (*msg).m_OriginalRequestorMachId = s->id;
370  delete s;
371 
372  if (pkt->isRead()) {
373  (*msg).m_Type = MemoryRequestType_MEMORY_READ;
374  (*msg).m_MessageSize = MessageSizeType_Response_Data;
375 
376  // Copy data from the packet
377  (*msg).m_DataBlk.setData(pkt->getPtr<uint8_t>(), 0,
379  } else if (pkt->isWrite()) {
380  (*msg).m_Type = MemoryRequestType_MEMORY_WB;
381  (*msg).m_MessageSize = MessageSizeType_Writeback_Control;
382  } else {
383  panic("Incorrect packet type received from memory controller!");
384  }
385 
387  delete pkt;
388 }
389 
390 Tick
392 {
393  return ticksToCycles(memoryPort.sendAtomic(pkt));
394 }
395 
396 MachineID
398 {
399  NodeID node = m_net_ptr->addressToNodeID(addr, mtype);
400  MachineID mach = {mtype, node};
401  return mach;
402 }
403 
404 MachineID
406 const
407 {
408  const auto i = downstreamAddrMap.contains(addr);
410  "%s: couldn't find mapping for address %x\n", name(), addr);
411 
412  const AddrMapEntry &entry = i->second;
413  assert(!entry.empty());
414 
415  if (mtype == MachineType_NUM) {
416  fatal_if(entry.size() > 1,
417  "%s: address %x mapped to multiple machine types.\n", name(), addr);
418  return entry.begin()->second;
419  } else {
420  auto j = entry.find(mtype);
421  fatal_if(j == entry.end(),
422  "%s: couldn't find mapping for address %x\n", name(), addr);
423  return j->second;
424  }
425 }
426 
427 
428 bool
430 {
432  return true;
433 }
434 
435 void
437 {
438  controller->serviceMemoryQueue();
439 }
440 
442  AbstractController *_controller,
443  PortID id)
444  : RequestPort(_name, _controller, id), controller(_controller)
445 {
446 }
447 
450  : Stats::Group(parent),
451  ADD_STAT(fullyBusyCycles,
452  "cycles for which number of transistions == max transitions"),
453  ADD_STAT(delayHistogram, "delay_histogram")
454 {
459 }
AbstractController::blockOnQueue
void blockOnQueue(Addr, MessageBuffer *)
Definition: AbstractController.cc:306
Stats::Group::regStats
virtual void regStats()
Callback to set stat parameters.
Definition: group.cc:63
NetDest::add
void add(MachineID newElement)
Definition: NetDest.cc:39
AbstractController::ControllerStats::delayHistogram
Stats::Histogram delayHistogram
Histogram for profiling delay for the messages this controller cares for.
Definition: AbstractController.hh:395
Packet::isResponse
bool isResponse() const
Definition: packet.hh:561
AbstractController::m_waiting_buffers
WaitingBufType m_waiting_buffers
Definition: AbstractController.hh:316
system.hh
AbstractController::SenderState
Definition: AbstractController.hh:353
RubySystem::getBlockSizeBytes
static uint32_t getBlockSizeBytes()
Definition: RubySystem.hh:61
AbstractController::recvAtomic
Tick recvAtomic(PacketPtr pkt)
Definition: AbstractController.cc:391
Packet::getAddr
Addr getAddr() const
Definition: packet.hh:755
AbstractController::MemoryPort::controller
AbstractController * controller
Definition: AbstractController.hh:334
AddrRangeMap::insert
iterator insert(const AddrRange &r, const V &d)
Definition: addr_range_map.hh:152
ArmISA::i
Bitfield< 7 > i
Definition: miscregs_types.hh:63
MachineID::getType
MachineType getType() const
Definition: MachineID.hh:60
AbstractController::getMemReqQueue
virtual MessageBuffer * getMemReqQueue() const =0
AddrRangeMap::end
const_iterator end() const
Definition: addr_range_map.hh:214
Network::addressToNodeID
NodeID addressToNodeID(Addr addr, MachineType mtype)
Map an address to the correct NodeID.
Definition: Network.cc:229
Stats::registerDumpCallback
void registerDumpCallback(const std::function< void()> &callback)
Register a callback that should be called whenever statistics are about to be dumped.
Definition: statistics.cc:319
AbstractController::stallBuffer
void stallBuffer(MessageBuffer *buf, Addr addr)
Definition: AbstractController.cc:132
AbstractController::MemoryPort::recvTimingResp
bool recvTimingResp(PacketPtr pkt)
Receive a timing response from the peer.
Definition: AbstractController.cc:429
Packet::isRead
bool isRead() const
Definition: packet.hh:557
AbstractController::wakeUpAllBuffers
void wakeUpAllBuffers()
Definition: AbstractController.cc:209
Tick
uint64_t Tick
Tick count type.
Definition: types.hh:59
AbstractController::mapAddressToMachine
MachineID mapAddressToMachine(Addr addr, MachineType mtype) const
Map an address to the correct MachineID.
Definition: AbstractController.cc:397
AbstractController::ControllerStats::delayVCHistogram
std::vector< Stats::Histogram * > delayVCHistogram
Definition: AbstractController.hh:396
AbstractController.hh
AbstractController::MemoryPort::MemoryPort
MemoryPort(const std::string &_name, AbstractController *_controller, PortID id=InvalidPortID)
Definition: AbstractController.cc:441
PortID
int16_t PortID
Port index/ID type, and a symbolic name for an invalid port id.
Definition: types.hh:243
Stats::Group::Group
Group()=delete
RequestPtr
std::shared_ptr< Request > RequestPtr
Definition: request.hh:86
Packet::dataDynamic
void dataDynamic(T *p)
Set the data pointer to a value that should have delete [] called on it.
Definition: packet.hh:1146
std::vector< MessageBuffer * >
MessageBuffer::reanalyzeMessages
void reanalyzeMessages(Addr addr, Tick current_time)
Definition: MessageBuffer.cc:373
AbstractController
Definition: AbstractController.hh:76
RequestPort::sendFunctional
void sendFunctional(PacketPtr pkt) const
Send a functional request packet, where the data is instantly updated everywhere in the memory system...
Definition: port.hh:482
MessageBuffer::setConsumer
void setConsumer(Consumer *consumer)
Definition: MessageBuffer.hh:96
AbstractController::m_cur_in_port
unsigned int m_cur_in_port
Definition: AbstractController.hh:319
MessageBuffer::enqueue
void enqueue(MsgPtr message, Tick curTime, Tick delta)
Definition: MessageBuffer.cc:191
AbstractController::mapAddressToDownstreamMachine
MachineID mapAddressToDownstreamMachine(Addr addr, MachineType mtype=MachineType_NUM) const
Maps an address to the correct dowstream MachineID (i.e.
Definition: AbstractController.cc:405
AbstractController::serviceMemoryQueue
bool serviceMemoryQueue()
Definition: AbstractController.cc:248
MachineID
Definition: MachineID.hh:50
AbstractController::isBlocked
bool isBlocked(Addr) const
Definition: AbstractController.cc:313
NetDest::resize
void resize()
Definition: NetDest.cc:247
Packet::setData
void setData(const uint8_t *p)
Copy data into the packet from the provided pointer.
Definition: packet.hh:1226
ClockedObject
The ClockedObject class extends the SimObject with a clock and accessor functions to relate ticks to ...
Definition: clocked_object.hh:231
Stats::DataWrap::flags
Derived & flags(Flags _flags)
Set the flags and marks this stat to print at the end of simulation.
Definition: statistics.hh:339
Stats::Histogram
A simple histogram stat.
Definition: statistics.hh:2126
X86ISA::system
Bitfield< 15 > system
Definition: misc.hh:997
AbstractController::wakeUpBuffers
void wakeUpBuffers(Addr addr)
Definition: AbstractController.cc:168
ArmISA::j
Bitfield< 24 > j
Definition: miscregs_types.hh:54
AbstractController::unblock
void unblock(Addr)
Definition: AbstractController.cc:319
Clocked::cyclesToTicks
Tick cyclesToTicks(Cycles c) const
Definition: clocked_object.hh:224
AbstractController::memoryPort
MemoryPort memoryPort
Definition: AbstractController.hh:350
ClockedObject::Params
ClockedObjectParams Params
Parameters of ClockedObject.
Definition: clocked_object.hh:237
AbstractController::regStats
virtual void regStats()
Callback to set stat parameters.
Definition: AbstractController.cc:118
AbstractController::m_in_ports
unsigned int m_in_ports
Definition: AbstractController.hh:318
RequestPort::sendTimingReq
bool sendTimingReq(PacketPtr pkt)
Attempt to send a timing request to the responder port by calling its corresponding receive function.
Definition: port.hh:492
AbstractController::m_net_ptr
Network * m_net_ptr
Definition: AbstractController.hh:309
DPRINTF
#define DPRINTF(x,...)
Definition: trace.hh:237
ADD_STAT
#define ADD_STAT(n,...)
Convenience macro to add a stat to a statistics group.
Definition: group.hh:71
SenderState
RubyTester::SenderState SenderState
Definition: Check.cc:37
AbstractController::wakeUpBuffer
void wakeUpBuffer(MessageBuffer *buf, Addr addr)
Definition: AbstractController.cc:146
AbstractController::m_is_blocking
bool m_is_blocking
Definition: AbstractController.hh:310
Packet::createRead
static PacketPtr createRead(const RequestPtr &req)
Constructor-like methods that return Packets based on Request objects.
Definition: packet.hh:981
Port
Ports are used to interface objects to each other.
Definition: port.hh:56
Consumer
Definition: Consumer.hh:55
Clocked::clockEdge
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...
Definition: clocked_object.hh:174
MessageBuffer::functionalRead
bool functionalRead(Packet *pkt)
Definition: MessageBuffer.hh:170
AbstractController::functionalMemoryWrite
int functionalMemoryWrite(PacketPtr)
Definition: AbstractController.cc:349
AbstractController::recvTimingResp
void recvTimingResp(PacketPtr pkt)
Definition: AbstractController.cc:359
AbstractController::m_block_map
std::map< Addr, MessageBuffer * > m_block_map
Definition: AbstractController.hh:311
AbstractController::m_machineID
MachineID m_machineID
Definition: AbstractController.hh:303
RequestPort
A RequestPort is a specialisation of a Port, which implements the default protocol for the three diff...
Definition: port.hh:74
AbstractController::collateStats
virtual void collateStats()
Function for collating statistics from all the controllers of this particular type.
Definition: AbstractController.hh:152
AbstractController::AddrMapEntry
std::unordered_map< MachineType, MachineID > AddrMapEntry
Definition: AbstractController.hh:366
RubySystem.hh
Addr
uint64_t Addr
Address type This will probably be moved somewhere else in the near future.
Definition: types.hh:148
name
const std::string & name()
Definition: trace.cc:48
Network::getNumberOfVirtualNetworks
static uint32_t getNumberOfVirtualNetworks()
Definition: Network.hh:84
Stats::nozero
const FlagsType nozero
Don't print if this is zero.
Definition: info.hh:58
AbstractController::init
void init()
init() is called after all C++ SimObjects have been created and all ports are connected.
Definition: AbstractController.cc:70
X86ISA::addr
Bitfield< 3 > addr
Definition: types.hh:80
SimObject::name
virtual const std::string name() const
Definition: sim_object.hh:182
AbstractController::getPort
Port & getPort(const std::string &if_name, PortID idx=InvalidPortID)
A function used to return the port associated with this bus object.
Definition: AbstractController.cc:334
Network.hh
Packet::createWrite
static PacketPtr createWrite(const RequestPtr &req)
Definition: packet.hh:987
AbstractController::ControllerStats::fullyBusyCycles
Stats::Scalar fullyBusyCycles
Counter for the number of cycles when the transitions carried out were equal to the maximum allowed.
Definition: AbstractController.hh:391
Packet::pushSenderState
void pushSenderState(SenderState *sender_state)
Push a new sender state to the packet and make the current sender state the predecessor of the new on...
Definition: packet.cc:332
RubySystem::getWarmupEnabled
static bool getWarmupEnabled()
Definition: RubySystem.hh:64
Clocked::ticksToCycles
Cycles ticksToCycles(Tick t) const
Definition: clocked_object.hh:219
AddrRangeMap::contains
const_iterator contains(const AddrRange &r) const
Find entry that contains the given address range.
Definition: addr_range_map.hh:87
Packet
A Packet is used to encapsulate a transfer between two objects in the memory system (e....
Definition: packet.hh:258
AbstractController::stats
AbstractController::ControllerStats stats
AbstractController::m_id
const RequestorID m_id
Definition: AbstractController.hh:307
Stats::Group
Statistics container.
Definition: group.hh:87
AddrRangeMap::intersects
const_iterator intersects(const AddrRange &r) const
Find entry that intersects with the given address range.
Definition: addr_range_map.hh:137
AbstractController::MemoryPort::recvReqRetry
void recvReqRetry()
Called by the peer if sendTimingReq was called on this peer (causing recvTimingReq to be called on th...
Definition: AbstractController.cc:436
getOffset
Addr getOffset(Addr addr)
Definition: Address.cc:48
Stats::DistBase::reset
void reset()
Reset stat value to default.
Definition: statistics.hh:1347
Stats::DistBase::sample
void sample(const U &v, int n=1)
Add a value to the distribtion n times.
Definition: statistics.hh:1323
Cycles
Cycles is a wrapper class for representing cycle counts, i.e.
Definition: types.hh:79
Packet::isWrite
bool isWrite() const
Definition: packet.hh:558
Packet::getPtr
T * getPtr()
get a pointer to the data ptr.
Definition: packet.hh:1158
NodeID
unsigned int NodeID
Definition: TypeDefines.hh:34
Stats
Definition: statistics.cc:53
AbstractController::MsgBufType
std::set< MessageBuffer * > MsgBufType
Definition: AbstractController.hh:314
AbstractController::AbstractController
AbstractController(const Params &p)
Definition: AbstractController.cc:50
AbstractController::m_version
const NodeID m_version
Definition: AbstractController.hh:302
Stats::Histogram::init
Histogram & init(size_type size)
Set the parameters of this histogram.
Definition: statistics.hh:2153
SimObject::params
const Params & params() const
Definition: sim_object.hh:168
Packet::senderState
SenderState * senderState
This packet's sender state.
Definition: packet.hh:509
RequestPort::sendAtomic
Tick sendAtomic(PacketPtr pkt)
Send an atomic request packet, where the data is moved and the state is updated in zero time,...
Definition: port.hh:461
MipsISA::p
Bitfield< 0 > p
Definition: pra_constants.hh:323
std::list< AddrRange >
MessageBuffer
Definition: MessageBuffer.hh:68
AbstractController::profileMsgDelay
void profileMsgDelay(uint32_t virtualNetwork, Cycles delay)
Profiles the delay associated with messages.
Definition: AbstractController.cc:124
Packet::allocate
void allocate()
Allocate memory for the packet.
Definition: packet.hh:1300
ArmISA::s
Bitfield< 4 > s
Definition: miscregs_types.hh:556
fatal_if
#define fatal_if(cond,...)
Conditional fatal macro that checks the supplied condition and only causes a fatal error if the condi...
Definition: logging.hh:219
AbstractController::downstreamAddrMap
AddrRangeMap< AddrMapEntry, 3 > downstreamAddrMap
Definition: AbstractController.hh:368
AbstractController::getMemRespQueue
virtual MessageBuffer * getMemRespQueue() const =0
csprintf
std::string csprintf(const char *format, const Args &...args)
Definition: cprintf.hh:158
AbstractController::downstreamDestinations
NetDest downstreamDestinations
Definition: AbstractController.hh:370
AbstractController::MsgVecType
std::vector< MessageBuffer * > MsgVecType
Definition: AbstractController.hh:313
ArmISA::id
Bitfield< 33 > id
Definition: miscregs_types.hh:247
Consumer::scheduleEvent
void scheduleEvent(Cycles timeDelta)
Definition: Consumer.cc:50
panic
#define panic(...)
This implements a cprintf based panic() function.
Definition: logging.hh:171
AbstractController::ControllerStats::ControllerStats
ControllerStats(Stats::Group *parent)
Definition: AbstractController.cc:449
AbstractController::resetStats
virtual void resetStats()=0
Callback to reset stats.
Definition: AbstractController.cc:108
AbstractController::functionalMemoryRead
void functionalMemoryRead(PacketPtr)
Definition: AbstractController.cc:340
Sequencer.hh

Generated on Tue Jun 22 2021 15:28:30 for gem5 by doxygen 1.8.17