Lines Matching refs:max

15                      Fix bug for initial root table size == max - 1
127 len: 1..max - 1 (max == maximum code length in bits)
134 len is less than max, since the code completes immediately when len == max.
138 We build the array with length max-1 lists for the len index, with syms-3
170 local int max; /* maximum allowed bit length for the codes */
179 #define INDEX(i,j,k) (((size_t)((i-1)>>1)*((i-2)>>1)+(j>>1)-1)*(max-1)+k-1)
199 len through max inclusive, coding syms symbols, with left bit patterns of
202 calculation. Uses the globals max and num. */
217 assert(syms > left && left > 0 && len < max);
234 most = (((code_t)left << (max - len)) - syms) /
235 (((code_t)1 << (max - len)) - 1);
320 the current sub-table is rem. Uses the globals max, code, root, large, and
344 printf("max %d: ", mem);
345 for (use = root + 1; use <= max; use++)
370 most = (((code_t)left << (max - len)) - syms) /
371 (((code_t)1 << (max - len)) - 1);
402 requires that maximum. Uses the globals max, root, and num. */
410 for (n = 0; n <= max; n++)
415 if (root < max) /* otherwise, there's only a base table */
422 if (root + 1 < max && num[index]) /* reachable node */
474 max = 15;
480 max = atoi(argv[3]);
483 if (argc > 4 || syms < 2 || root < 1 || max < 1) {
484 fputs("invalid arguments, need: [sym >= 2 [root >= 1 [max >= 1]]]\n",
490 if (max > syms - 1)
491 max = syms - 1;
498 if (max > n || (code_t)(syms - 2) >= (((code_t)0 - 1) >> (max - 1))) {
504 if ((code_t)(syms - 1) > ((code_t)1 << max) - 1) {
506 syms, max);
511 code = calloc(max + 1, sizeof(int));
519 if (syms == 2) /* iff max == 1 */
524 (size *= n, size > ((size_t)0 - 1) / (n = max - 1)) ||
546 if (max < syms - 1)
547 printf(" (%d-bit length limit)\n", max);
562 if (root > max) /* reduce root to max length */
563 root = max;