MCPcopy Index your code
hub / github.com/git/git / test_bitmap_pseudo_merges

Function test_bitmap_pseudo_merges

pack-bitmap.c:2973–3001  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2971}
2972
2973int test_bitmap_pseudo_merges(struct repository *r)
2974{
2975 struct bitmap_index *bitmap_git;
2976 uint32_t i;
2977
2978 bitmap_git = prepare_bitmap_git(r);
2979 if (!bitmap_git || !bitmap_git->pseudo_merges.nr)
2980 goto cleanup;
2981
2982 for (i = 0; i < bitmap_git->pseudo_merges.nr; i++) {
2983 struct pseudo_merge *merge;
2984 struct ewah_bitmap *commits_bitmap, *merge_bitmap;
2985
2986 merge = use_pseudo_merge(&bitmap_git->pseudo_merges,
2987 &bitmap_git->pseudo_merges.v[i]);
2988 commits_bitmap = merge->commits;
2989 merge_bitmap = pseudo_merge_bitmap(&bitmap_git->pseudo_merges,
2990 merge);
2991
2992 printf("at=%"PRIuMAX", commits=%"PRIuMAX", objects=%"PRIuMAX"\n",
2993 (uintmax_t)merge->at,
2994 (uintmax_t)ewah_bitmap_popcount(commits_bitmap),
2995 (uintmax_t)ewah_bitmap_popcount(merge_bitmap));
2996 }
2997
2998cleanup:
2999 free_bitmap_index(bitmap_git);
3000 return 0;
3001}
3002
3003static void dump_ewah_object_ids(struct bitmap_index *bitmap_git,
3004 struct ewah_bitmap *bitmap)

Callers 1

Calls 5

prepare_bitmap_gitFunction · 0.85
use_pseudo_mergeFunction · 0.85
pseudo_merge_bitmapFunction · 0.85
ewah_bitmap_popcountFunction · 0.85
free_bitmap_indexFunction · 0.85

Tested by

no test coverage detected