Lines Matching refs:dist

409 local int  ct_tally      OF((deflate_state *s, int dist, int lc));
1599 #define d_code(dist) \ argument
1600 ((dist) < 256 ? dist_code[dist] : dist_code[256+((dist)>>7)])
1676 int dist; /* distance index */ in ct_static_init() local
1696 dist = 0; in ct_static_init()
1698 base_dist[code] = dist; in ct_static_init()
1700 dist_code[dist++] = (uch)code; in ct_static_init()
1703 Assert (dist == 256, "ct_static_init: dist != 256"); in ct_static_init()
1704 dist >>= 7; /* from now on, all distances are divided by 128 */ in ct_static_init()
1706 base_dist[code] = dist << 7; in ct_static_init()
1708 dist_code[256 + dist++] = (uch)code; in ct_static_init()
1711 Assert (dist == 256, "ct_static_init: 256+dist != 512"); in ct_static_init()
2403 local int ct_tally (s, dist, lc) in ct_tally() argument
2405 int dist; /* distance of matched string */
2408 s->d_buf[s->last_lit] = (ush)dist;
2410 if (dist == 0) {
2416 dist--; /* dist = match distance - 1 */
2417 Assert((ush)dist < (ush)MAX_DIST(s) &&
2419 (ush)d_code(dist) < (ush)D_CODES, "ct_tally: bad match");
2422 s->dyn_dtree[d_code(dist)].Freq++;
2456 unsigned dist; /* distance of matched string */ local
2463 dist = s->d_buf[lx];
2465 if (dist == 0) {
2477 dist--; /* dist is now the match distance - 1 */
2478 code = d_code(dist);
2484 dist -= base_dist[code];
2485 send_bits(s, dist, extra); /* send the extra distance bits */
4109 uInt dist; /* distance back to copy from */ member
4239 c->sub.copy.dist = t->base;
4256 c->sub.copy.dist += (uInt)b & inflate_mask[j];
4258 Tracevv((stderr, "inflate: distance %u\n", c->sub.copy.dist));
4262 f = (uInt)(q - s->window) < c->sub.copy.dist ?
4263 s->end - (c->sub.copy.dist - (q - s->window)) :
4264 q - c->sub.copy.dist;
4266 f = q - c->sub.copy.dist;
4267 if ((uInt)(q - s->window) < c->sub.copy.dist)
4268 f = s->end - (c->sub.copy.dist - (q - s->window));