Welcome to gem5 Q&A, where you can ask questions and receive answers from other members of the community.

Count number of writes in L2 cache

0 votes
Dear All,

               I want to calculate number of writes in L2 cache. I think from gem5 stats file, i need to sum number of write-backs from L1 cache and Number of misses in L2 cache(Because, that cause data to be written from memory in L2 cache).

To count write-backs, I am confused between two parameters (write-back accesses and write-backs)

To count number of misses in L2 cache, can i use overall_misses from gem5 stats file.

Can anyone suggest something

Many Thanks
asked Apr 6 in Classic Memory by sarah (450 points)

1 Answer

0 votes
I think it's WritebackDirty_hits::total + WritebackClean_hits::total + overall_misses::total. But you can read the code and make sure that these stats aren't missing anything.
answered Apr 6 by powerjg (6,280 points)
Thanks for your help. But, i could not find "WritebackClean_hits::total" and "WritebackDirty_hits::total" in stats file. I am using gem5 2015 stable version.
Also, clean data is not written back to l2 cache. Do, i need to consider "WritebackClean_hits::total"
You're using a *very* old version of gem5. Update to the latest version at https://gem5.googlesource.com/
...