ruby: call setMRU from L1 controllers, not from sequencer
Review Request #2957 - Created July 10, 2015 and submitted
| Information | |
|---|---|
| Nilay Vaish | |
| gem5 | |
| default | |
| Reviewers | |
| Default | |
Changeset 10937:3724230bfee5 --------------------------- ruby: call setMRU from L1 controllers, not from sequencer Currently the sequencer calls the function setMRU that updates the replacement policy structures with the first level caches. While functionally this is correct, the problem is that this requires calling findTagInSet() which is an expensive function. This patch removes the calls to setMRU from the sequencer. All controllers should now update the replacement policy on their own. The set and the way index for a given cache entry can be found within the AbstractCacheEntry structure. Use these indicies to update the replacement policy structures.
Issue Summary
| Description | From | Last Updated | Status |
|---|---|---|---|
| Is it necessary to update the replacement policy through an additional action like this? This seems pretty fragile if a ... | Joel Hestness | July 13, 2015, 1:16 p.m. | Open |
Overall, I really like the direction of this patch, since replacement policy should be handled modularly by the cache controllers rather than the Sequencer.
I wonder if it would be possible to limit the number of ways that MRU can be updated. Currently, this patch uses (1) lookup() and setMRU() in actions, and (2) some specific new actions that just call setMRU(). Previously, setMRU was called from a single place in the Sequencer, so there wasn't any worry of overlooking a place where replacement policy needed to be updated. Now, it's a little more complicated and there aren't any safeguards ensuring that one remembers to update MRU.
-
src/mem/protocol/MESI_Three_Level-L0cache.sm (Diff revision 1) -
Minor: Convention in other SLICC controller functions is to name function arguments using lower_underscore rather than lowerCamelCase.
-
src/mem/protocol/MESI_Three_Level-L0cache.sm (Diff revision 1) -
Is it necessary to update the replacement policy through an additional action like this? This seems pretty fragile if a user forgets to include this in transitions analogous to this one. It would also be nice to have a single process for updating replacement policy.
-
src/mem/protocol/RubySlicc_Types.sm (Diff revision 1) -
Minor: Could you use the default parameter specifier here so you could avoid passing static 'false' in a few cases?
Description: |
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Diff: |
Revision 2 (+154 -8) |
Description: |
|
|||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Diff: |
Revision 4 (+154 -8)
|
Description: |
|
|||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Diff: |
Revision 5 (+154 -8)
|
This might be a silly question but I was wondering:
Some of the protocols have getCacheEntry without a way to pass whether to setMRU or not; they default to false. What is the reason for these automatically being false? Since the sequencer cannot set the recently used status, how do these caches update their entry information?
