Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(6)

Side by Side Diff: third_party/zlib/deflate.h

Issue 671163003: Revert of Integrate SIMD optimisations for zlib (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « third_party/zlib/crc_folding.c ('k') | third_party/zlib/deflate.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* deflate.h -- internal compression state 1 /* deflate.h -- internal compression state
2 * Copyright (C) 1995-2010 Jean-loup Gailly 2 * Copyright (C) 1995-2010 Jean-loup Gailly
3 * For conditions of distribution and use, see copyright notice in zlib.h 3 * For conditions of distribution and use, see copyright notice in zlib.h
4 */ 4 */
5 5
6 /* WARNING: this file should *not* be used by applications. It is 6 /* WARNING: this file should *not* be used by applications. It is
7 part of the implementation of the compression library and is 7 part of the implementation of the compression library and is
8 subject to change. Applications should only use zlib.h. 8 subject to change. Applications should only use zlib.h.
9 */ 9 */
10 10
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 Bytef *pending_buf; /* output still pending */ 100 Bytef *pending_buf; /* output still pending */
101 ulg pending_buf_size; /* size of pending_buf */ 101 ulg pending_buf_size; /* size of pending_buf */
102 Bytef *pending_out; /* next pending byte to output to the stream */ 102 Bytef *pending_out; /* next pending byte to output to the stream */
103 uInt pending; /* nb of bytes in the pending buffer */ 103 uInt pending; /* nb of bytes in the pending buffer */
104 int wrap; /* bit 0 true for zlib, bit 1 true for gzip */ 104 int wrap; /* bit 0 true for zlib, bit 1 true for gzip */
105 gz_headerp gzhead; /* gzip header information to write */ 105 gz_headerp gzhead; /* gzip header information to write */
106 uInt gzindex; /* where in extra, name, or comment */ 106 uInt gzindex; /* where in extra, name, or comment */
107 Byte method; /* STORED (for zip only) or DEFLATED */ 107 Byte method; /* STORED (for zip only) or DEFLATED */
108 int last_flush; /* value of flush param for previous deflate call */ 108 int last_flush; /* value of flush param for previous deflate call */
109 109
110 unsigned zalign(16) crc0[4 * 5];
111
112 /* used by deflate.c: */ 110 /* used by deflate.c: */
113 111
114 uInt w_size; /* LZ77 window size (32K by default) */ 112 uInt w_size; /* LZ77 window size (32K by default) */
115 uInt w_bits; /* log2(w_size) (8..16) */ 113 uInt w_bits; /* log2(w_size) (8..16) */
116 uInt w_mask; /* w_size - 1 */ 114 uInt w_mask; /* w_size - 1 */
117 115
118 Bytef *window; 116 Bytef *window;
119 /* Sliding window. Input bytes are read into the second half of the window, 117 /* Sliding window. Input bytes are read into the second half of the window,
120 * and move to the first half later to keep a dictionary of at least wSize 118 * and move to the first half later to keep a dictionary of at least wSize
121 * bytes. With this organization, matches are limited to a distance of 119 * bytes. With this organization, matches are limited to a distance of
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after
339 s->dyn_ltree[_length_code[len]+LITERALS+1].Freq++; \ 337 s->dyn_ltree[_length_code[len]+LITERALS+1].Freq++; \
340 s->dyn_dtree[d_code(dist)].Freq++; \ 338 s->dyn_dtree[d_code(dist)].Freq++; \
341 flush = (s->last_lit == s->lit_bufsize-1); \ 339 flush = (s->last_lit == s->lit_bufsize-1); \
342 } 340 }
343 #else 341 #else
344 # define _tr_tally_lit(s, c, flush) flush = _tr_tally(s, 0, c) 342 # define _tr_tally_lit(s, c, flush) flush = _tr_tally(s, 0, c)
345 # define _tr_tally_dist(s, distance, length, flush) \ 343 # define _tr_tally_dist(s, distance, length, flush) \
346 flush = _tr_tally(s, distance, length) 344 flush = _tr_tally(s, distance, length)
347 #endif 345 #endif
348 346
349 /* Functions that are SIMD optimised on x86 */
350 void ZLIB_INTERNAL crc_fold_init(deflate_state* const s);
351 void ZLIB_INTERNAL crc_fold_copy(deflate_state* const s,
352 unsigned char* dst,
353 const unsigned char* src,
354 long len);
355 unsigned ZLIB_INTERNAL crc_fold_512to32(deflate_state* const s);
356
357 Pos ZLIB_INTERNAL insert_string_sse(deflate_state* const s, const Pos str);
358 void ZLIB_INTERNAL fill_window_sse(deflate_state* s);
359
360 #endif /* DEFLATE_H */ 347 #endif /* DEFLATE_H */
OLDNEW
« no previous file with comments | « third_party/zlib/crc_folding.c ('k') | third_party/zlib/deflate.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698