summaryrefslogtreecommitdiff
path: root/src/mem/packet_queue.hh
diff options
context:
space:
mode:
authorStephan Diestelhorst <stephan.diestelhorst@arm.com>2015-03-02 04:00:49 -0500
committerStephan Diestelhorst <stephan.diestelhorst@arm.com>2015-03-02 04:00:49 -0500
commitecef1612b8a9a5632c8354ccb000184c2f82ddf3 (patch)
treec7c21dfc5aa15f3a552fbfb59e7474d1307e7934 /src/mem/packet_queue.hh
parentd4ef8368aa1dfb5e1e1ebe155c0fce1070046f83 (diff)
downloadgem5-ecef1612b8a9a5632c8354ccb000184c2f82ddf3.tar.xz
mem: Add option to force in-order insertion in PacketQueue
By default, the packet queue is ordered by the ticks of the to-be-sent packages. With the recent modifications of packages sinking their header time when their resposne leaves the caches, there could be cases of MSHR targets being allocated and ordered A, B, but their responses being sent out in the order B,A. This led to inconsistencies in bus traffic, in particular the snoop filter observing first a ReadExResp and later a ReadRespWithInv. Logically, these were ordered the other way around behind the MSHR, but due to the timing adjustments when inserting into the PacketQueue, they were sent out in the wrong order on the bus, confusing the snoop filter. This patch adds a flag (off by default) such that these special cases can request in-order insertion into the packet queue, which might offset timing slighty. This is expected to occur rarely and not affect timing results.
Diffstat (limited to 'src/mem/packet_queue.hh')
-rw-r--r--src/mem/packet_queue.hh4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mem/packet_queue.hh b/src/mem/packet_queue.hh
index 164ff6345..6584fe997 100644
--- a/src/mem/packet_queue.hh
+++ b/src/mem/packet_queue.hh
@@ -180,8 +180,10 @@ class PacketQueue : public Drainable
*
* @param pkt Packet to send
* @param when Absolute time (in ticks) to send packet
+ * @param force_order Do not reorder packets despite timing, but keep them
+ * in insertion order.
*/
- void schedSendTiming(PacketPtr pkt, Tick when);
+ void schedSendTiming(PacketPtr pkt, Tick when, bool force_order = false);
/**
* Retry sending a packet from the queue. Note that this is not