From 11accacf7c9de8147e68845051a489c251c4e7b1 Mon Sep 17 00:00:00 2001 From: Ron Dreslinski Date: Sun, 12 Nov 2006 06:44:05 -0500 Subject: [PATCH] Move code before a early return to make sure it is executed on all paths --HG-- extra : convert_revision : cfdd5b6911422fbb733677c43d027aa4407fbc85 --- src/mem/cache/cache_impl.hh | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/src/mem/cache/cache_impl.hh b/src/mem/cache/cache_impl.hh index 51aa4f8e7..8acc67b69 100644 --- a/src/mem/cache/cache_impl.hh +++ b/src/mem/cache/cache_impl.hh @@ -476,6 +476,13 @@ Cache::snoop(PacketPtr &pkt) } CacheBlk::State new_state; bool satisfy = coherence->handleBusRequest(pkt,blk,mshr, new_state); + + if (blk && mshr && !mshr->inService && new_state == 0) { + //There was a outstanding write to a shared block, not need ReadEx + //not update, so change No Allocate param in MSHR + mshr->pkt->flags &= ~NO_ALLOCATE; + } + if (satisfy) { DPRINTF(Cache, "Cache snooped a %s request for addr %x and " "now supplying data, new state is %i\n", @@ -485,15 +492,10 @@ Cache::snoop(PacketPtr &pkt) respondToSnoop(pkt, curTick + hitLatency); return; } - if (blk) { + if (blk) DPRINTF(Cache, "Cache snooped a %s request for addr %x, " "new state is %i\n", pkt->cmdString(), blk_addr, new_state); - if (mshr && !mshr->inService && new_state == 0) { - //There was a outstanding write to a shared block, not need ReadEx - //not update, so change No Allocate param in MSHR - mshr->pkt->flags &= ~NO_ALLOCATE; - } - } + tags->handleSnoop(blk, new_state); } -- 2.30.2