Lines Matching refs:copy

27  * - Unroll direct copy to three copies per loop in inffast.c
44 * - Make MATCH copy in inflate() much faster for when inflate_fast() not used
53 * - Unroll last copy for window match in inflate_fast()
335 unsigned copy, dist;
354 /* copy state->wsize or less output bytes into the circular window */
355 copy = out - strm->avail_out;
356 if (copy >= state->wsize) {
363 if (dist > copy) dist = copy;
364 zmemcpy(state->window + state->write, strm->next_out - copy, dist);
365 copy -= dist;
366 if (copy) {
367 zmemcpy(state->window, strm->next_out - copy, copy);
368 state->write = copy;
547 and there is no window currently, goto inf_leave will create one and copy
572 unsigned copy; /* number of stored or match bytes to copy */
573 unsigned char FAR *from; /* where to copy match bytes from */
576 unsigned len; /* length to copy for repeats, bits to drop */
693 copy = state->length;
694 if (copy > have) copy = have;
695 if (copy) {
700 len + copy > state->head->extra_max ?
701 state->head->extra_max - len : copy);
704 state->check = crc32(state->check, next, copy);
705 have -= copy;
706 next += copy;
707 state->length -= copy;
717 copy = 0;
719 len = (unsigned)(next[copy++]);
724 } while (len && copy < have);
726 state->check = crc32(state->check, next, copy);
727 have -= copy;
728 next += copy;
739 copy = 0;
741 len = (unsigned)(next[copy++]);
746 } while (len && copy < have);
748 state->check = crc32(state->check, next, copy);
749 have -= copy;
750 next += copy;
839 copy = state->length;
840 if (copy) {
841 if (copy > have) copy = have;
842 if (copy > left) copy = left;
843 if (copy == 0) goto inf_leave;
844 zmemcpy(put, next, copy);
845 have -= copy;
846 next += copy;
847 left -= copy;
848 put += copy;
849 state->length -= copy;
918 copy = 3 + BITS(2);
925 copy = 3 + BITS(3);
932 copy = 11 + BITS(7);
935 if (state->have + copy > state->nlen + state->ndist) {
940 while (copy--)
1073 copy = out - left;
1074 if (state->offset > copy) { /* copy from window */
1075 copy = state->offset - copy;
1076 if (copy > state->write) {
1077 copy -= state->write;
1078 from = state->window + (state->wsize - copy);
1081 from = state->window + (state->write - copy);
1082 if (copy > state->length) copy = state->length;
1084 else { /* copy from output */
1086 copy = state->length;
1088 if (copy > left) copy = left;
1089 left -= copy;
1090 state->length -= copy;
1093 } while (--copy);
1218 /* copy dictionary to window */
1355 struct inflate_state FAR *copy;
1366 copy = (struct inflate_state FAR *)
1368 if (copy == Z_NULL) return Z_MEM_ERROR;
1374 ZFREE(source, copy);
1379 /* copy state */
1381 zmemcpy(copy, state, sizeof(struct inflate_state));
1384 copy->lencode = copy->codes + (state->lencode - state->codes);
1385 copy->distcode = copy->codes + (state->distcode - state->codes);
1387 copy->next = copy->codes + (state->next - state->codes);
1392 copy->window = window;
1393 dest->state = (struct internal_state FAR *)copy;