HI Andreas,
I think you got it wrong. forward snoop - should we send a snoop traffic upward. You might always want to do this with something like an LSQ. is top level - should ownership ever be provided to the entity above it. If a cache isn't marked is_top_level and it gets a cache line sized read it may provide the entire cache block and ownership to the entity above it. This is great if it's a L1<-L2 transfer, but if you accidentally do it to with a dirty line to something that isn't expecting to own the line than is a problem. In a word, yes there are cases where is top level is true and you want to forward the snoops. I don't think there is a case where is top level is false and you don't want to forward snoops, thus while there are currently four states, there could be three states. Ali On 19.01.2012 11:00, Andreas Hansson wrote: > Hi all, > > One of our next steps to the memory system is to separate out snooping messages from "normal" messages. This will eventually enable us to classify ports as coherent/non-coherent masters/slaves. When looking at how the caches deal with forwarding snoops at the moment, there is a slight ambiguity between the two options is_top_level and foward_snoops. Is there ever a case where is_top_level is true and we should still forward snoops? I would imagine that if the CPU has no caching, e.g. a normal atomic/timing CPU then is_top_level for the L1 is true and the cache should not forward snoops. If we use the O3 CPU with a snooping LSQ, then is_top_level should be false, and we should indeed forward snoops. > > Did I get this completely wrong, or do you agree? > > I have made the following change in the cache and all quick regressions (ARM, ALPHA, X86) still pass. > > diff --git a/src/mem/cache/base.cc b/src/mem/cache/base.cc > --- a/src/mem/cache/base.cc > +++ b/src/mem/cache/base.cc > @@ -57,7 +57,7 @@ > blkSize(p->block_size), > hitLatency(p->latency), > numTarget(p->tgts_per_mshr), > - forwardSnoops(p->forward_snoops), > + forwardSnoops(p->forward_snoops && !p->is_top_level), > isTopLevel(p->is_top_level), > blocked(0), > noTargetMSHR(NULL), > > Andreas > > -- IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you. > _______________________________________________ > gem5-dev mailing list > [email protected] > http://m5sim.org/mailman/listinfo/gem5-dev _______________________________________________ gem5-dev mailing list [email protected] http://m5sim.org/mailman/listinfo/gem5-dev
