From 58033095745e9daba44b31541bb21599bb999141 Mon Sep 17 00:00:00 2001 From: Andreas Hansson Date: Tue, 21 Aug 2012 05:49:24 -0400 Subject: PacketQueue: Allow queuing in the same tick as desired send tick This patch allows packets to be enqueued in the same tick as they are intended to be sent. This does not imply they actually are sent that tick, although that is possible. This change is useful for module that use the queued ports primarly to avoid handling the flow control involved in sending and retrying packets. --- src/mem/packet_queue.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/mem/packet_queue.cc') diff --git a/src/mem/packet_queue.cc b/src/mem/packet_queue.cc index 77fba8883..37aa2dcda 100644 --- a/src/mem/packet_queue.cc +++ b/src/mem/packet_queue.cc @@ -106,7 +106,8 @@ PacketQueue::schedSendEvent(Tick when) void PacketQueue::schedSendTiming(PacketPtr pkt, Tick when, bool send_as_snoop) { - assert(when > curTick()); + // we can still send a packet before the end of this tick + assert(when >= curTick()); // nothing on the list, or earlier than current front element, // schedule an event -- cgit v1.2.3