41#ifndef __MEM_RUBY_SLICC_INTERFACE_MESSAGE_HH__
42#define __MEM_RUBY_SLICC_INTERFACE_MESSAGE_HH__
51#include "mem/ruby/protocol/MessageSizeType.hh"
60typedef std::shared_ptr<Message>
MsgPtr;
76 virtual void print(std::ostream& out)
const = 0;
79 {
panic(
"MessageSizeType() called on wrong message!"); }
81 {
panic(
"MessageSizeType() called on wrong message!"); }
91 {
panic(
"functionalRead(Packet) not implemented"); }
93 {
panic(
"functionalRead(Packet,WriteMask) not implemented"); }
95 {
panic(
"functionalWrite(Packet) not implemented"); }
115 {
panic(
"getDestination() called on wrong message!"); }
117 {
panic(
"getDestination() called on wrong message!"); }
141 if (
l->getLastEnqueueTime() ==
r->getLastEnqueueTime()) {
144 return l->getLastEnqueueTime() >
r->getLastEnqueueTime();
A Packet is used to encapsulate a transfer between two objects in the memory system (e....
uint64_t getMsgCounter() const
virtual bool functionalRead(Packet *pkt, WriteMask &mask)
Tick getDelayedTicks() const
virtual MessageSizeType & getMessageSize()
virtual bool functionalRead(Packet *pkt)
The two functions below are used for reading / writing the message functionally.
virtual const NetDest & getDestination() const
int getIncomingLink() const
Tick getLastEnqueueTime() const
Message(const Message &other)=default
virtual bool functionalWrite(Packet *pkt)
void updateDelayedTicks(Tick curTime)
Update the delay this message has experienced so far.
virtual void print(std::ostream &out) const =0
void setIncomingLink(int link)
virtual NetDest & getDestination()
virtual MsgPtr clone() const =0
void setMsgCounter(uint64_t c)
void setLastEnqueueTime(const Tick &time)
virtual const MessageSizeType & getMessageSize() const
#define panic(...)
This implements a cprintf based panic() function.
std::shared_ptr< Message > MsgPtr
bool operator>(const MsgPtr &lhs, const MsgPtr &rhs)
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.
Declaration of the Packet class.