Optimize tracking of peak costs
authorMilian Wolff <milian.wolff@kdab.com>
Tue, 23 May 2017 14:08:19 +0000 (16:08 +0200)
committerMilian Wolff <milian.wolff@kdab.com>
Tue, 23 May 2017 14:12:57 +0000 (16:12 +0200)
commit9054e99e199459f8ff7ba7bbc48006983bbc8e28
treebce2e5868c2c640696d11077296b291801904954
parent18de9c5385903713f3e1a18b8a4b93cc2b833c23
Optimize tracking of peak costs

Use a separate container for the potentially frequent write
operations when updating the peak memory consumption of all
allocation locations. This allows us to only update what is
actually required and thus makes better use of our CPU caches.

In one of my example files, this decreases the processing time
from about 2.2s down to 1.8s, i.e. it's about 22% faster. But,
compared to the original approach with the different "peak"
heuristic, which took ~1.2s, we are still about 33% slower.
src/analyze/accumulatedtracedata.cpp
src/analyze/accumulatedtracedata.h