]> git.ipfire.org Git - thirdparty/zlib-ng.git/log
thirdparty/zlib-ng.git
5 years agoClean up zng_tr_tally code.
Nathan Moinvaziri [Thu, 5 Mar 2020 02:27:10 +0000 (18:27 -0800)] 
Clean up zng_tr_tally code.

5 years agoFixed possible unsigned integer overflow in send_bits when calculating the new bits...
Nathan Moinvaziri [Mon, 10 Feb 2020 15:12:37 +0000 (07:12 -0800)] 
Fixed possible unsigned integer overflow in send_bits when calculating the new bits valid it bit buffer.

5 years agoFixed incorrect compiler used for GitHub Actions configure instances.
Nathan Moinvaziri [Mon, 9 Mar 2020 16:48:59 +0000 (09:48 -0700)] 
Fixed incorrect compiler used for GitHub Actions configure instances.
Removed unused asan environment variables.

5 years agoRemove old INDEX file as contents already specified in README.md.
Nathan Moinvaziri [Fri, 14 Feb 2020 03:30:06 +0000 (19:30 -0800)] 
Remove old INDEX file as contents already specified in README.md.

5 years agoAdd testing with compiler flags -O1 and -g3, let MSAN run with -g3
Hans Kristian Rosbach [Thu, 13 Feb 2020 14:40:26 +0000 (15:40 +0100)] 
Add testing with compiler flags -O1 and -g3, let MSAN run with -g3

5 years agoMake sure we use unique codecov flags for each test run
Hans Kristian Rosbach [Wed, 12 Feb 2020 20:41:35 +0000 (21:41 +0100)] 
Make sure we use unique codecov flags for each test run

5 years agoImport default codecfactor.io .shellcheckrc file.
Hans Kristian Rosbach [Sat, 8 Feb 2020 23:18:01 +0000 (00:18 +0100)] 
Import default codecfactor.io .shellcheckrc file.
Disable codefactor complaints about using $? for retval checking (SC2181).

5 years agoAttempt to run codecov again if it fails.
Hans Kristian Rosbach [Sat, 8 Feb 2020 21:37:43 +0000 (22:37 +0100)] 
Attempt to run codecov again if it fails.

5 years agoDon't enable debug when building with code coverage.
Hans Kristian Rosbach [Sat, 8 Feb 2020 15:23:13 +0000 (16:23 +0100)] 
Don't enable debug when building with code coverage.
Don't disable optimization when building with code coverage.
Make sure GCC links with gcov, like the docs says you should.

5 years agoFix codecov for pull requests.
Hans Kristian Rosbach [Sat, 8 Feb 2020 15:22:14 +0000 (16:22 +0100)] 
Fix codecov for pull requests.
Fail build if codecov fails.

5 years agoAdd cpuidex.
Mika Lindqvist [Mon, 10 Feb 2020 17:17:31 +0000 (19:17 +0200)] 
Add cpuidex.

5 years agoFixed GitHub Actions warning about old version of macOS being used.
Nathan Moinvaziri [Sun, 9 Feb 2020 03:35:20 +0000 (19:35 -0800)] 
Fixed GitHub Actions warning about old version of macOS being used.

5 years agoFixed missing compressed_len count in deflate_quick when ZLIB_DEBUG defined. Put...
Nathan Moinvaziri [Fri, 7 Feb 2020 23:01:10 +0000 (15:01 -0800)] 
Fixed missing compressed_len count in deflate_quick when ZLIB_DEBUG defined. Put most likely condition in send_bits first.

5 years agoRenamed bit buffer local variables consistently.
Nathan Moinvaziri [Sun, 2 Feb 2020 22:15:11 +0000 (14:15 -0800)] 
Renamed bit buffer local variables consistently.

5 years agoReplace quick_send_bits with send_bits now that bi_buf is 32-bit.
Nathan Moinvaziri [Sun, 2 Feb 2020 20:58:18 +0000 (12:58 -0800)] 
Replace quick_send_bits with send_bits now that bi_buf is 32-bit.

5 years agoChange deflate_state's bi_buf from 16-bit to 32-bit.
Nathan Moinvaziri [Sun, 2 Feb 2020 17:46:00 +0000 (09:46 -0800)] 
Change deflate_state's bi_buf from 16-bit to 32-bit.

5 years agoFixed configure CI not working after adding macOS config. #518
Nathan Moinvaziri [Fri, 7 Feb 2020 20:49:36 +0000 (12:49 -0800)] 
Fixed configure CI not working after adding macOS config. #518

