2551 Commits

Author SHA1 Message Date
Timofey Solomko 03a68e6799 Merge branch 'hotfix-4.9.1' 4.9.1 2026-06-13 16:20:39 +08:00
Timofey Solomko 56267f0e14 Prepare for 4.9.1 release 2026-06-13 16:18:50 +08:00
Timofey Solomko e75d4bb167 [ZIP] Decode CP437 manually on non-Darwin platforms with Swift earlier than 6.2
Fixes #65.
2026-06-13 16:11:11 +08:00
Timofey Solomko 8b10dd5c0c [GZip] Add null terminator as a zero byte instead of character
Fixes #66.
2026-06-13 16:10:08 +08:00
Timofey Solomko c729f0baa4 Merge branch 'develop' 4.9.0 2026-05-22 19:46:17 +08:00
Timofey Solomko b2178ac126 Prepare for 4.9.0 release 2026-05-22 19:44:49 +08:00
Timofey Solomko 26dd6f5b5e Merge branch 'hotfix-4.8.7' into develop 2026-05-22 19:40:59 +08:00
Timofey Solomko b0b560e4c6 Merge branch 'hotfix-4.8.7' 4.8.7 2026-05-22 19:32:56 +08:00
Timofey Solomko 8ca3c18c61 Prepare for 4.8.7 release 2026-05-22 19:32:37 +08:00
Timofey Solomko 1c052807ba Merge branch 'wkonury-an-fix-dependency-version' into hotfix-4.8.7 2026-05-22 19:24:21 +08:00
Wojciech Konury 13676b8140 Lock BitByteData Dependency to 2.0.4 version 2026-05-22 12:40:10 +02:00
Timofey Solomko e3c41ca9a0 [BZip2] Fix grammar in comments 2026-05-22 17:16:29 +08:00
Timofey Solomko 3e78ae765b Update benchmark results due to a significant hardware update 2026-05-22 17:00:32 +08:00
Timofey Solomko 0bba830a3d [CI] Increase timeout for macOS jobs
Since we have to download simulators for some configurations every time, we hit the default timeout of 60 minutes. Increasing the timeout to 90 minutes should help.
2026-05-22 14:51:24 +08:00
Timofey Solomko 0da66b6da6 [CI] Upgrade deployment macOS version, remove DEVELOPER_DIR variable
Removing DEVELOPER_DIR variable should make CI use the default version of Xcode. Since recently AZP became more aggressive with removing older versions of Xcode from its CI images, relying on default version of Xcode will simplify maintenance of the CI configuration.
2026-05-21 16:58:27 +08:00
Timofey Solomko 462b443324 Update BBD version to 2.1.0 2026-05-21 16:57:02 +08:00
Timofey Solomko a41fe89076 [Tests] Add a test for 7-zip container with large LZMA dictionary size 2026-05-14 21:33:33 +08:00
Timofey Solomko 6cb19dfcfa Merge pull request #61 from analytical-engines/fix-lzma-dictionary-size 2026-05-14 21:31:46 +08:00
nekonya 735795a7e1 [7-Zip] Fix LZMA dictionary size parsing
The LZMA dictionary size was being read from only 3 bytes (indices 1-3)
instead of the full 4 bytes (indices 1-4) specified in the LZMA format.

This caused decompression to fail with LZMAError.notEnoughToRepeat for
archives using dictionary sizes >= 16MB (e.g., LZMA:24 = 2^24 = 16MB),
because the high byte was not read and the dictionary size defaulted
to the minimum 4096 bytes.

