Open mat-kalinowski opened 3 years ago
Thanks for filing the issue. For the configuration generated in cache_simulator_t(const cache_simulator_knobs_t &knobs)
, I think it makes sense to include L1I and L1D caches as children of the LLC. Can you also create a pull request for this?
Sure, I will implement the fix and create pull request.
Describe the bug In the default programmatic configuration using constructor
cache_simulator_t(const cache_simulator_knobs_t &knobs)
LL cache is created with emptychildren_
vector.init
function with the default value for thechildren_
vector is used:Probably it should contain L1i and L1d cache in this vector. With the same cache hierarchy configured through the file (using constructor
cache_simulator_t(std::istream *config_file)
) corresponding cache is created with proper values in thechildren_
vector.Because of this behavior invalidates are probably not counted properly in the default configuration. There is a lot of code like this in the
caching_device_t
class:To Reproduce
Run drcachesim in the default configuration without configuration file. Invalidates in L1d and L1i are always zero in the results:
The same app tested with the same cache hierarchy in the configuration file gives non-zero invalidates number in L1d and L1i.
Expected behavior I think LL cache in the default configuration should contain L1i and L1d cache in the children vector. Constructor
cache_simulator_t(const cache_simulator_knobs_t &knobs)
should invokecaching_device_t::init
with proper value provided for LL cache instead of using default value.Versions I was checking latest code from the master branch.