]>
git.ipfire.org Git - thirdparty/zstd.git/log
Yann Collet [Thu, 16 Jan 2025 00:31:00 +0000 (16:31 -0800)]
fixed zlib test
new versions of the library generate a different error code
Yann Collet [Thu, 16 Jan 2025 00:05:42 +0000 (16:05 -0800)]
zlib-wrapper: separate test components to better understand what is failing
Yann Collet [Wed, 15 Jan 2025 23:52:27 +0000 (15:52 -0800)]
update installed lib64gcc version
Yann Collet [Wed, 15 Jan 2025 23:39:20 +0000 (15:39 -0800)]
short-test-1: separate tests, giving each a name
to better observe where the problem might be
Yann Collet [Wed, 15 Jan 2025 23:28:23 +0000 (15:28 -0800)]
fixed cmake-build-and-test-check
missing the liblzma library
Yann Collet [Wed, 15 Jan 2025 23:24:27 +0000 (15:24 -0800)]
fix make-external-compressors "only-lzma" test
missing the liblzma-dev package
Yann Collet [Wed, 15 Jan 2025 23:15:27 +0000 (15:15 -0800)]
fix meson-linux build test
missing the liblzma package
Yann Collet [Wed, 15 Jan 2025 22:49:45 +0000 (14:49 -0800)]
fix clang-pgo test
Yann Collet [Tue, 14 Jan 2025 22:33:25 +0000 (14:33 -0800)]
Merge pull request #4234 from MessyHack/dev
[MSVC] Wrong define checked when building for 64bit with Visual Studio
Yann Collet [Tue, 14 Jan 2025 19:12:46 +0000 (11:12 -0800)]
Merge pull request #4237 from facebook/typo_s
fixed an obvious macro name typo
Sean Bartell [Thu, 20 Jun 2024 20:52:43 +0000 (15:52 -0500)]
[contrib/pzstd] Prevent hangs when there are errors
When two threads are using a WorkQueue and the reader thread exits due
to an error, it must call WorkQueue::finish() to wake up the writer
thread. Otherwise, if the queue is full and the writer thread is waiting
for a free slot, it could hang forever.
This can happen in pratice when decompressing a large, corrupted file
that does not contain pzstd skippable frames.
Yann Collet [Mon, 13 Jan 2025 07:08:26 +0000 (23:08 -0800)]
fixed macro name typo
MessyHack [Sat, 11 Jan 2025 06:38:56 +0000 (22:38 -0800)]
should check defined(_M_X64) not defined(_M_X86) when building with MSVC.
_M_X86 is only defined under MSVC 32Bit
_M_X64 is only defined under MSVC 64Bit
Victor Zhang [Tue, 7 Jan 2025 18:06:08 +0000 (10:06 -0800)]
Merge pull request #4218 from facebook/externC
Move #includes out of `extern "C"` blocks
Yann Collet [Tue, 7 Jan 2025 17:04:57 +0000 (09:04 -0800)]
Merge pull request #4231 from sunpoet/dev
Update MANDIR for FreeBSD
Victor Zhang [Mon, 6 Jan 2025 17:26:57 +0000 (09:26 -0800)]
Merge pull request #4230 from facebook/variedOutput
Do not vary row matchfinder selection based on availability of SSE2/Neon
Po-Chuan Hsieh [Sun, 5 Jan 2025 14:26:08 +0000 (22:26 +0800)]
Update MANDIR for FreeBSD
share/man became a valid path for manpage since Jan 2020. And we
converted the whole ports tree to share/man around last March.
Victor Zhang [Fri, 3 Jan 2025 17:35:18 +0000 (09:35 -0800)]
Do not vary row matchfinder selection based on availability of SSE2/Neon
Move towards a stronger guarantee of reproducibility by removing this small difference for machines without SSE2/Neon.
The SIMD behavior is now the default for all platforms.
Nick Terrell [Fri, 20 Dec 2024 22:32:28 +0000 (17:32 -0500)]
[opt] Fix too short of match getting generated
The optimal parser with LDM enabled using minMatch > 3 could generate a match
length of 3 when minMatch >= 4. This is not allowed.
1. Fix the bug
2. Add validation logic to `ZSTD_buildSeqStore()` in debug mode for all block
compressors that checks we never generate too short a match. This way we don't
rely on the `generate_sequences` fuzzer to find this issue.
Credit to OSS-Fuzz
Victor Zhang [Fri, 3 Jan 2025 06:42:00 +0000 (22:42 -0800)]
Merge pull request #4229 from facebook/noFseek
Support for libc variants without fseeko/ftello
Victor Zhang [Thu, 2 Jan 2025 23:10:40 +0000 (15:10 -0800)]
chore: indentation alignment
Victor Zhang [Thu, 2 Jan 2025 23:05:58 +0000 (15:05 -0800)]
PR feedback
Victor Zhang [Thu, 2 Jan 2025 22:17:24 +0000 (14:17 -0800)]
Oops
Victor Zhang [Thu, 2 Jan 2025 22:02:10 +0000 (14:02 -0800)]
Support for libc variants without fseeko/ftello
Some older Android libc implementations don't support `fseeko` or `ftello`.
This commit adds a new compile-time macro `LIBC_NO_FSEEKO` as well as a usage in CMake for old Android APIs.
Yann Collet [Thu, 2 Jan 2025 18:57:49 +0000 (10:57 -0800)]
Merge pull request #4228 from facebook/skippableMagicVariant
ZSTD_getFrameHeader() for skippable frames
Yann Collet [Sun, 29 Dec 2024 22:25:33 +0000 (14:25 -0800)]
update type names
naming convention: Type names should start with a Capital letter (after the prefix)
Yann Collet [Sun, 29 Dec 2024 21:27:35 +0000 (13:27 -0800)]
Merge pull request #4227 from facebook/doc_skippableFrame
clarify documentation for Frame-level methods invoked on a skippable frame
Yann Collet [Sun, 29 Dec 2024 20:26:04 +0000 (12:26 -0800)]
improve ZSTD_getFrameHeader on skippable frames
now reports:
- the header size
- the magic variant (within @dictID field)
Yann Collet [Sun, 29 Dec 2024 10:35:53 +0000 (02:35 -0800)]
clarify doc on Frame-level methods when invoked on a skippable frame
following discussion at #4226
Yann Collet [Thu, 26 Dec 2024 19:41:44 +0000 (11:41 -0800)]
Merge pull request #4217 from facebook/ZSTD_compressSequencesAndLiterals
ZSTD_compressSequencesAndLiterals
Yann Collet [Tue, 24 Dec 2024 05:15:50 +0000 (21:15 -0800)]
fixed another invalid scenario
compressSequencesAndLiterals() doesn't support sequence validation
Yann Collet [Tue, 24 Dec 2024 03:43:17 +0000 (19:43 -0800)]
add one valid test case
ZSTD_compressSequencesAndLiterals() may return a specific error code
when data to compress is non-compressible.
Yann Collet [Tue, 24 Dec 2024 02:42:51 +0000 (18:42 -0800)]
added fuzzer test for compressSequencesAndLiterals()
piggy-backing onto existing compressSequences() fuzzer test
Nick Terrell [Fri, 20 Dec 2024 17:40:32 +0000 (09:40 -0800)]
[cmake] Fix -z noexecstack portability
Summary:
Issue reported by @ryandesign and @MarcusCalhoun-Lopez.
CMake doesn't support spaces in flags. This caused older versions of gcc to
ignore the unknown flag "-z noexecstack" on MacOS since it was interpreted as a
single flag, not two separate flags. Then, during compilation it was treated as
"-z" "noexecstack", which was correctly forwarded to the linker. But the MacOS
linker does not support `-z noexecstack` so compilation failed.
The fix is to use `-Wl,-z,noexecstack`. This is never misinterpreted by a
compiler. However, not all compilers support this syntax to forward flags to the
linker. To fix this issue, we check if all the relevant `noexecstack` flags have
been successfully set, and if they haven't we disable assembly.
See also PR#4056 and PR#4061. I decided to go a different route because this is
simpler. It might not successfully set these flags on some compilers, but in that
case it also disables assembly, so they aren't required.
Test Plan:
```
mkdir build-cmake
cmake ../build/cmake/CMakeLists.txt
make -j
```
See that the linker flag is successfully detected & that assembly is enabled.
Run the same commands on MacOS which doesn't support `-Wl,-z,noexecstack` and see
that everything compiles and that `LD_FLAG_WL_Z_NOEXECSTACK` and
`ZSTD_HAS_NOEXECSTACK` are both false.
Yann Collet [Fri, 20 Dec 2024 17:03:26 +0000 (09:03 -0800)]
restore invocation of ZSTD_entropyCompressSeqStore()
in the ZSTD_compressSequences() pipeline
Yann Collet [Fri, 20 Dec 2024 00:11:46 +0000 (16:11 -0800)]
minor: use MEM_writeLE24()
so that an empty frame needs only 3 bytes of dstCapacity.
Yann Collet [Thu, 19 Dec 2024 23:55:11 +0000 (15:55 -0800)]
added parameter litCapacity
to ZSTD_compressSequencesAndLiterals()
to enforce the litCapacity >= litSize+8 condition.
Yann Collet [Thu, 19 Dec 2024 23:39:57 +0000 (15:39 -0800)]
add a check, to return an error if Sequence validation is enabled
since ZSTD_compressSequencesAndLiterals() doesn't support it.
Yann Collet [Thu, 19 Dec 2024 23:00:12 +0000 (15:00 -0800)]
fixed minor error in preparation of one fullbench scenario
Yann Collet [Thu, 19 Dec 2024 22:41:33 +0000 (14:41 -0800)]
ensure that srcSize is controlled
Yann Collet [Thu, 19 Dec 2024 17:45:28 +0000 (09:45 -0800)]
add dedicated error code for special case
ZSTD_compressSequencesAndLiterals() cannot produce an uncompressed block
Yann Collet [Thu, 19 Dec 2024 15:38:14 +0000 (07:38 -0800)]
added a test for ZSTD_compressSequencesAndLiterals
checks that srcSize is present in the frame header
and bounds the window size.
Yann Collet [Thu, 19 Dec 2024 15:26:38 +0000 (07:26 -0800)]
ZSTD_compressSequencesAndLiterals requires srcSize as parameter
this makes it possible to adjust windowSize to its tightest.
Yann Collet [Wed, 18 Dec 2024 06:27:09 +0000 (22:27 -0800)]
fixed minor error in one benchmark scenario
Yann Collet [Wed, 18 Dec 2024 06:08:43 +0000 (22:08 -0800)]
fixed minor conversion warning
Yann Collet [Wed, 18 Dec 2024 05:33:26 +0000 (21:33 -0800)]
improved speed of the Sequences converter
Yann Collet [Wed, 18 Dec 2024 01:25:57 +0000 (17:25 -0800)]
added benchmark for ZSTD_convertBlockSequences_wBlockDelim()
Yann Collet [Tue, 17 Dec 2024 22:24:29 +0000 (14:24 -0800)]
change name to ZSTD_convertSequences*()
Yann Collet [Tue, 17 Dec 2024 05:48:10 +0000 (21:48 -0800)]
attempt to silence Visual Studio warning about fopen()
Yann Collet [Tue, 17 Dec 2024 05:29:20 +0000 (21:29 -0800)]
fixed incorrect assert
Yann Collet [Tue, 17 Dec 2024 05:23:30 +0000 (21:23 -0800)]
removed fullbench-dll project from visual solutions
Yann Collet [Tue, 17 Dec 2024 05:05:24 +0000 (21:05 -0800)]
update Visual Studio solutions
Yann Collet [Tue, 17 Dec 2024 02:08:14 +0000 (18:08 -0800)]
added tests
check that ZSTD_compressAndLiterals() also controls that the `srcSize` field is exact.
Yann Collet [Tue, 17 Dec 2024 02:05:40 +0000 (18:05 -0800)]
ZSTD_compressSequencesAndLiterals() now supports multi-blocks frames.
Yann Collet [Mon, 16 Dec 2024 21:21:08 +0000 (13:21 -0800)]
change advanced parameter name: ZSTD_c_repcodeResolution
and updated its documentation.
Note: older name ZSTD_c_searchForExternalRepcodes remains supported via #define
Yann Collet [Mon, 16 Dec 2024 21:08:16 +0000 (13:08 -0800)]
minor: cleaner function parameter repcodeResolution
Yann Collet [Mon, 16 Dec 2024 20:54:52 +0000 (12:54 -0800)]
updated documentation on validateSequence
Yann Collet [Mon, 16 Dec 2024 19:39:25 +0000 (11:39 -0800)]
optimization: instantiate specialized version without Sequence checking code
results in +4% compression speed,
thanks to removal of branches in the hot loop.
Yann Collet [Mon, 16 Dec 2024 19:31:28 +0000 (11:31 -0800)]
minor optimization: only track seqPos->posInSrc when validateSequences is enabled
note: very minor saving, no performance impact
Yann Collet [Mon, 16 Dec 2024 07:07:31 +0000 (23:07 -0800)]
minor doc update
Yann Collet [Mon, 16 Dec 2024 00:14:38 +0000 (16:14 -0800)]
minor optimization for ZSTD_compressSequencesAndLiterals()
does not need to track and update internal `litPtr`.
note: does not measurably impact performance.
Yann Collet [Sun, 15 Dec 2024 07:46:21 +0000 (23:46 -0800)]
minor conversion warning fix
Yann Collet [Sun, 15 Dec 2024 07:38:18 +0000 (23:38 -0800)]
fullbench: new scenario: compressSequencesAndLiterals()
Yann Collet [Sat, 14 Dec 2024 20:34:26 +0000 (12:34 -0800)]
fullbench: switch default generator to lorem ipsum
which creates more "realistic" scenarios than former compressible noise.
The legacy data generator remains accessible,
it is triggered when requesting an explicit compressibility factor (-P#).
Yann Collet [Sat, 14 Dec 2024 01:22:19 +0000 (17:22 -0800)]
add the compressSequences() benchmark scenario
Yann Collet [Sat, 14 Dec 2024 00:23:54 +0000 (16:23 -0800)]
fullbench: preparation functions are now in charge of allocating buffers
Yann Collet [Fri, 13 Dec 2024 17:56:41 +0000 (09:56 -0800)]
minor variable renaming
Yann Collet [Fri, 13 Dec 2024 08:14:24 +0000 (00:14 -0800)]
minor: test reordering
Yann Collet [Fri, 13 Dec 2024 01:50:14 +0000 (17:50 -0800)]
refactor fullbench
to make it easier to add new scenarios
Yann Collet [Fri, 13 Dec 2024 01:29:11 +0000 (17:29 -0800)]
prepare fullbench for a refactor
Yann Collet [Thu, 12 Dec 2024 00:13:22 +0000 (16:13 -0800)]
added unit tests to ZSTD_compressSequencesAndLiterals()
seems to work as expected,
correctly control that `litSize` and `srcSize` are exactly correct.
Yann Collet [Wed, 11 Dec 2024 22:31:09 +0000 (14:31 -0800)]
produced ZSTD_compressSequencesAndLiterals() as a separate pipeline
only supports explicit delimiter mode, at least for the time being
Yann Collet [Wed, 11 Dec 2024 02:24:18 +0000 (18:24 -0800)]
minor: more accurate variable scope
Yann Collet [Wed, 11 Dec 2024 01:51:20 +0000 (17:51 -0800)]
ZSTD_SequenceCopier_f no returns the nb of bytes consumed from input
which feels much more natural
Yann Collet [Wed, 11 Dec 2024 01:07:19 +0000 (17:07 -0800)]
codemod: ZSTD_cParamMode_e -> ZSTD_CParamMode_e
Yann Collet [Wed, 11 Dec 2024 00:54:53 +0000 (16:54 -0800)]
codemod: ZSTD_paramSwitch_e -> ZSTD_ParamSwitch_e
Yann Collet [Wed, 11 Dec 2024 00:38:51 +0000 (16:38 -0800)]
minor simplification
Yann Collet [Wed, 11 Dec 2024 00:21:47 +0000 (16:21 -0800)]
fix minor artifact error in single_file_lib
Yann Collet [Wed, 11 Dec 2024 00:17:41 +0000 (16:17 -0800)]
doc: add mention of frame checksum incompatibility
for new prototype ZSTD_compressSequencesAndLiterals()
Yann Collet [Wed, 11 Dec 2024 00:08:44 +0000 (16:08 -0800)]
codemod: ZSTD_blockCompressor -> ZSTD_BlockCompressor_f
Yann Collet [Wed, 11 Dec 2024 00:04:01 +0000 (16:04 -0800)]
codemod: rawSeqStore_t -> RawSeqStore_t
Yann Collet [Wed, 11 Dec 2024 00:00:20 +0000 (16:00 -0800)]
codemod: repcodes_t -> Repcodes_t
Yann Collet [Tue, 10 Dec 2024 23:35:11 +0000 (15:35 -0800)]
codemod: ZSTD_matchState_t -> ZSTD_MatchState_t
Yann Collet [Tue, 10 Dec 2024 23:04:56 +0000 (15:04 -0800)]
codemod: ZSTD_buildSeqStore_e -> ZSTD_BuildSeqStore_e
Yann Collet [Tue, 10 Dec 2024 23:01:43 +0000 (15:01 -0800)]
codemod: ZSTD_sequencePosition -> ZSTD_SequencePosition
Yann Collet [Tue, 10 Dec 2024 22:18:39 +0000 (14:18 -0800)]
enable proper type
Yann Collet [Tue, 10 Dec 2024 22:14:07 +0000 (14:14 -0800)]
fix proper type for .forceNonContiguous
Yann Collet [Tue, 10 Dec 2024 22:11:51 +0000 (14:11 -0800)]
scope: ZSTD_copySequencesToSeqStore*() are private to ZSTD_compress.c
no need to publish them outside of this unit.
Yann Collet [Tue, 10 Dec 2024 22:02:53 +0000 (14:02 -0800)]
minor: simplify ZSTD_selectSequenceCopier
Yann Collet [Tue, 10 Dec 2024 22:00:09 +0000 (14:00 -0800)]
codemod: ZSTD_sequenceCopier -> ZSTD_SequenceCopier_f
Yann Collet [Tue, 10 Dec 2024 21:58:11 +0000 (13:58 -0800)]
codemod: ZSTD_sequenceFormat_e -> ZSTD_SequenceFormat_e
since it's a type name.
Note: in contrast with previous names, this one is on the Public API side.
So there is a #define, so that existing programs using ZSTD_sequenceFormat_e still work.
Yann Collet [Tue, 10 Dec 2024 21:33:48 +0000 (13:33 -0800)]
created ZSTD_entropyCompressSeqStore_wExtLitBuffer()
can receive externally defined buffer of literals
Yann Collet [Tue, 10 Dec 2024 20:02:44 +0000 (12:02 -0800)]
ZSTD_entropyCompressSeqStore_internal() can accept an externally defined literals buffer
Yann Collet [Tue, 10 Dec 2024 19:40:06 +0000 (11:40 -0800)]
codemod: ZSTD_defaultPolicy_e -> ZSTD_DefaultPolicy_e
Yann Collet [Tue, 10 Dec 2024 19:34:12 +0000 (11:34 -0800)]
codemod: symbolEncodingType_e -> SymbolEncodingType_e
Yann Collet [Tue, 10 Dec 2024 19:27:03 +0000 (11:27 -0800)]
codemod: ZSTD_sequenceLength -> ZSTD_SequenceLength
Yann Collet [Tue, 10 Dec 2024 19:09:52 +0000 (11:09 -0800)]
codemod: seqStore_t -> SeqStore_t
same idea, SeqStore_t is a type name, it should start with a Capital letter.
Yann Collet [Tue, 10 Dec 2024 19:06:58 +0000 (11:06 -0800)]
codemod: seqDef -> SeqDef
SeqDef is a type name, so it should start with a Capital letter.
It's an internal symbol, no impact on public API.
Yann Collet [Tue, 10 Dec 2024 19:04:25 +0000 (11:04 -0800)]
move Sequences definition to zstd_compress_internal.h
they should not be in common/zstd_internal.h,
since these definitions are not shared beyond lib/compress/.
Yann Collet [Tue, 10 Dec 2024 05:39:34 +0000 (21:39 -0800)]
created ZSTD_storeSeqOnly()
makes it possible to register a sequence without copying its literals.