mem-ruby: Fix MultiGrainBloomFilter total count calculation
authorDaniel R. Carvalho <odanrc@yahoo.com.br>
Wed, 8 May 2019 20:21:06 +0000 (22:21 +0200)
committerDaniel Carvalho <odanrc@yahoo.com.br>
Sat, 6 Jul 2019 22:55:32 +0000 (22:55 +0000)
Previous value was always 0, and was never incrementing. The
total count should take into account the value stored in the
entry.

Change-Id: I93813e3f388198967b30cf11848a8a8c3a7b91f4
Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/18733
Maintainer: Nikos Nikoleris <nikos.nikoleris@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
src/mem/ruby/filters/MultiGrainBloomFilter.cc

index 29af6eb1b828defcf6381599b876869e2ad771d1..a1f8993c901eb810cbdb8c60b56b16cfb8d7c81b 100644 (file)
@@ -105,7 +105,7 @@ MultiGrainBloomFilter::getTotalCount()
     }
 
     for (int i=0; i < m_page_filter_size; ++i) {
-        count += m_page_filter[i] = 0;
+        count += m_page_filter[i];
     }
 
     return count;