|
gem5
v19.0.0.0
|
A write queue for all eviction packets, i.e. More...
#include <write_queue.hh>
Public Member Functions | |
| WriteQueue (const std::string &_label, int num_entries, int reserve) | |
| Create a write queue with a given number of entries. More... | |
| WriteQueueEntry * | allocate (Addr blk_addr, unsigned blk_size, PacketPtr pkt, Tick when_ready, Counter order) |
| Allocates a new WriteQueueEntry for the request and size. More... | |
| void | markInService (WriteQueueEntry *entry) |
| Mark the given entry as in service. More... | |
Public Member Functions inherited from Queue< WriteQueueEntry > | |
| Queue (const std::string &_label, int num_entries, int reserve) | |
| Create a queue with a given number of entries. More... | |
| bool | isEmpty () const |
| bool | isFull () const |
| int | numInService () const |
| WriteQueueEntry * | findMatch (Addr blk_addr, bool is_secure, bool ignore_uncacheable=true) const |
| Find the first entry that matches the provided address. More... | |
| bool | trySatisfyFunctional (PacketPtr pkt) |
| WriteQueueEntry * | findPending (const QueueEntry *entry) const |
| Find any pending requests that overlap the given request of a different queue. More... | |
| WriteQueueEntry * | getNext () const |
| Returns the WriteQueueEntry at the head of the readyList. More... | |
| Tick | nextReadyTime () const |
| void | deallocate (WriteQueueEntry *entry) |
| Removes the given entry from the queue. More... | |
| DrainState | drain () override |
| Notify an object that it needs to drain its state. More... | |
Public Member Functions inherited from Drainable | |
| DrainState | drainState () const |
| Return the current drain state of an object. More... | |
| virtual void | notifyFork () |
| Notify a child process of a fork. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from Queue< WriteQueueEntry > | |
| WriteQueueEntry ::Iterator | addToReadyList (WriteQueueEntry *entry) |
Protected Member Functions inherited from Drainable | |
| Drainable () | |
| virtual | ~Drainable () |
| virtual void | drainResume () |
| Resume execution after a successful drain. More... | |
| void | signalDrainDone () const |
| Signal that an object is drained. More... | |
Protected Attributes inherited from Queue< WriteQueueEntry > | |
| const std::string | label |
| Local label (for functional print requests) More... | |
| const int | numEntries |
| The total number of entries in this queue. More... | |
| const int | numReserve |
| The number of entries to hold as a temporary overflow space. More... | |
| std::vector< WriteQueueEntry > | entries |
| Actual storage. More... | |
| WriteQueueEntry ::List | allocatedList |
| Holds pointers to all allocated entries. More... | |
| WriteQueueEntry ::List | readyList |
| Holds pointers to entries that haven't been sent downstream. More... | |
| WriteQueueEntry ::List | freeList |
| Holds non allocated entries. More... | |
| int | _numInService |
| The number of entries that are in service. More... | |
| int | allocated |
| The number of currently allocated entries. More... | |
A write queue for all eviction packets, i.e.
writebacks and clean evictions, as well as uncacheable writes.
Definition at line 59 of file write_queue.hh.
| WriteQueue::WriteQueue | ( | const std::string & | _label, |
| int | num_entries, | ||
| int | reserve | ||
| ) |
Create a write queue with a given number of entries.
| num_entries | The number of entries in this queue. |
| reserve | The maximum number of entries needed to satisfy any access. |
Definition at line 55 of file write_queue.cc.
| WriteQueueEntry * WriteQueue::allocate | ( | Addr | blk_addr, |
| unsigned | blk_size, | ||
| PacketPtr | pkt, | ||
| Tick | when_ready, | ||
| Counter | order | ||
| ) |
Allocates a new WriteQueueEntry for the request and size.
This places the request as the first target in the WriteQueueEntry.
| blk_addr | The address of the block. |
| blk_size | The number of bytes to request. |
| pkt | The original write. |
| when_ready | When is the WriteQueueEntry be ready to act upon. |
| order | The logical order of this WriteQueueEntry |
Definition at line 61 of file write_queue.cc.
References Queue< WriteQueueEntry >::addToReadyList(), WriteQueueEntry::allocate(), Queue< WriteQueueEntry >::allocated, Queue< WriteQueueEntry >::allocatedList, Queue< WriteQueueEntry >::freeList, and WriteQueueEntry::readyIter.
Referenced by BaseCache::allocateWriteBuffer().
| void WriteQueue::markInService | ( | WriteQueueEntry * | entry | ) |
Mark the given entry as in service.
This removes the entry from the readyList or deallocates the entry if it does not expect a response (writeback/eviction rather than an uncacheable write).
| entry | The entry to mark in service. |
Definition at line 78 of file write_queue.cc.
References Queue< WriteQueueEntry >::deallocate(), and WriteQueueEntry::popTarget().
Referenced by BaseCache::markInService().