diff --git a/inc/Performance.h b/inc/Performance.h index a9daf2c..5e5ef56 100644 --- a/inc/Performance.h +++ b/inc/Performance.h @@ -90,13 +90,13 @@ private: static Performance* instance; Performance(); - uint64_t data_memory_read = 0; - uint64_t data_memory_write = 0; - uint64_t code_memory_read = 0; - uint64_t code_memory_write = 0; - uint64_t register_read = 0; - uint64_t register_write = 0; - uint64_t instructions_executed = 0; + uint64_t data_memory_read; + uint64_t data_memory_write; + uint64_t code_memory_read; + uint64_t code_memory_write; + uint64_t register_read; + uint64_t register_write; + uint64_t instructions_executed; }; #endif diff --git a/src/Performance.cpp b/src/Performance.cpp index 122e48c..6259af9 100644 --- a/src/Performance.cpp +++ b/src/Performance.cpp @@ -11,7 +11,15 @@ Performance* Performance::getInstance() } Performance::Performance() -{} +{ + data_memory_read = 0; + data_memory_write = 0; + code_memory_read = 0; + code_memory_write = 0; + register_read = 0; + register_write = 0; + instructions_executed = 0; +} void Performance::dump() { cout << dec << "# data memory reads: " << data_memory_read << endl;