Hi,

'way' parameter literally means way of the set-associative cache. It is
initialized in a constructor of BaseSetAssoc class (Here, set is also
initialized in). allocAssoc is similar to assoc which is given by your
simulation configuration. "blks" is an array of cache block which is sorted
in an access order. Therefore, 'b->way < allocAssoc' means "just choose a
cache block in the tail.
As you can notice, the default LRU implementation in gem5 is an ideal LRU,
not approximation.

Sincerely,
Joonsung Kim.

2018-03-19 10:24 GMT+09:00 ?? ? <[email protected]>:

>
>
> Hi,
>
>
>
> I am a student using GEM5 to simulate the performance with different
> benchmarks.
>
>
>
> After different experiments, now I am interested in the cache replacement
> polices implementing in GEM5.
>
>
>
> From tracing the code, I can find out that the function "CacheBlk*
> LRU::findVictim" is which GEM5 decides the victim to be replaced.
>
>
>
> But I can't understand the key if statement 'b->way < allocAssoc' to
> decide the victim.
>
>
>
> I have gone through all the official document and there is no comment or
> other instruction about what is the 'way' parameter and how it works.
>
>
>
> Where can I learn more about how GEM5 implement different cache
> replacement polices or you can shortly describe the functionality of 'way'
> and when will the value be changed ?
>
>
>
> And is the LRU implemented in the GEM5 still the real LRU as before or an
> approximation of LRU?  Cause I have read the code releasing few years ago
> and it seems to be a real LRU.
>
>
>
> BTW, the GEM5 is an awesome software that I can run so many different
> experiments to simulate the performance.
>
>
>
> I am very appreciate having chance to use such a powerful program.
>
>
>
> Thanks.
>
>
>
> Tseng,
>
> 03/18/2018
>
>
>
> _______________________________________________
> gem5-users mailing list
> [email protected]
> http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users
>
_______________________________________________
gem5-users mailing list
[email protected]
http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users

Reply via email to