Cache Replacement policy and Cache Banks

17 views
Skip to first unread message

Vinay

unread,
Nov 16, 2011, 5:56:28 PM11/16/11
to MV5sim
Hi Jiayuan,

Can we change the cache replacement policy, like LRU or MRU , If yes
where can we set the parameter?
Also how can we vary the number of banks ?

I did see the parameters in ~/hgfractal/src/mem/cache/BaseCache.py :

lru = Param.Bool(True, "whether the LRU replacement policy is
used")
mru = Param.Bool(False, "whether the MRU replacement policy is
used")
lrgu = Param.Bool(False, "whether the LRGU replacement policy is
used")

numBanks = Param.Int(1, "number of banks this cache has, must be
>=1")

Can these parameters be included in either ~/configs/fractal/
fractal_smp.py or config_hetero.py ?

Thanks,
Vinay

Vinay V.L

unread,
Nov 16, 2011, 6:05:34 PM11/16/11
to MV5sim
I just noticed that that the number of banks can be changed separately for both DCache and L2. throught fractal_smp.py Sorry about that, I take back my question.

I am concerned about L2 Cache replacement policy. Is it possible vary it ?

Thanks,
Vinay

Jiayuan Meng

unread,
Nov 17, 2011, 3:13:10 AM11/17/11
to mv5...@googlegroups.com
Yes, in frCommon.py, you can see each cache class has a "repl" attribute. Actually in the commandline, there are DcacheRepl and l2Repl, with which you can specify the replacement policy. 

Jiayuan
Reply all
Reply to author
Forward
0 new messages