Change: `for i in 1..<4` → `for i in 1..<5`
2026-05-14 21:31:30 +08:00
Timofey Solomko a6419940c1 [CI] Add Swift 6.3, update iOS simulator for Swift 6.2 2026-05-14 13:21:34 +08:00
Timofey Solomko 85c8fd60aa [docs] Update BZip2 docs for multiDecompress functionality 2026-05-14 12:42:02 +08:00
Timofey Solomko cf044550f1 [swcomp] Add --multi-decompress option to bz2 command
This option allows to decompress multiple BZip2 archives concatenated together.
2026-05-14 12:42:02 +08:00
Timofey Solomko 8c389295c4 [Tests] Add tests for BZip2.multiDecompress 2026-05-14 12:42:02 +08:00
Timofey Solomko 75cc406d47 [BZip2] Add multiDecompress public function
This should help with inputs consisting of multiple BZip2 archives concatenated together which were brought up in #59.
2026-05-12 16:06:19 +08:00
Timofey Solomko 2620ed67cf Remove reference to download-bbd-macos command in README 2026-05-12 16:04:53 +08:00
Timofey Solomko e32887084c [Huffman] Change Decoding/Encoding tree to structs
This seems to have a positive impact on the performance of Deflate and BZip2 decompression and compression. It is unclear to me why these two were declared as classes in the first place.
2026-03-01 20:35:22 +08:00
Timofey Solomko 567a5473d1 [GZip] Move bytes left check out of the loop when reading extra fields 2026-03-01 20:35:22 +08:00
Timofey Solomko 5d4b4d2493 [TAR] Fix code comment to refer to TarParser instead of Provider 2026-03-01 20:35:22 +08:00
Timofey Solomko 93e2eef38d [BZip2] Remove redundant check for zero code lengths
Such code lengths are now filtered out during Huffman code construction.
2026-03-01 20:35:22 +08:00
Timofey Solomko 8310b985f2 [Tests] Add tests for all zero code lengths in Deflate dynamic Huffman block
These are related to situation described in issue #57. We should now either properly throw an error, or in rare cases (when only literals are inside the block) produce an output.
2026-03-01 20:35:22 +08:00
Timofey Solomko d8c22c55da [Deflate][Huffman] Filter out zero code lengths only during code construction
This should prevent crashes described in issue #57.
2026-03-01 20:35:21 +08:00
Timofey Solomko 7e6a9fd42c [Deflate] Add a check for correct number of literal/length codes 2026-03-01 20:35:21 +08:00
Timofey Solomko 229c3ec47d [Tests] Add Deflate tests for handling over copying in dynamic Huffman blocks 2026-03-01 20:35:21 +08:00
Timofey Solomko a39011a00b [Deflate] Fix potential crashes in cases of too large copy amount
In a dynamic Huffman block if either previous or zero code length is copied too many times, it could cause a crash or lead to inconsistent state. These situations are checked now.
2026-03-01 20:35:21 +08:00
Timofey Solomko 7f547c20a1 [Huffman] Optimize DecodingTree leaf count 2026-03-01 20:35:21 +08:00
Timofey Solomko 567878fce5 [CI] Update to Xcode 26.3 2026-03-01 20:35:21 +08:00
Timofey Solomko 07d30d6045 [Tests] Add a test for symbol 16 issue in Deflate 2026-03-01 20:35:21 +08:00
Timofey Solomko ccf97c995b [Deflate] Check that 16 is not the first code length symbol
This symbol in the dynamic Huffman block encodes copy of the previous code length. If this symbol is the first, then there is nothing to copy. Previously, this could cause a crash.
2026-02-28 01:26:43 +08:00
Timofey Solomko 3bfb4a1fa2 [Tests] Simplify Deflate truncation test 2026-02-28 01:26:43 +08:00
Timofey Solomko b743b0b7ed [Deflate] Optimize decoding of code lengths for dynamic trees 2026-02-26 00:53:17 +08:00
Timofey Solomko 80177155c8 [Tests] Move deflate truncation testing into a separate file
Also add test files that contain only "deflated" data.
2026-02-26 00:25:24 +08:00
Timofey Solomko 08e10e8c45 [Tests] Add a more comprehensive GZip truncation test 2026-02-25 23:44:41 +08:00
Timofey Solomko fd42e30262 [Tests] Add a more comprehensive Zlib truncation test 2026-02-24 00:59:15 +08:00
Timofey Solomko 52efeef2b8 [Zlib] Improve handling of truncated inputs during decompression 2026-02-24 00:58:49 +08:00
Timofey Solomko 7b366f7df4 [Tests] Add a more comprehensive LZ4 truncation test 2026-02-24 00:50:23 +08:00
Timofey Solomko e8c8ccb3f2 [Tests] Add a test for BZip2 truncation handling
The idea here is that BZip2.decompress should not crash for any possible truncation. It should either throw an error or produce an output (if stars align such that truncated input is still a valid BZip2 "archive").
2026-02-24 00:44:54 +08:00
Timofey Solomko f307a7fb0b [BZip2] Improve handling of truncated inputs during decompression 2026-02-23 18:08:27 +08:00
Timofey Solomko ad73d82367 [BZip2] Slightly rewrite Huffman+RUNA/B+MTF decoding
This piece of the code is now more logical, with less branching, and mirrors encoding counterpart.
2026-02-23 18:08:26 +08:00
Timofey Solomko a0c64f7f9c [Deflate] Optimize creation of uncompressed blocks 2026-02-23 18:08:26 +08:00
Timofey Solomko 51734eb8d3 [swcomp] Remove empty warmupIteration function from comp-ratio benchmarks
These functions weren't called anyway since 5e8f568f64 commit where Benchmark protocol requirement for this function acquired Double return type. In any event, skipping of warmup iteration is better controlled by the corresponding option of "benchmark run" command.
2026-02-23 18:08:26 +08:00