I am still digging into how the cache configuration is specified.
Currently, the system has four caches - two 32 KB, 256 sets, 2-way
associative caches, one 2 MB, 2048 sets, 16-way set associative cache, and
one 4 MB, 16384 sets, 4-set associative cache. Each of these caches make
use of a hash table having only 193 buckets. This seems too low to me.
Clearly if the cache is being used to full capacity, look ups in the hash
table will have to go through lot many entries before figuring out whether
the address being searched for is in the cache or not.
--
Nilay
On Fri, 5 Nov 2010, Steve Reinhardt wrote:
If that's where a significant amount of time is being spent, we need to
either call it less or make it run faster :-). Doing both is even better.
At a high level, the process of looking something up in an N-way associative
cache should not take that many instructions if N is small (a shift and an
add to find the tag index, at most N loads and compares to match the tags).
If we reorder the tags to search the MRU block first then we will
probabilistically keep the average number of tags searched well below N.
Steve
On Fri, Nov 5, 2010 at 9:27 AM, Nilay Vaish <[email protected]> wrote:
I had another look at the profile output. On the machine that I am using (a
3.2 GHz Pentium 4), each call to isTagPresent() take about 57 ns. Assuming
that the pipeline is functioning at is best, I think the number of uops
executed would be ~500. Is that too much for this function?
--
Nilay
On Fri, 5 Nov 2010, Nilay Vaish wrote:
Do you know what hash function is in use? Seems to me that the default
hash function is to hash to self. May be we should test with a different
hash function.
--
Nilay
On Fri, 5 Nov 2010, Steve Reinhardt wrote:
You can look at the call graph profile further down in the gprof output
to
figure out how much time is spent in functions that get called from
isTagPresent. If it's not specifically calling out findTagInSet, it may
be
because it's inlined in isTagPresent.
Steve
_______________________________________________
m5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/m5-dev
_______________________________________________
m5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/m5-dev