MCPcopy Create free account
hub / github.com/git/git / write_graph_chunk_bloom_indexes

Function write_graph_chunk_bloom_indexes

commit-graph.c:1451–1469  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1449}
1450
1451static int write_graph_chunk_bloom_indexes(struct hashfile *f,
1452 void *data)
1453{
1454 struct write_commit_graph_context *ctx = data;
1455 struct commit **list = ctx->commits.items;
1456 struct commit **last = ctx->commits.items + ctx->commits.nr;
1457 uint32_t cur_pos = 0;
1458
1459 while (list < last) {
1460 struct bloom_filter *filter = get_bloom_filter(ctx->r, *list);
1461 size_t len = filter ? filter->len : 0;
1462 cur_pos += len;
1463 display_progress(ctx->progress, ++ctx->progress_cnt);
1464 hashwrite_be32(f, cur_pos);
1465 list++;
1466 }
1467
1468 return 0;
1469}
1470
1471static void trace2_bloom_filter_settings(struct write_commit_graph_context *ctx)
1472{

Callers

nothing calls this directly

Calls 3

get_bloom_filterFunction · 0.85
display_progressFunction · 0.85
hashwrite_be32Function · 0.85

Tested by

no test coverage detected