80 Tick arrival_time = current_time + delta;
81 assert(arrival_time > current_time);
83 Message* msg_ptr = message.get();
88 scheduleEventAbsolute(arrival_time);
90 panic(
"No Consumer for WireBuffer! %s\n", *
this);
99 std::greater<MsgPtr>());
107 assert(msg_ptr != NULL);
121 std::greater<MsgPtr>());
123 Tick future_time = current_time + recycle_latency;
124 node->setLastEnqueueTime(future_time);
128 std::greater<MsgPtr>());
130 scheduleEventAbsolute(future_time);
Abstract superclass for simulation objects.
void setLastEnqueueTime(const Tick &time)
WireBuffer(const Params &p)
void enqueue(MsgPtr message, Tick current_time, Tick delta)
void init()
init() is called after all C++ SimObjects have been created and all ports are connected.
void recycle(Tick current_time, Tick recycle_latency)
void print(std::ostream &out) const
std::vector< MsgPtr > m_message_queue
Consumer * m_consumer_ptr
void dequeue(Tick current_time)
RubyWireBufferParams Params
bool isReady(Tick current_time)
#define panic(...)
This implements a cprintf based panic() function.
std::shared_ptr< Message > MsgPtr
std::ostream & operator<<(std::ostream &os, const BoolVec &myvector)
Copyright (c) 2024 - Pranith Kumar Copyright (c) 2020 Inria All rights reserved.
uint64_t Tick
Tick count type.