gem5 v24.0.0.0
|
#include <q_policy.hh>
Public Types | |
typedef std::deque< PacketPtr > | PacketQueue |
Public Member Functions | |
virtual void | enqueuePacket (PacketPtr pkt) |
This method is called by the memory controller after it enqueues a packet. | |
virtual PacketQueue::iterator | selectPacket (PacketQueue *queue)=0 |
Policy selector. | |
void | setMemCtrl (MemCtrl *mem) |
Setting a pointer to the Memory Controller implementing the policy. | |
virtual | ~QueuePolicy () |
Static Public Member Functions | |
static QueuePolicy * | create (const QoSMemCtrlParams &p) |
This factory method is used for generating the queue policy. | |
Protected Member Functions | |
QueuePolicy (const QoSMemCtrlParams &p) | |
Protected Attributes | |
MemCtrl * | memCtrl |
Pointer to parent memory controller implementing the policy. | |
The QoS Queue Policy class implements algorithms to schedule packets within the same QoS priority queue
Definition at line 65 of file q_policy.hh.
Definition at line 68 of file q_policy.hh.
|
inlinevirtual |
Definition at line 108 of file q_policy.hh.
|
inlineprotected |
Definition at line 111 of file q_policy.hh.
|
static |
This factory method is used for generating the queue policy.
It takes the memory controller params as an argument and returns the related QueuePolicy object. If no particular QueuePolicy has been specified in the QoSMemCtrlParams, the method will default to a LIFO queue policy.
p | qos::MemCtrl parameter variable |
Definition at line 59 of file q_policy.cc.
References gem5::MipsISA::p.
|
inlinevirtual |
This method is called by the memory controller after it enqueues a packet.
It is a way for the queue policy to hook into the packet enqueuing and update relevant metadata. This will then be used once the QueuePolicy::selectPacket will be called.
pkt | Enqueued packet |
Reimplemented in gem5::memory::qos::LrgQueuePolicy.
Definition at line 89 of file q_policy.hh.
|
pure virtual |
Policy selector.
The implementation of this virtual method selects the packet to be serviced from the packet queue passed as an argument.
queue | Non-empty packet queue to select a packet from |
Implemented in gem5::memory::qos::FifoQueuePolicy, gem5::memory::qos::LifoQueuePolicy, and gem5::memory::qos::LrgQueuePolicy.
|
inline |
Setting a pointer to the Memory Controller implementing the policy.
Definition at line 106 of file q_policy.hh.
|
protected |
Pointer to parent memory controller implementing the policy.
Definition at line 116 of file q_policy.hh.
Referenced by gem5::memory::qos::LrgQueuePolicy::enqueuePacket(), gem5::memory::qos::LrgQueuePolicy::selectPacket(), and setMemCtrl().