mem-garnet: Fix garnet network interface stats
authorjiemingyin <bjm419@gmail.com>
Wed, 21 Oct 2020 23:43:05 +0000 (19:43 -0400)
committerJieming Yin <bjm419@gmail.com>
Thu, 22 Oct 2020 12:51:49 +0000 (12:51 +0000)
Fixing a bug in garnet network interface where flit source delay is
computed using both tick and cycle.

Change-Id: If21a985f371a818611d13e9cd5ce344dbcf5fb2b
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/36416
Reviewed-by: Srikant Bharadwaj <srikant.bharadwaj@amd.com>
Maintainer: Matthew Poremba <matthew.poremba@amd.com>
Tested-by: kokoro <noreply+kokoro@google.com>
src/mem/ruby/network/garnet/NetworkInterface.cc

index bbff5b416bedcd8c01d00d3fb97e2f2bc89f7375..e6c22000c5a27dee4bb5c0de98c1c831b818a286 100644 (file)
@@ -435,7 +435,7 @@ NetworkInterface::flitisizeMessage(MsgPtr msg_ptr, int vnet)
                 net_msg_ptr->getMessageSize()),
                 oPort->bitWidth(), curTick());
 
-            fl->set_src_delay(curTick() - ticksToCycles(msg_ptr->getTime()));
+            fl->set_src_delay(curTick() - msg_ptr->getTime());
             niOutVcs[vc].insert(fl);
         }