Merge branch 'ds/bitmap-lookup-remove-tracing'
Perf-fix. * ds/bitmap-lookup-remove-tracing: pack-bitmap: remove trace2 region from hot path
This commit is contained in:
commit
2a7d63a245
@ -830,10 +830,9 @@ struct ewah_bitmap *bitmap_for_commit(struct bitmap_index *bitmap_git,
|
|||||||
if (!bitmap_git->table_lookup)
|
if (!bitmap_git->table_lookup)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
trace2_region_enter("pack-bitmap", "reading_lookup_table", the_repository);
|
/* this is a fairly hot codepath - no trace2_region please */
|
||||||
/* NEEDSWORK: cache misses aren't recorded */
|
/* NEEDSWORK: cache misses aren't recorded */
|
||||||
bitmap = lazy_bitmap_for_commit(bitmap_git, commit);
|
bitmap = lazy_bitmap_for_commit(bitmap_git, commit);
|
||||||
trace2_region_leave("pack-bitmap", "reading_lookup_table", the_repository);
|
|
||||||
if (!bitmap)
|
if (!bitmap)
|
||||||
return NULL;
|
return NULL;
|
||||||
return lookup_stored_bitmap(bitmap);
|
return lookup_stored_bitmap(bitmap);
|
||||||
|
@ -455,13 +455,6 @@ test_expect_success 'verify writing bitmap lookup table when enabled' '
|
|||||||
grep "\"label\":\"writing_lookup_table\"" trace2
|
grep "\"label\":\"writing_lookup_table\"" trace2
|
||||||
'
|
'
|
||||||
|
|
||||||
test_expect_success 'lookup table is actually used to traverse objects' '
|
|
||||||
git repack -adb &&
|
|
||||||
GIT_TRACE2_EVENT="$(pwd)/trace3" \
|
|
||||||
git rev-list --use-bitmap-index --count --all &&
|
|
||||||
grep "\"label\":\"reading_lookup_table\"" trace3
|
|
||||||
'
|
|
||||||
|
|
||||||
test_expect_success 'truncated bitmap fails gracefully (lookup table)' '
|
test_expect_success 'truncated bitmap fails gracefully (lookup table)' '
|
||||||
test_config pack.writebitmaphashcache false &&
|
test_config pack.writebitmaphashcache false &&
|
||||||
git repack -adb &&
|
git repack -adb &&
|
||||||
|
Loading…
Reference in New Issue
Block a user