1 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
2 ; Copyright(c) 2011-2016 Intel Corporation All rights reserved.
4 ; Redistribution and use in source and binary forms, with or without
5 ; modification, are permitted provided that the following conditions
7 ; * Redistributions of source code must retain the above copyright
8 ; notice, this list of conditions and the following disclaimer.
9 ; * Redistributions in binary form must reproduce the above copyright
10 ; notice, this list of conditions and the following disclaimer in
11 ; the documentation and/or other materials provided with the
13 ; * Neither the name of Intel Corporation nor the names of its
14 ; contributors may be used to endorse or promote products derived
15 ; from this software without specific prior written permission.
17 ; THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
18 ; "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
19 ; LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
20 ; A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
21 ; OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
22 ; SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
23 ; LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
24 ; DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
25 ; THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26 ; (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
27 ; OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
29 %include "options.asm"
31 %include "lz0a_const.asm"
32 %include "data_struct2.asm"
33 %include "bitbuf2.asm"
34 %include "huffman.asm"
35 %include "igzip_compare_types.asm"
36 %include "reg_sizes.asm"
49 %define LARGE_MATCH_HASH_REP 1 ; Hash 4 * LARGE_MATCH_HASH_REP elements
50 %define LARGE_MATCH_MIN 264 ; Minimum match size to enter large match emit loop
51 %define MIN_INBUF_PADDING 16
52 %define MAX_EMIT_SIZE 258 * 16
54 %define SKIP_SIZE_BASE (2 << 10) ; No match length before starting skipping
55 %define SKIP_BASE 32 ; Initial skip size
56 %define SKIP_START 512 ; Start increasing skip size once level is beyond SKIP_START
57 %define SKIP_RATE 2 ; Rate skip size increases after SKIP_START
58 %define MAX_SKIP_SIZE 128 ; Maximum skip size
59 %define MAX_SKIP_LEVEL (((MAX_SKIP_SIZE - SKIP_BASE) / SKIP_RATE) + SKIP_START) ; Maximum skip level
60 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
61 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
62 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
63 %define file_start rdi
64 %define file_length r15
72 %define skip_count rcx
75 %define dist_code2 rbx
102 ;; GPR r8 & r15 can be used
104 %define xtmp0 xmm0 ; tmp
105 %define xtmp1 xmm1 ; tmp
106 %define xlow_lit_shuf xmm2
107 %define xup_lit_shuf xmm3
111 %define ytmp0 ymm0 ; tmp
112 %define ytmp1 ymm1 ; tmp
114 %define hash_table level_buf + _hash8k_hash_table
115 %define lit_len_hist level_buf + _hist_lit_len
116 %define dist_hist level_buf + _hist_dist
118 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
119 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
120 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
122 m_out_end equ 0 ; local variable (8 bytes)
124 dist_mask_offset equ 16
125 hash_mask_offset equ 24
126 f_end_i_mem_offset equ 32
128 inbuf_slop_offset equ 48
129 skip_match_offset equ 56
130 skip_level_offset equ 64
131 gpr_save_mem_offset equ 80 ; gpr save area (8*8 bytes)
132 xmm_save_mem_offset equ gpr_save_mem_offset + 8*8 ; xmm save area (4*16 bytes) (16 byte aligned)
133 stack_size equ 11*8 + 8*8 + 4*16
135 ;;; 8 because stack address is odd multiple of 8 after a function call and
136 ;;; we want it aligned to 16 bytes
138 ;; Defines to generate functions for different architecture
144 %xdefine COMPARE_TYPE_NOT_DEF
145 %xdefine COMPARE_TYPE 1
146 %xdefine COMPARE_TYPE1 2
147 %xdefine COMPARE_TYPE2 3
150 ;; Defines to generate functions for different levels
151 %xdefine METHOD hash_hist
158 ; void isal_deflate_icf_body <hashsize> <arch> ( isal_zstream *stream )
159 ; we make 6 different versions of this function
160 ; arg 1: rcx: addr of stream
161 global isal_deflate_icf_body_ %+ METHOD %+ _ %+ ARCH
162 isal_deflate_icf_body_ %+ METHOD %+ _ %+ ARCH %+ :
163 %ifidn __OUTPUT_FORMAT__, elf64
167 ;; do nothing if (avail_in == 0)
168 cmp dword [rcx + _avail_in], 0
171 ;; Set stream's next state
172 mov rdx, ZSTATE_CREATE_HDR
173 mov eax, [rcx + _internal_state_state]
174 cmp word [rcx + _end_of_stream], 0
176 cmp word [rcx + _flush], _NO_FLUSH
178 mov dword [rcx + _internal_state_state], eax
191 mov [rsp + gpr_save_mem_offset + 0*8], rbx
192 mov [rsp + gpr_save_mem_offset + 1*8], rsi
193 mov [rsp + gpr_save_mem_offset + 2*8], rdi
194 mov [rsp + gpr_save_mem_offset + 3*8], rbp
195 mov [rsp + gpr_save_mem_offset + 4*8], r12
196 mov [rsp + gpr_save_mem_offset + 5*8], r13
197 mov [rsp + gpr_save_mem_offset + 6*8], r14
198 mov [rsp + gpr_save_mem_offset + 7*8], r15
201 mov [rsp + stream_offset], stream
203 mov byte [stream + _internal_state_has_eob], 0
205 mov tmp1 %+ d, dword[stream + _internal_state_dist_mask]
206 mov [rsp + dist_mask_offset], tmp1
207 mov tmp1 %+ d, dword[stream + _internal_state_hash_mask]
208 mov [rsp + hash_mask_offset], tmp1
210 ; state->bitbuf.set_buf(stream->next_out, stream->avail_out);
211 mov level_buf, [stream + _level_buf]
212 mov m_out_buf, [level_buf + _icf_buf_next]
214 mov [rsp + m_out_start], m_out_buf
215 mov tmp1, [level_buf + _icf_buf_avail_out]
219 mov [rsp + m_out_end], tmp1
221 mov file_start, [stream + _next_in]
223 mov f_i %+ d, dword [stream + _total_in]
226 mov file_length %+ d, [stream + _avail_in]
229 mov [rsp + skip_match_offset], f_i
230 add qword [rsp + skip_match_offset], SKIP_SIZE_BASE
231 mov qword [rsp + skip_level_offset], 0
233 PBROADCASTD xlit, dword [min_lit_dist_syms]
234 MOVDQU xlow_lit_shuf, [low_lit_shuf]
235 MOVDQU xup_lit_shuf, [up_lit_shuf]
237 mov qword [rsp + inbuf_slop_offset], MIN_INBUF_PADDING
238 cmp byte [stream + _end_of_stream], 0
239 jnz .default_inbuf_padding
240 cmp byte [stream + _flush], 0
241 jnz .default_inbuf_padding
242 mov qword [rsp + inbuf_slop_offset], LA
243 .default_inbuf_padding:
245 ; file_length -= INBUF_PADDING;
246 sub file_length, [rsp + inbuf_slop_offset]
247 ; if (file_length <= 0) continue;
248 mov hmask1 %+ d, [rsp + hash_mask_offset]
253 ; for (f_i = f_start_i; f_i < file_length; f_i++) {
254 MOVDQU xdata, [file_start + f_i]
255 mov curr_data, [file_start + f_i]
258 compute_hash hash, curr_data
261 compute_hash hash2, tmp1
266 cmp byte [stream + _internal_state_has_hist], IGZIP_NO_HIST
273 mov tmp3 %+ d, [rsp + dist_mask_offset]
274 mov hmask1 %+ d, [rsp + hash_mask_offset]
275 ; if (state->bitbuf.is_full()) {
276 cmp m_out_buf, [rsp + m_out_end]
282 lea tmp1, [file_start + f_i]
284 mov dist %+ w, f_i %+ w
286 sub dist %+ w, word [hash_table + 2 * hash]
287 mov [hash_table + 2 * hash], f_i %+ w
293 compute_hash hash, curr_data
294 and hash %+ d, hmask1 %+ d
296 mov dist2 %+ w, f_i %+ w
298 sub dist2 %+ w, word [hash_table + 2 * hash2]
299 mov [hash_table + 2 * hash2], f_i %+ w
301 ; if ((dist-1) < (D-1)) {
302 and dist %+ d, tmp3 %+ d
306 compute_hash hash2, tmp2
307 and hash2 %+ d, hmask1 %+ d
309 and dist2 %+ d, tmp3 %+ d
312 ;; Check for long len/dist match (>7) with first literal
316 xor len, [tmp1 + dist - 1]
319 ;; Check for len/dist match (>7) with second literal
321 xor len2, [tmp1 + dist2]
324 movzx lit_code, curr_data %+ b
327 ;; Check for len/dist match for first literal
328 test len %+ d, 0xFFFFFFFF
329 jz .len_dist_huffman_pre
332 inc dword [lit_len_hist + HIST_ELEM_SIZE*lit_code]
333 movzx lit_code2, curr_data %+ b
334 ;; Check for len/dist match for second literal
335 test len2 %+ d, 0xFFFFFFFF
338 .len_dist_lit_huffman_pre:
342 .len_dist_lit_huffman:
344 mov dword [m_out_buf], lit_code %+ d
348 get_dist_icf_code dist2, dist_code2, tmp1
350 mov hmask3 %+ d, dword [rsp + hash_mask_offset]
352 ;; Setup for updating hash
353 lea tmp3, [f_i + 1] ; tmp3 <= k
359 jg .len_dist_lit_huffman_finish
361 lea tmp1, [f_i + SKIP_SIZE_BASE]
362 mov qword [rsp + skip_match_offset], tmp1
363 sub qword [rsp + skip_level_offset], len2
365 MOVDQU xdata, [file_start + len2]
366 mov tmp1, [file_start + len2]
370 compute_hash hash3, curr_data
371 and hash3 %+ d, hmask3 %+ d
376 mov [hash_table + 2 * hash], tmp3 %+ w
378 compute_hash hash, curr_data
381 mov [hash_table + 2 * hash2], tmp3 %+ w
383 compute_hash hash2, tmp1
386 mov [hash_table + 2 * hash3], tmp3 %+ w
391 inc dword [lit_len_hist + HIST_ELEM_SIZE*(len2 + 254)]
393 mov dword [m_out_buf + 4], dist_code2 %+ d
396 shr dist_code2, DIST_OFFSET
398 inc dword [dist_hist + HIST_ELEM_SIZE*dist_code2]
400 ; hash = compute_hash(state->file_start + f_i) & hash_mask;
401 and hash %+ d, hmask3 %+ d
402 and hash2 %+ d, hmask3 %+ d
407 .len_dist_lit_huffman_finish:
410 mov [hash_table + 2 * hash], tmp3 %+ w
412 mov [hash_table + 2 * hash2], tmp3 %+ w
417 inc dword [lit_len_hist + HIST_ELEM_SIZE*(len2 + 254)]
419 mov dword [m_out_buf + 4], dist_code2 %+ d
422 shr dist_code2, DIST_OFFSET
424 inc dword [dist_hist + HIST_ELEM_SIZE*dist_code2]
428 .len_dist_huffman_pre:
434 ;; Setup for updateing hash
435 lea tmp3, [f_i + 2] ; tmp3 <= k
439 ; get_dist_code(dist, &code2, &code_len2);
440 get_dist_icf_code dist, dist_code, tmp1
442 .len_dist_huffman_skip:
444 mov hmask2 %+ d, [rsp + hash_mask_offset]
451 jg .len_dist_huffman_finish
453 lea tmp2, [f_i + SKIP_SIZE_BASE]
454 mov qword [rsp + skip_match_offset], tmp2
455 sub qword [rsp + skip_level_offset], len
457 MOVDQU xdata, [file_start + len]
458 mov curr_data2, [file_start + len]
459 mov curr_data, curr_data2
461 ; get_len_code(len, &code, &code_len);
462 lea len_code, [len + 254]
463 or dist_code, len_code
465 mov [hash_table + 2 * hash], tmp3 %+ w
467 mov [hash_table + 2 * hash2], tmp3 %+ w
469 compute_hash hash, curr_data
472 compute_hash hash2, curr_data2
474 inc dword [lit_len_hist + HIST_ELEM_SIZE*len_code]
476 mov dword [m_out_buf], dist_code %+ d
479 shr dist_code, DIST_OFFSET
481 inc dword [dist_hist + HIST_ELEM_SIZE*dist_code]
483 ; hash = compute_hash(state->file_start + f_i) & hash_mask;
484 and hash %+ d, hmask2 %+ d
485 and hash2 %+ d, hmask2 %+ d
490 .len_dist_huffman_finish:
493 ; get_len_code(len, &code, &code_len);
494 lea len_code, [len + 254]
495 or dist_code, len_code
497 mov [hash_table + 2 * hash], tmp3 %+ w
499 mov [hash_table + 2 * hash2], tmp3 %+ w
501 inc dword [lit_len_hist + HIST_ELEM_SIZE*len_code]
503 mov dword [m_out_buf], dist_code %+ d
506 shr dist_code, DIST_OFFSET
508 inc dword [dist_hist + HIST_ELEM_SIZE*dist_code]
513 MOVQ curr_data, xdata
517 jg .write_lit_bits_finish
519 MOVDQU xdata, [file_start + f_i]
521 inc dword [lit_len_hist + HIST_ELEM_SIZE*lit_code2]
523 shl lit_code2, DIST_OFFSET
524 lea lit_code, [lit_code + lit_code2 + (31 << DIST_OFFSET)]
526 mov dword [m_out_buf], lit_code %+ d
529 cmp f_i, [rsp + skip_match_offset]
533 mov rcx, [rsp + skip_level_offset]
536 mov tmp1, MAX_SKIP_LEVEL
537 cmp rcx, MAX_SKIP_LEVEL
540 mov tmp1, SKIP_SIZE_BASE
543 %if MAX_SKIP_LEVEL > 63
547 mov [rsp + skip_match_offset], tmp1
548 mov [rsp + skip_level_offset], rcx
553 lea skip_count, [SKIP_RATE * rcx + SKIP_BASE]
554 and skip_count, -SKIP_BASE
556 mov tmp1, [rsp + m_out_end]
561 jl .skip_forward_short
563 mov tmp1, [rsp + inbuf_slop_offset]
564 add tmp1, file_length
567 jl .skip_forward_short
570 MOVQ xdata, [file_start + f_i]
572 movzx lit_code, byte [file_start + f_i]
573 movzx lit_code2, byte [file_start + f_i + 1]
575 add dword [lit_len_hist + HIST_ELEM_SIZE*lit_code], 1
576 add dword [lit_len_hist + HIST_ELEM_SIZE*lit_code2], 1
578 movzx lit_code, byte [file_start + f_i + 2]
579 movzx lit_code2, byte [file_start + f_i + 3]
581 add dword [lit_len_hist + HIST_ELEM_SIZE*lit_code], 1
582 add dword [lit_len_hist + HIST_ELEM_SIZE*lit_code2], 1
584 movzx lit_code, byte [file_start + f_i + 4]
585 movzx lit_code2, byte [file_start + f_i + 5]
587 add dword [lit_len_hist + HIST_ELEM_SIZE*lit_code], 1
588 add dword [lit_len_hist + HIST_ELEM_SIZE*lit_code2], 1
590 movzx lit_code, byte [file_start + f_i + 6]
591 movzx lit_code2, byte [file_start + f_i + 7]
593 add dword [lit_len_hist + HIST_ELEM_SIZE*lit_code], 1
594 add dword [lit_len_hist + HIST_ELEM_SIZE*lit_code2], 1
596 PSHUFB xtmp0, xdata, xlow_lit_shuf
597 PSHUFB xtmp1, xdata, xup_lit_shuf
598 PSLLD xtmp1, xtmp1, DIST_OFFSET
599 POR xtmp0, xtmp0, xtmp1
600 PADDD xtmp0, xtmp0, xlit
601 MOVDQU [m_out_buf], xtmp0
607 jg .skip_forward_long
612 mov curr_data, [file_start + f_i]
613 MOVDQU xdata, [file_start + f_i]
614 add [rsp + skip_match_offset], f_i
619 movzx lit_code, byte [file_start + f_i]
620 movzx lit_code2, byte [file_start + f_i + 1]
622 inc dword [lit_len_hist + HIST_ELEM_SIZE*lit_code]
623 inc dword [lit_len_hist + HIST_ELEM_SIZE*lit_code2]
625 shl lit_code2, DIST_OFFSET
626 lea lit_code, [lit_code + lit_code2 + (31 << DIST_OFFSET)]
628 mov dword [m_out_buf], lit_code %+ d
632 cmp m_out_buf, [rsp + m_out_end]
638 jmp .skip_forward_short
640 .write_lit_bits_finish:
641 inc dword [lit_len_hist + HIST_ELEM_SIZE*lit_code2]
643 shl lit_code2, DIST_OFFSET
644 lea lit_code, [lit_code + lit_code2 + (31 << DIST_OFFSET)]
646 mov dword [m_out_buf], lit_code %+ d
650 mov stream, [rsp + stream_offset]
651 mov tmp1, ZSTATE_FLUSH_READ_BUFFER
652 mov tmp2, ZSTATE_BODY
653 cmp word [stream + _end_of_stream], 0
655 cmp word [stream + _flush], _NO_FLUSH
658 mov dword [stream + _internal_state_state], tmp2 %+ d
662 mov stream, [rsp + stream_offset]
663 mov dword [stream + _internal_state_state], ZSTATE_CREATE_HDR
666 ;; update input buffer
667 add file_length, [rsp + inbuf_slop_offset]
668 mov [stream + _total_in], f_i %+ d
669 mov [stream + _internal_state_block_end], f_i %+ d
671 mov [stream + _next_in], file_start
673 mov [stream + _avail_in], file_length %+ d
675 ;; update output buffer
676 mov [level_buf + _icf_buf_next], m_out_buf
677 sub m_out_buf, [rsp + m_out_start]
678 sub [level_buf + _icf_buf_avail_out], m_out_buf %+ d
680 mov rbx, [rsp + gpr_save_mem_offset + 0*8]
681 mov rsi, [rsp + gpr_save_mem_offset + 1*8]
682 mov rdi, [rsp + gpr_save_mem_offset + 2*8]
683 mov rbp, [rsp + gpr_save_mem_offset + 3*8]
684 mov r12, [rsp + gpr_save_mem_offset + 4*8]
685 mov r13, [rsp + gpr_save_mem_offset + 5*8]
686 mov r14, [rsp + gpr_save_mem_offset + 6*8]
687 mov r15, [rsp + gpr_save_mem_offset + 7*8]
699 lea tmp2, [tmp1 + dist - 1]
701 mov len2, file_length
703 add len2, [rsp + inbuf_slop_offset]
705 mov tmp3, MAX_EMIT_SIZE
710 compare_large tmp1, tmp2, len, len2, tmp3, ytmp0, ytmp1
713 jle .len_dist_huffman
714 cmp len, LARGE_MATCH_MIN
717 jmp .len_dist_huffman
721 lea tmp2, [tmp1 + dist2]
726 add len, [rsp + inbuf_slop_offset]
727 mov tmp3, MAX_EMIT_SIZE
732 compare_large tmp1, tmp2, len2, len, tmp3, ytmp0, ytmp1
734 movzx lit_code, curr_data %+ b
736 inc dword [lit_len_hist + HIST_ELEM_SIZE*lit_code]
738 jle .len_dist_lit_huffman
739 cmp len2, LARGE_MATCH_MIN
742 jmp .len_dist_lit_huffman
746 mov dword [m_out_buf], lit_code %+ d
755 get_dist_icf_code dist, dist_code, tmp1
757 mov len_code2, 258 + 254
758 or len_code2, dist_code
760 shr tmp1, DIST_OFFSET
765 mov [hash_table + 2 * hash], tmp3 %+ w
767 mov [hash_table + 2 * hash2], tmp3 %+ w
772 inc dword [lit_len_hist + HIST_ELEM_SIZE*(258 + 254)]
773 inc dword [dist_hist + HIST_ELEM_SIZE*tmp1]
774 mov dword [m_out_buf], len_code2 %+ d
777 cmp m_out_buf, [rsp + m_out_end]
780 cmp len, LARGE_MATCH_MIN
787 ; get_len_code(len, &code, &code_len);
789 lea len_code, [len + 254]
790 or dist_code, len_code
792 inc dword [lit_len_hist + HIST_ELEM_SIZE*len_code]
793 inc dword [dist_hist + HIST_ELEM_SIZE*tmp1]
795 mov dword [m_out_buf], dist_code %+ d
801 lea tmp2, [f_i - 4 * LARGE_MATCH_HASH_REP]
802 mov hmask2 %+ d, [rsp + hash_mask_offset]
804 %rep LARGE_MATCH_HASH_REP
805 mov curr_data %+ d, dword [file_start + tmp2]
806 mov curr_data2 %+ d, dword [file_start + tmp2 + 1]
807 mov tmp3 %+ d, dword [file_start + tmp2 + 2]
808 mov tmp1 %+ d, dword [file_start + tmp2 + 3]
810 compute_hash hash, curr_data
811 compute_hash hash2, curr_data2
812 compute_hash hash3, tmp3
813 compute_hash hmask3, tmp1
815 and hash %+ d, hmask2 %+ d
816 and hash2 %+ d, hmask2 %+ d
817 and hash3 %+ d, hmask2 %+ d
818 and hmask3 %+ d, hmask2 %+ d
820 mov [hash_table + 2 * hash], tmp2 %+ w
822 mov [hash_table + 2 * hash2], tmp2 %+ w
824 mov [hash_table + 2 * hash3], tmp2 %+ w
826 mov [hash_table + 2 * hmask3], tmp2 %+ w
827 %if (LARGE_MATCH_HASH_REP > 1)
831 ; for (f_i = f_start_i; f_i < file_length; f_i++) {
832 MOVDQU xdata, [file_start + f_i]
833 mov curr_data, [file_start + f_i]
836 compute_hash hash, curr_data
839 compute_hash hash2, tmp1
847 mov hmask1 %+ d, [rsp + hash_mask_offset]
848 cmp m_out_buf, [rsp + m_out_end]
851 mov byte [stream + _internal_state_has_hist], IGZIP_HIST
853 mov [hash_table + 2 * hash], f_i %+ w
857 compute_hash hash2, tmp2
860 inc dword [lit_len_hist + HIST_ELEM_SIZE*curr_data]
863 mov dword [m_out_buf], curr_data %+ d
866 MOVDQU xdata, [file_start + f_i + 1]
868 mov curr_data, [file_start + f_i]
869 and hash %+ d, hmask1 %+ d
870 and hash2 %+ d, hmask1 %+ d
880 ;; Shift defines over in order to iterate over all versions
886 %ifdef COMPARE_TYPE_NOT_DEF
888 %xdefine COMPARE_TYPE COMPARE_TYPE1
890 %xdefine COMPARE_TYPE1 COMPARE_TYPE2
894 dd LIT + (1 << DIST_OFFSET)
897 db 0x00, 0xff, 0xff, 0xff, 0x02, 0xff, 0xff, 0xff
898 db 0x04, 0xff, 0xff, 0xff, 0x06, 0xff, 0xff, 0xff
900 db 0x01, 0xff, 0xff, 0xff, 0x03, 0xff, 0xff, 0xff
901 db 0x05, 0xff, 0xff, 0xff, 0x07, 0xff, 0xff, 0xff