Skip to content

Commit 526c514

Browse files
committed
genhtml: Reduce load times for complex coverage data files
genhtml uses a significant amount of time loading coverage data files containing complex branch coverage data (i.e. data with a large number of branches per basic block). Most of this time is spent storing branch coverage data in a vector-based data representation, with an unnecessary amount of cross-checking being done for existing branch data. Fix this by replacing the vector based data representation by two separate representations, scalar for storage and hash for processing, and by moving cross-checking out of the hot path. This results in a significant speedup at the cost of a minor increase in memory usage. Test results for "make -C genhtml_output/ SIZE=large": Original: 6 tests executed, 6 passed, 0 failed, 0 skipped (time 768.4s, mem 893.8MB) Patched: 6 tests executed, 6 passed, 0 failed, 0 skipped (time 202.3s, mem 908.10MB) Signed-off-by: Peter Oberparleiter <[email protected]>
1 parent 0f07133 commit 526c514

File tree

1 file changed

+122
-257
lines changed

1 file changed

+122
-257
lines changed

0 commit comments

Comments
 (0)