Re: [Gems-users] Modifying cache line and eviction scheme


Date: Tue, 28 Feb 2006 08:30:23 -0600 (CST)
From: Mike Marty <mikem@xxxxxxxxxxx>
Subject: Re: [Gems-users] Modifying cache line and eviction scheme
Hi Gene,

The cache replacement policy is implemented in
$GEMS/ruby/system/CacheMemory.h, in the cacheProbe() method.

You can add extra bits to cache lines in two ways.  The first is adding
protocol-specific bits to the SLICC specification of ENTRY ( in each
-cache.sm file ).  However for your purposes, it seems better to add these
to $GEMS/ruby/slicc_interface/AbstractCacheEntry.h so that they are easily
accessed by CacheMemory methods.

The Ruby Sequencer is the Processor-Cache interface
($GEMS/ruby/system/Sequencer.C).  It calls the CacheMemory::setMRU
directly on the L1 caches because it directly checks for a cache hit/miss
and bypasses the controllers on a hit.

For the CMP protocols that have a seperate controller for the L1 and L2
caches, setMRU is called in the protocol specification.  For example, the
$GEMS/protocols/MSI_MOSI_CMP_directory-L2cache.sm controller specification
calls setMRU on all L2 accesses.

Hope this helps.

--Mike


> Hi all,
>
> I am new to GEMS, but for my research I would like to add an extra field
> to the cache lines and also modify the cache block eviction scheme (from
> the basic LRU scheme). Ideally these changes would be independent of the
> cache coherency protocol, but could be made for a specific one if that's
> easier to implement. I would very much appreciate if someone could point
> me to the code that I need to modify to implement these changes. Also,
> knowing what part of the code actually performs accesses to the cache
> would be very useful.
>
> Thanks a lot for the tips in advance.
>
> -Gene
> _______________________________________________
> Gems-users mailing list
> Gems-users@xxxxxxxxxxx
> https://lists.cs.wisc.edu/mailman/listinfo/gems-users
>
[← Prev in Thread] Current Thread [Next in Thread→]