gem5  [DEVELOP-FOR-23.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-2022 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 
50 namespace gem5
51 {
52 
53 namespace ruby
54 {
55 
57  : ClockedObject(p), Consumer(this), m_version(p.version),
58  m_clusterID(p.cluster_id),
59  m_id(p.system->getRequestorId(this)), m_is_blocking(false),
60  m_number_of_TBEs(p.number_of_TBEs),
61  m_transitions_per_cycle(p.transitions_per_cycle),
62  m_buffer_size(p.buffer_size), m_recycle_latency(p.recycle_latency),
63  m_mandatory_queue_latency(p.mandatory_queue_latency),
64  m_waiting_mem_retry(false),
65  m_mem_ctrl_waiting_retry(false),
66  memoryPort(csprintf("%s.memory", name()), this),
67  addrRanges(p.addr_ranges.begin(), p.addr_ranges.end()),
68  mRetryRespEvent{*this, false},
69  stats(this)
70 {
71  if (m_version == 0) {
72  // Combine the statistics from all controllers
73  // of this particular type.
74  statistics::registerDumpCallback([this]() { collateStats(); });
75  }
76 }
77 
78 void
80 {
82  uint32_t size = Network::getNumberOfVirtualNetworks();
83  for (uint32_t i = 0; i < size; i++) {
84  stats.delayVCHistogram.push_back(new statistics::Histogram(this));
85  stats.delayVCHistogram[i]->init(10);
86  }
87 
88  if (getMemReqQueue()) {
89  getMemReqQueue()->setConsumer(this);
90  }
91 
92  // Initialize the addr->downstream machine mappings. Multiple machines
93  // in downstream_destinations can have the same address range if they have
94  // different types. If this is the case, mapAddressToDownstreamMachine
95  // needs to specify the machine type
97  for (auto abs_cntrl : params().downstream_destinations) {
98  MachineID mid = abs_cntrl->getMachineID();
99  const AddrRangeList &ranges = abs_cntrl->getAddrRanges();
100  for (const auto &addr_range : ranges) {
101  auto i = downstreamAddrMap.find(mid.getType());
102  if ((i != downstreamAddrMap.end()) &&
103  (i->second.intersects(addr_range) != i->second.end())) {
104  fatal("%s: %s mapped to multiple machines of the same type\n",
105  name(), addr_range.to_string());
106  }
107  downstreamAddrMap[mid.getType()].insert(addr_range, mid);
108  }
110  }
111  // Initialize the addr->upstream machine list.
112  // We do not need to map address -> upstream machine,
113  // so we don't examine the address ranges
115  for (auto abs_cntrl : params().upstream_destinations) {
116  upstreamDestinations.add(abs_cntrl->getMachineID());
117  }
118 }
119 
120 void
122 {
124  uint32_t size = Network::getNumberOfVirtualNetworks();
125  for (uint32_t i = 0; i < size; i++) {
126  stats.delayVCHistogram[i]->reset();
127  }
128 }
129 
130 void
132 {
134 }
135 
136 void
137 AbstractController::profileMsgDelay(uint32_t virtualNetwork, Cycles delay)
138 {
139  assert(virtualNetwork < stats.delayVCHistogram.size());
140  stats.delayHistogram.sample(delay);
141  stats.delayVCHistogram[virtualNetwork]->sample(delay);
142 }
143 
144 void
146 {
147  if (m_waiting_buffers.count(addr) == 0) {
148  MsgVecType* msgVec = new MsgVecType;
149  msgVec->resize(m_in_ports, NULL);
150  m_waiting_buffers[addr] = msgVec;
151  }
152  DPRINTF(RubyQueue, "stalling %s port %d addr %#x\n", buf, m_cur_in_port,
153  addr);
154  assert(m_in_ports > m_cur_in_port);
155  (*(m_waiting_buffers[addr]))[m_cur_in_port] = buf;
156 }
157 
158 void
160 {
161  auto iter = m_waiting_buffers.find(addr);
162  if (iter != m_waiting_buffers.end()) {
163  bool has_other_msgs = false;
164  MsgVecType* msgVec = iter->second;
165  for (unsigned int port = 0; port < msgVec->size(); ++port) {
166  if ((*msgVec)[port] == buf) {
168  (*msgVec)[port] = NULL;
169  } else if ((*msgVec)[port] != NULL) {
170  has_other_msgs = true;
171  }
172  }
173  if (!has_other_msgs) {
174  delete msgVec;
175  m_waiting_buffers.erase(iter);
176  }
177  }
178 }
179 
180 void
182 {
183  if (m_waiting_buffers.count(addr) > 0) {
184  //
185  // Wake up all possible lower rank (i.e. lower priority) buffers that could
186  // be waiting on this message.
187  //
188  for (int in_port_rank = m_cur_in_port - 1;
189  in_port_rank >= 0;
190  in_port_rank--) {
191  if ((*(m_waiting_buffers[addr]))[in_port_rank] != NULL) {
192  (*(m_waiting_buffers[addr]))[in_port_rank]->
193  reanalyzeMessages(addr, clockEdge());
194  }
195  }
196  delete m_waiting_buffers[addr];
197  m_waiting_buffers.erase(addr);
198  }
199 }
200 
201 void
203 {
204  if (m_waiting_buffers.count(addr) > 0) {
205  //
206  // Wake up all possible buffers that could be waiting on this message.
207  //
208  for (int in_port_rank = m_in_ports - 1;
209  in_port_rank >= 0;
210  in_port_rank--) {
211  if ((*(m_waiting_buffers[addr]))[in_port_rank] != NULL) {
212  (*(m_waiting_buffers[addr]))[in_port_rank]->
213  reanalyzeMessages(addr, clockEdge());
214  }
215  }
216  delete m_waiting_buffers[addr];
217  m_waiting_buffers.erase(addr);
218  }
219 }
220 
221 void
223 {
224  //
225  // Wake up all possible buffers that could be waiting on any message.
226  //
227 
228  std::vector<MsgVecType*> wokeUpMsgVecs;
229  MsgBufType wokeUpMsgBufs;
230 
231  if (m_waiting_buffers.size() > 0) {
232  for (WaitingBufType::iterator buf_iter = m_waiting_buffers.begin();
233  buf_iter != m_waiting_buffers.end();
234  ++buf_iter) {
235  for (MsgVecType::iterator vec_iter = buf_iter->second->begin();
236  vec_iter != buf_iter->second->end();
237  ++vec_iter) {
238  //
239  // Make sure the MessageBuffer has not already be reanalyzed
240  //
241  if (*vec_iter != NULL &&
242  (wokeUpMsgBufs.count(*vec_iter) == 0)) {
243  (*vec_iter)->reanalyzeAllMessages(clockEdge());
244  wokeUpMsgBufs.insert(*vec_iter);
245  }
246  }
247  wokeUpMsgVecs.push_back(buf_iter->second);
248  }
249 
250  for (std::vector<MsgVecType*>::iterator wb_iter = wokeUpMsgVecs.begin();
251  wb_iter != wokeUpMsgVecs.end();
252  ++wb_iter) {
253  delete (*wb_iter);
254  }
255 
256  m_waiting_buffers.clear();
257  }
258 }
259 
260 bool
262 {
263  auto mem_queue = getMemReqQueue();
264  assert(mem_queue);
265  if (m_waiting_mem_retry || !mem_queue->isReady(clockEdge())) {
266  return false;
267  }
268 
269  const MemoryMsg *mem_msg = (const MemoryMsg*)mem_queue->peek();
270  unsigned int req_size = RubySystem::getBlockSizeBytes();
271  if (mem_msg->m_Len > 0) {
272  req_size = mem_msg->m_Len;
273  }
274 
275  RequestPtr req
276  = std::make_shared<Request>(mem_msg->m_addr, req_size, 0, m_id);
277  PacketPtr pkt;
278  if (mem_msg->getType() == MemoryRequestType_MEMORY_WB) {
279  pkt = Packet::createWrite(req);
280  pkt->allocate();
281  pkt->setData(mem_msg->m_DataBlk.getData(getOffset(mem_msg->m_addr),
282  req_size));
283  } else if (mem_msg->getType() == MemoryRequestType_MEMORY_READ) {
284  pkt = Packet::createRead(req);
285  uint8_t *newData = new uint8_t[req_size];
286  pkt->dataDynamic(newData);
287  } else {
288  panic("Unknown memory request type (%s) for addr %p",
289  MemoryRequestType_to_string(mem_msg->getType()),
290  mem_msg->m_addr);
291  }
292 
293  SenderState *s = new SenderState(mem_msg->m_Sender);
294  pkt->pushSenderState(s);
295 
297  // Use functional rather than timing accesses during warmup
298  mem_queue->dequeue(clockEdge());
300  // Since the queue was popped the controller may be able
301  // to make more progress. Make sure it wakes up
302  scheduleEvent(Cycles(1));
303  recvTimingResp(pkt);
304  } else if (memoryPort.sendTimingReq(pkt)) {
305  mem_queue->dequeue(clockEdge());
306  // Since the queue was popped the controller may be able
307  // to make more progress. Make sure it wakes up
308  scheduleEvent(Cycles(1));
309  } else {
310  scheduleEvent(Cycles(1));
311  m_waiting_mem_retry = true;
312  delete pkt;
313  delete s;
314  }
315 
316  return true;
317 }
318 
319 void
321 {
322  m_is_blocking = true;
323  m_block_map[addr] = port;
324 }
325 
326 bool
328 {
329  return m_is_blocking && (m_block_map.find(addr) != m_block_map.end());
330 }
331 
332 void
334 {
335  m_block_map.erase(addr);
336  if (m_block_map.size() == 0) {
337  m_is_blocking = false;
338  }
339 }
340 
341 bool
343 {
344  return (m_block_map.count(addr) > 0);
345 }
346 
347 Port &
348 AbstractController::getPort(const std::string &if_name, PortID idx)
349 {
350  return memoryPort;
351 }
352 
353 void
355 {
356  // read from mem. req. queue if write data is pending there
357  MessageBuffer *req_queue = getMemReqQueue();
358  if (!req_queue || !req_queue->functionalRead(pkt))
360 }
361 
362 int
364 {
365  int num_functional_writes = 0;
366 
367  // Update memory itself.
369  return num_functional_writes + 1;
370 }
371 
372 bool
374 {
375  auto* memRspQueue = getMemRespQueue();
376  gem5_assert(memRspQueue);
377  gem5_assert(pkt->isResponse());
378 
379  if (!memRspQueue->areNSlotsAvailable(1, curTick())) {
381  return false;
382  }
383 
384  std::shared_ptr<MemoryMsg> msg = std::make_shared<MemoryMsg>(clockEdge());
385  (*msg).m_addr = pkt->getAddr();
386  (*msg).m_Sender = m_machineID;
387 
388  SenderState *s = dynamic_cast<SenderState *>(pkt->senderState);
389  (*msg).m_OriginalRequestorMachId = s->id;
390  delete s;
391 
392  if (pkt->isRead()) {
393  (*msg).m_Type = MemoryRequestType_MEMORY_READ;
394  (*msg).m_MessageSize = MessageSizeType_Response_Data;
395 
396  // Copy data from the packet
397  (*msg).m_DataBlk.setData(pkt->getPtr<uint8_t>(), 0,
399  } else if (pkt->isWrite()) {
400  (*msg).m_Type = MemoryRequestType_MEMORY_WB;
401  (*msg).m_MessageSize = MessageSizeType_Writeback_Control;
402  } else {
403  panic("Incorrect packet type received from memory controller!");
404  }
405 
406  memRspQueue->enqueue(msg, clockEdge(), cyclesToTicks(Cycles(1)));
407  delete pkt;
408  return true;
409 }
410 
411 Tick
413 {
414  return ticksToCycles(memoryPort.sendAtomic(pkt));
415 }
416 
417 MachineID
419 {
420  NodeID node = m_net_ptr->addressToNodeID(addr, mtype);
421  MachineID mach = {mtype, node};
422  return mach;
423 }
424 
425 MachineID
427 const
428 {
429  if (mtype == MachineType_NUM) {
430  // map to the first match
431  for (const auto &i : downstreamAddrMap) {
432  const auto mapping = i.second.contains(addr);
433  if (mapping != i.second.end())
434  return mapping->second;
435  }
436  }
437  else {
438  const auto i = downstreamAddrMap.find(mtype);
439  if (i != downstreamAddrMap.end()) {
440  const auto mapping = i->second.contains(addr);
441  if (mapping != i->second.end())
442  return mapping->second;
443  }
444  }
445  fatal("%s: couldn't find mapping for address %x mtype=%s\n",
446  name(), addr, mtype);
447 }
448 
449 
450 void
454  }
455 }
456 
457 void
459  auto* q = getMemRespQueue();
460  gem5_assert(q);
461  q->dequeue(clockEdge());
463 }
464 
465 void
468  m_mem_ctrl_waiting_retry = false;
470  }
471 }
472 
473 bool
475 {
476  return controller->recvTimingResp(pkt);
477 }
478 
479 void
481 {
482  controller->m_waiting_mem_retry = false;
483  controller->serviceMemoryQueue();
484 }
485 
487  AbstractController *_controller,
488  PortID id)
489  : RequestPort(_name, id), controller(_controller)
490 {
491 }
492 
495  : statistics::Group(parent),
496  ADD_STAT(fullyBusyCycles,
497  "cycles for which number of transistions == max transitions"),
498  ADD_STAT(delayHistogram, "delay_histogram")
499 {
504 }
505 
506 } // namespace ruby
507 } // namespace gem5
gem5::curTick
Tick curTick()
The universal simulation clock.
Definition: cur_tick.hh:46
fatal
#define fatal(...)
This implements a cprintf based fatal() function.
Definition: logging.hh:200
gem5::ruby::MachineID::getType
MachineType getType() const
Definition: MachineID.hh:66
gem5::PortID
int16_t PortID
Port index/ID type, and a symbolic name for an invalid port id.
Definition: types.hh:245
gem5::ruby::Network::getNumberOfVirtualNetworks
static uint32_t getNumberOfVirtualNetworks()
Definition: Network.hh:90
gem5::VegaISA::s
Bitfield< 1 > s
Definition: pagetable.hh:64
gem5::ruby::AbstractController::MsgBufType
std::set< MessageBuffer * > MsgBufType
Definition: AbstractController.hh:364
gem5::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:587
gem5::ruby::AbstractController::ControllerStats::fullyBusyCycles
statistics::Scalar fullyBusyCycles
Counter for the number of cycles when the transitions carried out were equal to the maximum allowed.
Definition: AbstractController.hh:446
system.hh
gem5::ruby::AbstractController::getMemReqQueue
virtual MessageBuffer * getMemReqQueue() const =0
gem5::ruby::AbstractController::profileMsgDelay
void profileMsgDelay(uint32_t virtualNetwork, Cycles delay)
Profiles the delay associated with messages.
Definition: AbstractController.cc:137
gem5::Packet::setData
void setData(const uint8_t *p)
Copy data into the packet from the provided pointer.
Definition: packet.hh:1293
gem5::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:334
gem5::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:536
gem5::ruby::AbstractController::serviceMemoryQueue
bool serviceMemoryQueue()
Definition: AbstractController.cc:261
gem5::statistics::nozero
const FlagsType nozero
Don't print if this is zero.
Definition: info.hh:67
gem5::ruby::AbstractController::wakeUpBuffers
void wakeUpBuffers(Addr addr)
Definition: AbstractController.cc:181
gem5::ruby::AbstractController::resetStats
virtual void resetStats()=0
Callback to reset stats.
Definition: AbstractController.cc:121
AbstractController.hh
gem5::Packet::isWrite
bool isWrite() const
Definition: packet.hh:594
gem5::ruby::RubySystem::getBlockSizeBytes
static uint32_t getBlockSizeBytes()
Definition: RubySystem.hh:72
gem5::Packet::createWrite
static PacketPtr createWrite(const RequestPtr &req)
Definition: packet.hh:1044
gem5::X86ISA::system
Bitfield< 15 > system
Definition: misc.hh:1004
gem5::ruby::AbstractController::mapAddressToDownstreamMachine
MachineID mapAddressToDownstreamMachine(Addr addr, MachineType mtype=MachineType_NUM) const
Maps an address to the correct dowstream MachineID (i.e.
Definition: AbstractController.cc:426
gem5::ruby::AbstractController::dequeueMemRespQueue
void dequeueMemRespQueue()
Definition: AbstractController.cc:458
gem5::EventManager::schedule
void schedule(Event &event, Tick when)
Definition: eventq.hh:1012
std::vector
STL vector class.
Definition: stl.hh:37
gem5::ruby::AbstractController::m_block_map
std::map< Addr, MessageBuffer * > m_block_map
Definition: AbstractController.hh:361
gem5::ruby::AbstractController::isBlocked
bool isBlocked(Addr) const
Definition: AbstractController.cc:327
gem5::csprintf
std::string csprintf(const char *format, const Args &...args)
Definition: cprintf.hh:161
gem5::ruby::Consumer
Definition: Consumer.hh:61
gem5::ruby::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:348
gem5::ArmISA::i
Bitfield< 7 > i
Definition: misc_types.hh:67
gem5::ruby::AbstractController::MsgVecType
std::vector< MessageBuffer * > MsgVecType
Definition: AbstractController.hh:363
gem5::ruby::AbstractController::m_is_blocking
bool m_is_blocking
Definition: AbstractController.hh:360
gem5::ruby::AbstractController
Definition: AbstractController.hh:83
gem5::ruby::AbstractController::memRespQueueDequeued
void memRespQueueDequeued()
Definition: AbstractController.cc:451
gem5::ruby::MessageBuffer::reanalyzeMessages
void reanalyzeMessages(Addr addr, Tick current_time)
Definition: MessageBuffer.cc:403
gem5::statistics::DistBase::sample
void sample(const U &v, int n=1)
Add a value to the distribtion n times.
Definition: statistics.hh:1327
gem5::ruby::AbstractController::ControllerStats::delayHistogram
statistics::Histogram delayHistogram
Histogram for profiling delay for the messages this controller cares for.
Definition: AbstractController.hh:450
gem5::ruby::AbstractController::m_waiting_mem_retry
bool m_waiting_mem_retry
Definition: AbstractController.hh:375
gem5::RequestPort
A RequestPort is a specialisation of a Port, which implements the default protocol for the three diff...
Definition: port.hh:118
gem5::statistics::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:329
gem5::Cycles
Cycles is a wrapper class for representing cycle counts, i.e.
Definition: types.hh:78
gem5::statistics::Histogram
A simple histogram stat.
Definition: statistics.hh:2125
gem5::ruby::AbstractController::ControllerStats::delayVCHistogram
std::vector< statistics::Histogram * > delayVCHistogram
Definition: AbstractController.hh:451
gem5::ruby::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:480
gem5::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:563
gem5::Packet::isRead
bool isRead() const
Definition: packet.hh:593
gem5::ruby::AbstractController::functionalMemoryWrite
int functionalMemoryWrite(PacketPtr)
Definition: AbstractController.cc:363
gem5::Named::name
virtual std::string name() const
Definition: named.hh:47
gem5::VegaISA::p
Bitfield< 54 > p
Definition: pagetable.hh:70
gem5::Clocked::cyclesToTicks
Tick cyclesToTicks(Cycles c) const
Definition: clocked_object.hh:227
gem5::SimObject::params
const Params & params() const
Definition: sim_object.hh:176
gem5::ruby::Consumer::scheduleEvent
void scheduleEvent(Cycles timeDelta)
Definition: Consumer.cc:56
DPRINTF
#define DPRINTF(x,...)
Definition: trace.hh:210
ADD_STAT
#define ADD_STAT(n,...)
Convenience macro to add a stat to a statistics group.
Definition: group.hh:75
gem5::Packet
A Packet is used to encapsulate a transfer between two objects in the memory system (e....
Definition: packet.hh:294
gem5::ruby::MessageBuffer::functionalRead
bool functionalRead(Packet *pkt)
Definition: MessageBuffer.hh:182
gem5::ruby::AbstractController::mapAddressToMachine
MachineID mapAddressToMachine(Addr addr, MachineType mtype) const
Map an address to the correct MachineID.
Definition: AbstractController.cc:418
gem5::Tick
uint64_t Tick
Tick count type.
Definition: types.hh:58
gem5::RequestPort::sendRetryResp
virtual void sendRetryResp()
Send a retry to the response port that previously attempted a sendTimingResp to this request port and...
Definition: port.hh:621
gem5::RequestPtr
std::shared_ptr< Request > RequestPtr
Definition: request.hh:92
gem5::ruby::AbstractController::recvAtomic
Tick recvAtomic(PacketPtr pkt)
Definition: AbstractController.cc:412
gem5::ruby::AbstractController::ControllerStats::ControllerStats
ControllerStats(statistics::Group *parent)
Definition: AbstractController.cc:494
gem5::ruby::AbstractController::m_cur_in_port
unsigned int m_cur_in_port
Definition: AbstractController.hh:369
gem5::ruby::AbstractController::downstreamDestinations
NetDest downstreamDestinations
Definition: AbstractController.hh:421
gem5::ruby::getOffset
Addr getOffset(Addr addr)
Definition: Address.cc:54
gem5::ruby::AbstractController::MemoryPort::MemoryPort
MemoryPort(const std::string &_name, AbstractController *_controller, PortID id=InvalidPortID)
Definition: AbstractController.cc:486
gem5::ruby::AbstractController::AbstractController
AbstractController(const Params &p)
Definition: AbstractController.cc:56
gem5::ruby::AbstractController::mRetryRespEvent
MemberEventWrapper<&AbstractController::sendRetryRespToMem > mRetryRespEvent
Definition: AbstractController.hh:425
gem5::ruby::AbstractController::downstreamAddrMap
std::unordered_map< MachineType, AddrRangeMap< MachineID, 3 > > downstreamAddrMap
Definition: AbstractController.hh:419
gem5::ruby::AbstractController::m_mem_ctrl_waiting_retry
bool m_mem_ctrl_waiting_retry
Definition: AbstractController.hh:376
RubySystem.hh
gem5::Addr
uint64_t Addr
Address type This will probably be moved somewhere else in the near future.
Definition: types.hh:147
gem5::statistics::Histogram::init
Histogram & init(size_type size)
Set the parameters of this histogram.
Definition: statistics.hh:2153
gem5::Packet::senderState
SenderState * senderState
This packet's sender state.
Definition: packet.hh:545
name
const std::string & name()
Definition: trace.cc:48
gem5::ruby::AbstractController::SenderState
Definition: AbstractController.hh:405
gem5::ruby::AbstractController::m_waiting_buffers
WaitingBufType m_waiting_buffers
Definition: AbstractController.hh:366
gem5::ruby::AbstractController::m_machineID
MachineID m_machineID
Definition: AbstractController.hh:353
gem5::statistics::Group::regStats
virtual void regStats()
Callback to set stat parameters.
Definition: group.cc:68
gem5::ruby::AbstractController::recvTimingResp
bool recvTimingResp(PacketPtr pkt)
Definition: AbstractController.cc:373
gem5::ClockedObject
The ClockedObject class extends the SimObject with a clock and accessor functions to relate ticks to ...
Definition: clocked_object.hh:234
gem5::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:177
gem5::ruby::AbstractController::init
void init()
init() is called after all C++ SimObjects have been created and all ports are connected.
Definition: AbstractController.cc:79
gem5::ruby::AbstractController::unblock
void unblock(Addr)
Definition: AbstractController.cc:333
gem5::ruby::AbstractController::stats
gem5::ruby::AbstractController::ControllerStats stats
gem5::ruby::MessageBuffer::setConsumer
void setConsumer(Consumer *consumer)
Definition: MessageBuffer.hh:105
Network.hh
gem5::ruby::AbstractController::wakeUpAllBuffers
void wakeUpAllBuffers()
Definition: AbstractController.cc:222
gem5::ArmISA::q
Bitfield< 27 > q
Definition: misc_types.hh:55
gem5::Packet::allocate
void allocate()
Allocate memory for the packet.
Definition: packet.hh:1367
gem5::Port
Ports are used to interface objects to each other.
Definition: port.hh:61
gem5::ruby::AbstractController::m_in_ports
unsigned int m_in_ports
Definition: AbstractController.hh:368
gem5::ruby::Network::addressToNodeID
NodeID addressToNodeID(Addr addr, MachineType mtype)
Map an address to the correct NodeID.
Definition: Network.cc:235
gem5::ruby::AbstractController::MemoryPort::recvTimingResp
bool recvTimingResp(PacketPtr pkt)
Receive a timing response from the peer.
Definition: AbstractController.cc:474
gem5::ruby::RubySystem::getWarmupEnabled
static bool getWarmupEnabled()
Definition: RubySystem.hh:75
gem5::ruby::AbstractController::m_net_ptr
Network * m_net_ptr
Definition: AbstractController.hh:359
gem5::ruby::AbstractController::functionalMemoryRead
void functionalMemoryRead(PacketPtr)
Definition: AbstractController.cc:354
gem5::ruby::AbstractController::upstreamDestinations
NetDest upstreamDestinations
Definition: AbstractController.hh:422
gem5::Packet::dataDynamic
void dataDynamic(T *p)
Set the data pointer to a value that should have delete [] called on it.
Definition: packet.hh:1213
gem5::ruby::NetDest::resize
void resize()
Definition: NetDest.cc:253
gem5::ruby::AbstractController::sendRetryRespToMem
void sendRetryRespToMem()
Definition: AbstractController.cc:466
gem5::statistics::Group
Statistics container.
Definition: group.hh:92
gem5::ruby::AbstractController::m_id
const RequestorID m_id
Definition: AbstractController.hh:357
gem5::ArmISA::id
Bitfield< 33 > id
Definition: misc_types.hh:305
gem5::ruby::NodeID
unsigned int NodeID
Definition: TypeDefines.hh:42
gem5::ruby::NetDest::add
void add(MachineID newElement)
Definition: NetDest.cc:45
gem5::ruby::AbstractController::regStats
virtual void regStats()
Callback to set stat parameters.
Definition: AbstractController.cc:131
gem5::ruby::AbstractController::MemoryPort::controller
AbstractController * controller
Definition: AbstractController.hh:386
gem5::statistics::DistBase::reset
void reset()
Reset stat value to default.
Definition: statistics.hh:1351
gem5::ClockedObject::Params
ClockedObjectParams Params
Parameters of ClockedObject.
Definition: clocked_object.hh:240
gem5::statistics::DataWrap::flags
Derived & flags(Flags _flags)
Set the flags and marks this stat to print at the end of simulation.
Definition: statistics.hh:357
gem5::Clocked::ticksToCycles
Cycles ticksToCycles(Tick t) const
Definition: clocked_object.hh:222
gem5_assert
#define gem5_assert(cond,...)
The assert macro will function like a normal assert, but will use panic instead of straight abort().
Definition: logging.hh:317
gem5::ruby::AbstractController::memoryPort
MemoryPort memoryPort
Definition: AbstractController.hh:402
gem5::ruby::MessageBuffer
Definition: MessageBuffer.hh:74
std::list< AddrRange >
gem5::Packet::getAddr
Addr getAddr() const
Definition: packet.hh:807
gem5
Reference material can be found at the JEDEC website: UFS standard http://www.jedec....
Definition: gpu_translation_state.hh:37
gem5::Packet::createRead
static PacketPtr createRead(const RequestPtr &req)
Constructor-like methods that return Packets based on Request objects.
Definition: packet.hh:1038
gem5::ruby::AbstractController::getMemRespQueue
virtual MessageBuffer * getMemRespQueue() const =0
gem5::ruby::MachineID
Definition: MachineID.hh:56
gem5::ruby::AbstractController::blockOnQueue
void blockOnQueue(Addr, MessageBuffer *)
Definition: AbstractController.cc:320
gem5::Packet::isResponse
bool isResponse() const
Definition: packet.hh:598
gem5::Named::_name
const std::string _name
Definition: named.hh:41
gem5::Event::scheduled
bool scheduled() const
Determine if the current event is scheduled.
Definition: eventq.hh:458
gem5::ruby::AbstractController::wakeUpBuffer
void wakeUpBuffer(MessageBuffer *buf, Addr addr)
Definition: AbstractController.cc:159
panic
#define panic(...)
This implements a cprintf based panic() function.
Definition: logging.hh:188
gem5::X86ISA::addr
Bitfield< 3 > addr
Definition: types.hh:84
gem5::ruby::AbstractController::stallBuffer
void stallBuffer(MessageBuffer *buf, Addr addr)
Definition: AbstractController.cc:145
gem5::SenderState
RubyTester::SenderState SenderState
Definition: Check.cc:40
gem5::Packet::getPtr
T * getPtr()
get a pointer to the data ptr.
Definition: packet.hh:1225
Sequencer.hh

Generated on Sun Jul 30 2023 01:56:59 for gem5 by doxygen 1.8.17