Lines Matching refs:heap_len
461 int heap_len; /* number of elements in the heap */
2197 * one less element. Updates heap and heap_len.
2202 s->heap[SMALLEST] = s->heap[s->heap_len--]; \
2227 while (j <= s->heap_len) {
2229 if (j < s->heap_len &&
2399 s->heap_len = 0, s->heap_max = HEAP_SIZE;
2403 s->heap[++(s->heap_len)] = max_code = n;
2415 while (s->heap_len < 2) {
2416 node = s->heap[++(s->heap_len)] = (max_code < 2 ? ++max_code : 0);
2424 /* The elements heap[heap_len/2+1 .. heap_len] are leaves of the tree,
2427 for (n = s->heap_len/2; n >= 1; n--) pqdownheap(s, tree, n);
2454 } while (s->heap_len >= 2);