5 years agoAdded codecov badge to README.md.
Nathan Moinvaziri [Fri, 7 Feb 2020 20:06:55 +0000 (12:06 -0800)] 
Added codecov badge to README.md.

5 years agoAdded infcover code coverage test executable to cmake test.
Nathan Moinvaziri [Thu, 12 Dec 2019 17:51:14 +0000 (09:51 -0800)] 
Added infcover code coverage test executable to cmake test.
Modified infcover.c to work with zlib-ng.
Fixed compiler warnings in infcover.c.

5 years agoAdd initial AVX2 support.
Mika Lindqvist [Wed, 22 Jan 2020 20:58:35 +0000 (22:58 +0200)] 
Add initial AVX2 support.

5 years agoEnable CI options explicitly so forked repositories don't fail CI. #487
Nathan Moinvaziri [Mon, 6 Jan 2020 01:58:24 +0000 (17:58 -0800)] 
Enable CI options explicitly so forked repositories don't fail CI. #487

5 years agoSupport aligned alloc/free functions for Windows and define them only if MZ_ZALLOC...
Nathan Moinvaziri [Tue, 28 Jan 2020 06:10:49 +0000 (22:10 -0800)] 
Support aligned alloc/free functions for Windows and define them only if MZ_ZALLOC is not defined.

5 years agoFixed compiler warning when using BITS macro.
Nathan Moinvaziri [Sun, 2 Feb 2020 16:29:11 +0000 (08:29 -0800)] 
Fixed compiler warning when using BITS macro.

5 years agoAdded better aligned access support for put_short.
Nathan Moinvaziri [Sun, 26 Jan 2020 20:34:54 +0000 (12:34 -0800)] 
Added better aligned access support for put_short.
Renamed putShortMSB to put_short_msb and moved to deflate.h with the rest of the put functions.
Added put_uint32 and put_uint32_msb and replaced instances of put_byte with put_short or put_uint32.

5 years agoUse value already stored in wsize.
Nathan Moinvaziri [Fri, 31 Jan 2020 22:34:32 +0000 (14:34 -0800)] 
Use value already stored in wsize.

5 years agoFixed wrong compiler names specified in build matrix.
Nathan Moinvaziri [Sun, 19 Jan 2020 02:13:11 +0000 (18:13 -0800)] 
Fixed wrong compiler names specified in build matrix.

5 years agoRemoved MAX_DIST2 which is incompatible with zlib when compiled with INFLATE_STRICT...
Nathan Moinvaziri [Thu, 2 Jan 2020 15:59:52 +0000 (07:59 -0800)] 
Removed MAX_DIST2 which is incompatible with zlib when compiled with INFLATE_STRICT. It also fixes the check for proper bounds in zng_tr_tally.

5 years agoFix double specification of -O2
Gabriel A. Devenyi [Tue, 28 Jan 2020 15:12:25 +0000 (10:12 -0500)] 
Fix double specification of -O2

5 years agoFixed configure script use of sed on macOS. #427
Nathan Moinvaziri [Sun, 19 Jan 2020 01:26:04 +0000 (17:26 -0800)] 
Fixed configure script use of sed on macOS. #427
Added macOS configure build.

5 years agoDisable alignment sanitizer when architecture supports unaligned reads. #496
Nathan Moinvaziri [Fri, 10 Jan 2020 04:01:56 +0000 (20:01 -0800)] 
Disable alignment sanitizer when architecture supports unaligned reads. #496

5 years agoFixed formatting, 4 spaces for code intent, 2 spaces for preprocessor indent, initial...
Nathan Moinvaziri [Wed, 8 Jan 2020 03:09:34 +0000 (19:09 -0800)] 
Fixed formatting, 4 spaces for code intent, 2 spaces for preprocessor indent, initial function brace on the same line as definition, removed extraneous spaces and new lines.

5 years agoSet arch based on target compiler if cross compiling.
Nathan Moinvaziri [Thu, 12 Dec 2019 06:50:50 +0000 (22:50 -0800)] 
Set arch based on target compiler if cross compiling.

5 years agos390: fix build failure with --with-dfltcc-deflate
Ilya Leoshkevich [Tue, 10 Dec 2019 13:33:04 +0000 (14:33 +0100)] 
s390: fix build failure with --with-dfltcc-deflate

