|
From: Stephen K. <he...@st...> - 2015-02-01 12:45:13
|
Hello, I'm looking for a way to answer the question 'how much of a cache line did I use before discarding it?'. I wrote this simple file https://gist.github.com/steveire/7c3cfb0494b4708b68fe and ran the following commands: g++ matrix.cpp -O0 -g valgrind --tool=callgrind --cacheuse=yes --instr-atstart=no ./a.out The output shows a large value for AcCost1 because of the padding in the Data struct, but kcachegrind doesn't point me to the loop as the cause of loading that struct and using so little of it. Is there something I'm missing here? Is the workflow of making use of the option --cacheuse=yes different than I assume? Thanks, Steve. |