Branch Coverage

deps/libgit2/src/xdiff/xhistogram.c
Criterion Covered Total %
branch 0 98 0.0


line true false branch
117 0 0 for (ptr = LINE_END(1); line1 <= ptr; ptr--) {
123 0 0 while (rec) {
124 0 0 if (CMP(index, 1, rec->ptr, 1, ptr)) {
142 0 0 if (chain_len == index->max_chain_length)
149 0 0 if (!(rec = xdl_cha_alloc(&index->rcha)))
174 0 0 for (; rec; rec = rec->next) {
175 0 0 if (rec->cnt > index->cnt) {
176 0 0 if (!index->has_common)
182 0 0 if (!CMP(index, 1, as, 2, b_ptr))
194 0 0 while (line1 < as && line2 < bs
0 0 while (line1 < as && line2 < bs
195 0 0 && CMP(index, 1, as - 1, 2, bs - 1)) {
198 0 0 if (1 < rc)
201 0 0 while (ae < LINE_END(1) && be < LINE_END(2)
0 0 while (ae < LINE_END(1) && be < LINE_END(2)
202 0 0 && CMP(index, 1, ae + 1, 2, be + 1)) {
205 0 0 if (1 < rc)
209 0 0 if (b_next <= be)
211 0 0 if (lcs->end1 - lcs->begin1 < ae - as || rc < index->cnt) {
0 0 if (lcs->end1 - lcs->begin1 < ae - as || rc < index->cnt) {
219 0 0 if (np == 0)
222 0 0 while (np <= ae) {
224 0 0 if (np == 0) {
230 0 0 if (should_break)
246 0 0 if (scanA(index, line1, count1))
251 0 0 for (b_ptr = line2; b_ptr <= LINE_END(2); )
254 0 0 return index->has_common && index->max_chain_length < index->cnt;
0 0 return index->has_common && index->max_chain_length < index->cnt;
277 0 0 if (count1 <= 0 && count2 <= 0)
0 0 if (count1 <= 0 && count2 <= 0)
280 0 0 if (LINE_END(1) >= MAX_PTR)
283 0 0 if (!count1) {
284 0 0 while(count2--)
287 0 0 } else if (!count2) {
288 0 0 while(count1--)
305 0 0 GIT_ERROR_CHECK_ALLOC_MULTIPLY(&sz, sz, sizeof(struct record *));
0 0 GIT_ERROR_CHECK_ALLOC_MULTIPLY(&sz, sz, sizeof(struct record *));
307 0 0 if (!(index.records = (struct record **) xdl_malloc(sz)))
313 0 0 if (!(index.line_map = (struct record **) xdl_malloc(sz)))
319 0 0 if (!(index.next_ptrs = (unsigned int *) xdl_malloc(sz)))
324 0 0 if (xdl_cha_init(&index.rcha, sizeof(struct record), count1 / 4 + 1) < 0)
331 0 0 if (find_lcs(&index, &lcs, line1, count1, line2, count2))
334 0 0 if (lcs.begin1 == 0 && lcs.begin2 == 0) {
0 0 if (lcs.begin1 == 0 && lcs.begin2 == 0) {
335 0 0 while (count1--)
337 0 0 while (count2--)
344 0 0 if (result)
349 0 0 if (result)
366 0 0 if (xdl_prepare_env(file1, file2, xpp, env) < 0)