Patch by Michael Munday (issue #477).

5 years agoAdded gzip tests for all open modes and compression levels for more code coverage.
Nathan Moinvaziri [Fri, 25 Oct 2019 19:53:04 +0000 (12:53 -0700)] 
Added gzip tests for all open modes and compression levels for more code coverage.
Added tests for gzip compress/uncompress for all open modes.
Added test data from Google snappy project and include copying info.

5 years agoCompatibility fix for crc32()
Mika Lindqvist [Mon, 25 Nov 2019 23:23:50 +0000 (01:23 +0200)] 
Compatibility fix for crc32()
* Use "unsigned long" externally instead of "uint32_t" for crc
* Use "unsigned int" externally instead of "uint32_t" for len

Fixes #483

5 years agoCompatibility fix
Mika Lindqvist [Mon, 25 Nov 2019 23:39:16 +0000 (01:39 +0200)] 
Compatibility fix
* Add back OF() macro

5 years agoImprovements to GitHub Actions for code coverage.
Nathan Moinvaziri [Mon, 4 Nov 2019 00:42:23 +0000 (16:42 -0800)] 
Improvements to GitHub Actions for code coverage.

5 years agoconfigure: relax arm detection
MilhouseVH [Mon, 25 Nov 2019 16:50:43 +0000 (16:50 +0000)] 
configure: relax arm detection

5 years agoFixed checksum combine being compiled out on release builds.
Nathan Moinvaziri [Sat, 26 Oct 2019 18:06:44 +0000 (11:06 -0700)] 
Fixed checksum combine being compiled out on release builds.

5 years agoComment assert in chunkmemset when len < sizeof(uint64_t) since the function handles...
Nathan Moinvaziri [Sat, 5 Oct 2019 01:54:26 +0000 (18:54 -0700)] 
Comment assert in chunkmemset when len < sizeof(uint64_t) since the function handles that condition properly.

5 years agoFixed assert during inflate fast when len < sizeof(uint64_t).
Nathan Moinvaziri [Fri, 20 Sep 2019 05:11:43 +0000 (22:11 -0700)] 
Fixed assert during inflate fast when len < sizeof(uint64_t).

5 years agoAdded debug build configuration to GitHub Actions
Nathan Moinvaziri [Thu, 24 Oct 2019 15:32:58 +0000 (08:32 -0700)] 
Added debug build configuration to GitHub Actions

5 years agoFixed unresolved external symbols when building maketrees.
Nathan Moinvaziri [Thu, 24 Oct 2019 15:43:10 +0000 (08:43 -0700)] 
Fixed unresolved external symbols when building maketrees.

5 years agoFixed pip not installing codecov-python on windows after mingw downgrade.
Nathan Moinvaziri [Thu, 24 Oct 2019 16:08:41 +0000 (09:08 -0700)] 
Fixed pip not installing codecov-python on windows after mingw downgrade.

5 years agoFixed formatting converting tabs to spaces.
Nathan Moinvaziri [Wed, 23 Oct 2019 15:06:08 +0000 (08:06 -0700)] 
Fixed formatting converting tabs to spaces.

5 years agoReplaced Travis CI badge with GitHub Actions badges.
Nathan Moinvaziri [Wed, 23 Oct 2019 00:33:57 +0000 (17:33 -0700)] 
Replaced Travis CI badge with GitHub Actions badges.

5 years agoRun GitHub Actions workflow on pull requests.
Nathan Moinvaziri [Wed, 23 Oct 2019 01:30:43 +0000 (18:30 -0700)] 
Run GitHub Actions workflow on pull requests.

5 years agoFixed build when apt-get out of date in GitHub Actions images.
Nathan Moinvaziri [Wed, 23 Oct 2019 00:21:10 +0000 (17:21 -0700)] 
Fixed build when apt-get out of date in GitHub Actions images.

5 years agoFixed buffer read overflow in crc32 folding when allocation size is not a multiple...
Nathan Moinvaziri [Tue, 22 Oct 2019 02:13:20 +0000 (19:13 -0700)] 
Fixed buffer read overflow in crc32 folding when allocation size is not a multiple of 16 bytes. zlib-ng/zlib-ng#452

5 years agoFixed signed warnings in zng_tr_tally_dist on Windows.
Nathan Moinvaziri [Mon, 7 Oct 2019 01:47:29 +0000 (18:47 -0700)] 
Fixed signed warnings in zng_tr_tally_dist on Windows.

5 years agoAdded missing headers for intrinsics.
Nathan Moinvaziri [Tue, 22 Oct 2019 00:43:52 +0000 (17:43 -0700)] 
Added missing headers for intrinsics.

5 years agoFixed compiler warnings in fuzzers. zlib-ng/zlib-ng#454
Nathan Moinvaziri [Sun, 20 Oct 2019 22:14:22 +0000 (15:14 -0700)] 
Fixed compiler warnings in fuzzers. zlib-ng/zlib-ng#454

5 years agoFixed load of misaligned address in deflate_quick.c. zlib-ng/zlib-ng#453
Nathan Moinvaziri [Sun, 20 Oct 2019 21:40:42 +0000 (14:40 -0700)] 
Fixed load of misaligned address in deflate_quick.c. zlib-ng/zlib-ng#453

5 years agoDon't bother computing check value after successful inflateSync().
Mark Adler [Thu, 3 Jan 2019 02:10:40 +0000 (18:10 -0800)] 
Don't bother computing check value after successful inflateSync().

inflateSync() is used to skip invalid deflate data, which means
that the check value that was being computed is no longer useful.
This commit turns off the check value computation, and furthermore
allows a successful return if the compressed data terminated in a
graceful manner. This commit also fixes a bug in the case that
inflateSync() is used before a header is ever processed. In that
case, there is no knowledge of a trailer, so the remainder is
treated as raw.

5 years agoClean up LIKELY/UNLIKELY definitions, making them upper-case to improve visibility.
Hans Kristian Rosbach [Mon, 23 Sep 2019 07:47:32 +0000 (09:47 +0200)] 
Clean up LIKELY/UNLIKELY definitions, making them upper-case to improve visibility.
Add LIKELY_NULL hint.
Add PREFETCH_L1, PREFETCH_L2 and PREFETCH_RW for GCC, Clang, ICC and MSVC.

5 years agoAvoid adding empty gzip member after gzflush with Z_FINISH.
Mark Adler [Sun, 14 Apr 2019 00:05:16 +0000 (17:05 -0700)] 
Avoid adding empty gzip member after gzflush with Z_FINISH.

5 years agozlib-ng.h syntax cleanup
Hans Kristian Rosbach [Mon, 7 Oct 2019 19:38:36 +0000 (21:38 +0200)] 
zlib-ng.h syntax cleanup

5 years agoAdded github actions yaml for cmake and configure.
Nathan Moinvaziri [Wed, 25 Sep 2019 02:40:26 +0000 (19:40 -0700)] 
Added github actions yaml for cmake and configure.
Added cmake toolchain files for qemu powerpc, sparc64, and s390x.
Turn off shared libs for qemu and use static builds for qemu.
Fixed maintainer mode being overwriting when in CI by options parsing.
Set CI environment variable to enable Fuzzers by default.
Added support for code-coverage for all tests.

5 years agoUse temp variables in send_all_trees too
Hans Kristian Rosbach [Tue, 17 Sep 2019 13:48:03 +0000 (15:48 +0200)] 
Use temp variables in send_all_trees too
Re-introduce private temp variables for val and len in send_bits macro.

5 years agoReduce indirections used by send_bits and send_code.
Hans Kristian Rosbach [Sun, 11 Aug 2019 20:53:22 +0000 (22:53 +0200)] 
Reduce indirections used by send_bits and send_code.
Also simplify the debug tracing into the define instead
of using a separate static function.
x86_64 shows a small performance improvement.

5 years agoMove scan_start check, based on Cloudflare commit
Hans Kristian Rosbach [Sun, 11 Aug 2019 16:55:14 +0000 (18:55 +0200)] 
Move scan_start check, based on Cloudflare commit
5f1bd2b72e5966aa8a4f942e6e8050a050161cf9

5 years agoFixed msan detection when compiler doesn't support it.
Nathan Moinvaziri [Sun, 6 Oct 2019 01:30:40 +0000 (18:30 -0700)] 
Fixed msan detection when compiler doesn't support it.

5 years agoAdded private headers to cmake and fallback_builtins.h for MSVC.
Nathan Moinvaziri [Tue, 8 Oct 2019 01:50:58 +0000 (18:50 -0700)] 
Added private headers to cmake and fallback_builtins.h for MSVC.

5 years agoFixed use of uninitialized value in test_deflate_copy when deflateCopy is called...
Nathan Moinvaziri [Sun, 6 Oct 2019 17:14:42 +0000 (10:14 -0700)] 
Fixed use of uninitialized value in test_deflate_copy when deflateCopy is called. #438

5 years agoFixed use of uninitialized value state in makefixed. #437
Nathan Moinvaziri [Mon, 7 Oct 2019 01:54:05 +0000 (18:54 -0700)] 
Fixed use of uninitialized value state in makefixed. #437

5 years agoFixed signed warnings in match_p.h on arm. #430
Nathan Moinvaziri [Mon, 7 Oct 2019 02:01:31 +0000 (19:01 -0700)] 
Fixed signed warnings in match_p.h on arm. #430

5 years agoFixed missing comma in msvc inline asm.
Nathan Moinvaziri [Sat, 5 Oct 2019 07:36:55 +0000 (00:36 -0700)] 
Fixed missing comma in msvc inline asm.

5 years agoFixed tab formatting in fuzzers (#414)
Nathan Moinvaziri [Sun, 6 Oct 2019 17:59:07 +0000 (10:59 -0700)] 
Fixed tab formatting in fuzzers (#414)

* Fixed tab formatting in fuzzers.
* Fixed function argument spacing.
* Fixed whitespace in comments and strings.

5 years agotravis.yml changes:
Hans Kristian Rosbach [Thu, 19 Sep 2019 08:12:49 +0000 (10:12 +0200)] 
travis.yml changes:
 - Select minimal vm image instead of generic ('C'), reducing size and boot time.
   - Windows needs 'C' image to not hang on booting
 - Update from Xenial to Bionic for linux tests.
   - ppc64 images don't have Bionic, set to Xenial
   - ppc64 is having misc failures with Xenial tools, so use GCC-9 and Clang-6
   - ppc64 cannot run MSAN
 - Add another test for more complete testing across architectures.
 - Enable fuzzers, msan and/or sanitizers most various tests.
 - Disable ASAN leak detection on aarch64, since it crashes under qemu
 - Reorder tests to be better grouped and running windows/macox tests lasts.
 - Enable verbose messages from sanitizers

CmakeLists.txt changes:
 - Enable warnings by default.
 - Add MAINTAINER setting to cmake
   - Enables extra warnings.
   - Enables fuzzers.
 - Add CI detection to cmake, currently auto-enables MAINTAINER mode.
 - Add detection of several more sanitizer features.
 - Test sanitizer features together, not just alone.
   This also helps with their inter-dependencies.

.gitignore changes:
 - Add switchlevels.

5 years agoConfigure: Don't enable optimizations if without-optimizations has been set.
Hans Kristian Rosbach [Fri, 20 Sep 2019 22:07:05 +0000 (00:07 +0200)] 
Configure: Don't enable optimizations if without-optimizations has been set.
Add ARM_GETAUXVAL define for ARM platforms if optimizations is enabled.

5 years agoUnify detection of ARM getauxval code availability.
Hans Kristian Rosbach [Fri, 20 Sep 2019 20:50:50 +0000 (22:50 +0200)] 
Unify detection of ARM getauxval code availability.
We don't want to compile arch-specific code when WITH_OPTIM is not set,
and the current checks don't take that into account.

5 years agoClean up parts of CMakeLists.txt
Hans Kristian Rosbach [Fri, 20 Sep 2019 18:53:16 +0000 (20:53 +0200)] 
Clean up parts of CMakeLists.txt

5 years agoAdd archdetect as separate cmake include file.
Hans Kristian Rosbach [Fri, 20 Sep 2019 18:35:44 +0000 (20:35 +0200)] 
Add archdetect as separate cmake include file.
Simplify architecture checking by setting BASEARCH in addition to ARCH.

5 years agoFixed running fuzzers with cmake on arm.
Nathan Moinvaziri [Fri, 20 Sep 2019 23:46:50 +0000 (16:46 -0700)] 
Fixed running fuzzers with cmake on arm.

5 years agoFixed crc1 unused variable warning. #418.
Nathan Moinvaziri [Fri, 20 Sep 2019 22:37:00 +0000 (15:37 -0700)] 
Fixed crc1 unused variable warning. #418.

5 years agoAdd oss-fuzz to readme.
Nathan Moinvaziri [Fri, 20 Sep 2019 22:45:18 +0000 (15:45 -0700)] 
Add oss-fuzz to readme.

5 years agoAdd makecrct test and clean up makecrct.c code
Hans Kristian Rosbach [Tue, 17 Sep 2019 12:12:15 +0000 (14:12 +0200)] 
Add makecrct test and clean up makecrct.c code
Update crc32.h tables to match makecrct output.

5 years agoSplit crc table generating code (MAKECRCH) out into separate tool makecrct.
Hans Kristian Rosbach [Tue, 17 Sep 2019 11:18:02 +0000 (13:18 +0200)] 
Split crc table generating code (MAKECRCH) out into separate tool makecrct.

5 years agoAdd maketrees test and clean up maketrees.c code
Hans Kristian Rosbach [Sun, 15 Sep 2019 16:15:08 +0000 (18:15 +0200)] 
Add maketrees test and clean up maketrees.c code

5 years agoSplit maketrees out into a separate tool
Hans Kristian Rosbach [Sun, 15 Sep 2019 12:52:27 +0000 (14:52 +0200)] 
Split maketrees out into a separate tool

5 years agotravis.yml changes:
Hans Kristian Rosbach [Fri, 20 Sep 2019 09:26:28 +0000 (11:26 +0200)] 
travis.yml changes:
 - Add shorthand-variables for some of the long parameters often used
 - Enable --warn in a couple configure tests that did not have it enabled.
 - Make travis print out CMakeError.log or configure.log in after_failure.
 - Reorder some cmake parameters to improve consistency
 - Disable ccache. Downloading and uploading the cache archive is quite slow,
   especially if travis is having network-connectivity issues.
   Also ccache caches gcno (coverage) files, making the coverage data wrong
   because it is being shared across builds, branches and PRs.

CmakeLists.txt changes:
 - Enable -Wall by default in cmake.

5 years agoPotential fix for clang array warnings. #416
Nathan Moinvaziri [Fri, 20 Sep 2019 04:57:20 +0000 (21:57 -0700)] 
Potential fix for clang array warnings. #416

5 years agoFixed warnings in checksum fuzzer and example. #418
Nathan Moinvaziri [Fri, 20 Sep 2019 01:21:46 +0000 (18:21 -0700)] 
Fixed warnings in checksum fuzzer and example. #418

5 years agoFixed minigzip fuzzer failures on Windows. #411
Nathan Moinvaziri [Thu, 19 Sep 2019 17:17:04 +0000 (10:17 -0700)] 
Fixed minigzip fuzzer failures on Windows. #411

5 years agoIn test_deflate_copy(), we free the original struct but forget to free the copy stuct.
Hans Kristian Rosbach [Thu, 19 Sep 2019 14:14:48 +0000 (16:14 +0200)] 
In test_deflate_copy(), we free the original struct but forget to free the copy stuct.
Found by msan.

5 years agoFixed several warnings in example and fuzzers. #409
Nathan Moinvaziri [Thu, 19 Sep 2019 16:57:42 +0000 (09:57 -0700)] 
Fixed several warnings in example and fuzzers. #409

5 years agoFixed use of uninitialized value warning in crc_folding.c #394
Nathan Moinvaziri [Sun, 15 Sep 2019 22:34:12 +0000 (15:34 -0700)] 
Fixed use of uninitialized value warning in crc_folding.c #394

5 years agoSimplify adding src files with list() command. (#405)
Nathan Moinvaziri [Wed, 18 Sep 2019 20:13:15 +0000 (13:13 -0700)] 
Simplify adding src files with list() command. (#405)

5 years agoMake travis retry its operations, to attempt to avoid many of the
Hans Kristian Rosbach [Tue, 17 Sep 2019 14:12:22 +0000 (16:12 +0200)] 
Make travis retry its operations, to attempt to avoid many of the
failed builds due to silly things like git failed to look up github.com
or apt failed to install deps due to network timeout, etc.

Make curl retry download of codecov bash script, and
make codecov re-try the uploads, since all the network errors
travis has is causing erratic coverage data.

5 years agoAdd test cases to #437
jiangjufa [Thu, 25 Jul 2019 03:13:49 +0000 (11:13 +0800)] 
Add test cases to #437

5 years agoAdded travis msvc 64 bit builds.
Nathan Moinvaziri [Wed, 11 Sep 2019 01:37:32 +0000 (18:37 -0700)] 
Added travis msvc 64 bit builds.

5 years agoAdded cmake tests to verify output of makefixed (#398)
Nathan Moinvaziri [Sat, 14 Sep 2019 17:02:45 +0000 (10:02 -0700)] 
Added cmake tests to verify output of makefixed (#398)

* Add auto-generated header files to .gitignore
* Remove auto-generated header files in make clean

5 years agoRemoved obsolete text file.
Nathan Moinvaziri [Sat, 7 Sep 2019 23:33:41 +0000 (16:33 -0700)] 
Removed obsolete text file.

5 years agoAdd support for Visual Studio 2019 nmake.
Mika Lindqvist [Thu, 29 Aug 2019 16:40:03 +0000 (19:40 +0300)] 
Add support for Visual Studio 2019 nmake.

5 years agocrc_folding: use temp buffer for partial stores
Jim Kukunas [Thu, 8 Dec 2016 04:13:26 +0000 (20:13 -0800)] 
crc_folding: use temp buffer for partial stores

With deflate, the only destination for crc folding was the window, which
was guaranteed to have an extra 15B of padding (because we allocated it).
This padding allowed us to handle the partial store case (len < 16)
with a regular SSE store.

For inflate, this is no longer the case. For crc folding to be
efficient, it needs to operate on large chunks of the data each call.
For inflate, this means copying the decompressed data out to the
user-provided output buffer (moreso with our reorganized window). Since
it's user-provided, we don't have the padding guarantee and therefore
need to fallback to a slower method of handling partial length stores.

5 years agocrc_folding: Fix potential out-of-bounds access
Nicolas Trangez [Thu, 3 Mar 2016 17:17:43 +0000 (18:17 +0100)] 
crc_folding: Fix potential out-of-bounds access

In some (very rare) scenarios, the SIMD code in the `crc_folding` module
can perform out-of-bounds reads or writes, which could lead to GPF
crashes.

Here's the deal: when the `crc_fold_copy` function is called with a
non-zero `len` argument of less then 16, `src` is read through
`_mm_loadu_si128` which always reads 16 bytes. If the `src` pointer
points to a location which contains `len` bytes, but any of the `16 -
len` out-of-bounds bytes falls in unmapped memory, this operation will
trigger a GPF.

The same goes for the `dst` pointer when written to through
`_mm_storeu_si128`.

With this patch applied, the crash no longer occurs.

We first discovered this issue though Valgrind reporting an
out-of-bounds access while running a unit-test for some code derived
from `crc_fold_copy`. In general, the out-of-bounds read is not an issue
because reads only occur in sections which are definitely mapped
(assuming page size is a multiple of 16), and garbage bytes are ignored.
While giving this some more thought we realized for small `len` values
and `src` or `dst` pointers at a very specific place in the address
space can lead to GPFs.

- Minor tweaks to merge request by Jim Kukunas <james.t.kukunas@linux.intel.com>
- removed C11-isms
- use unaligned load
- better integrated w/ zlib (use zalign)
- removed full example code from commit msg

5 years agoUse slide_hash_sse2 from fill_window_sse instead of having a local
Hans Kristian Rosbach [Fri, 23 Aug 2019 19:02:55 +0000 (21:02 +0200)] 
Use slide_hash_sse2 from fill_window_sse instead of having a local
copy of the code.

5 years agoAdd slide_hash to functable, and enable the sse2-optimized version.
Hans Kristian Rosbach [Fri, 23 Aug 2019 18:25:26 +0000 (20:25 +0200)] 
Add slide_hash to functable, and enable the sse2-optimized version.
Add necessary code to cmake and configure.
Fix slide_hash_sse2 to compile with zlib-ng.

5 years agoAdds SSE2 optimized slide_hash.
Jim Kukunas [Thu, 21 Jun 2018 20:47:32 +0000 (20:47 +0000)] 
Adds SSE2 optimized slide_hash.

Edit: Removed glue code in deflate.c, since we want
to implement this differently in zlib-ng.

5 years agoChanges to support compilation with MSVC ARM & ARM64 (#386)
Nathan Moinvaziri [Wed, 4 Sep 2019 06:35:23 +0000 (23:35 -0700)] 
Changes to support compilation with MSVC ARM & ARM64 (#386)

* Merge aarch64 and arm cmake sections.
* Updated MSVC compiler support for ARM and ARM64.
* Moved detection for -mfpu=neon to where the flag is set to simplify add_intrinsics_option.
* Only add ${ACLEFLAG} on aarch64 if not WITH_NEON.
* Rename arch/x86/ctzl.h to fallback_builtins.h.