- Oct 08, 2021
-
-
Nick Terrell authored
Fix underflow of `nbCompares` by switching to an `int` and comparing `nbCompares > 0`. This is a minimal fix, because I don't want to change the logic. These loops seem to be doing `nbCompares + 1` comparisons. The bug was reported by Dan Carpenter and found by Smatch static checker. https://lore.kernel.org/all/20211008063704.GA5370@kili/
-
- Oct 05, 2021
-
-
stanjo74 authored
* Limit training samples size to 2GB * simplified DISPLAYLEVEL() macro to use global vqriable instead of local. * refactored training samples loading * fixed compiler warning * addressed comments from the pull request * addressed @terrelln comments * missed some fixes * fixed type mismatch * Fixed bug passing estimated number of samples rather insted of the loaded number of samples. Changed unit conversion not to use bit-shifts. * fixed a declaration after code * fixed type conversion compile errors * fixed more type castting * fixed more type mismatching * changed sizes type to size_t * move type casting * more type cast fixes
-
- Oct 01, 2021
-
-
Yann Collet authored
Add AIX support in Makefile
-
- Sep 29, 2021
-
-
Nick Terrell authored
[contrib][linux-kernel] Add standard warnings and -Werror to CI
-
Nick Terrell authored
[contrib][linux] Fix -Wundef inside Linux kernel tree
-
Nick Terrell authored
add missing BUNDLE DESTINATION
-
sen authored
Skip most long matches in lazy hash table update
-
Denis Rouzaud authored
fixes build on iOS
-
- Sep 28, 2021
- Sep 27, 2021
-
-
Nick Terrell authored
[huf] Fix OSS-Fuzz assert
-
Felix Handte authored
Smaller code with disabled features
-
Nick Terrell authored
PR #2784 introduced a bug in the decompressor that caused some valid inputs to fail to decompress. The bitstream isn't reloaded after the 4X* loop if the number of elements remaining is small enough, causing us to read more bits than are available in the bitcontainer. This was caught by the MSAN fuzzer in OSS-Fuzz because the assembly implementation isn't used in the MSAN build. Credit to OSS-Fuzz.
-
- Sep 26, 2021
-
-
Yann Collet authored
provide correct reasons to include zstd_internal.h
-
Yann Collet authored
-
Yann Collet authored
-
Norbert Lange authored
Multiple ZSTD_createDCtx* functions call other (public) ZSTD_createDCtx* functions, this makes it harder for humans and compilers to throw out code that is not used. This farms out the logic into a static function, if a program only uses a single ZSTD_createDCtx variant, all others can be easily dropped and the remaining implementation can be specialized.
-
Norbert Lange authored
Use an helper function, which will just return 0 in case the feature is disabled. Allows constant propagation and removal of dead code.
-
Norbert Lange authored
Remove the then unneeded variables from the struct, and all accesses to them.
-
- Sep 25, 2021
-
-
Alexander Lobakin authored
Commit d7ef97a0 ("[build] Fix oss-fuzz build with the dataflow sanitizer") broke build inside Linux-kernel after 'import', as it no longer can conditionally remove ZSTD_MEMORY_SANITIZER definition from the #if DEF_A || DEF_B block. This emits -Wundef warning which can be treated as error. Split this preprocessor condition into two separate conditions to fix this. Fixes: d7ef97a0 ("[build] Fix oss-fuzz build with the dataflow sanitizer") Signed-off-by:
Alexander Lobakin <alobakin@pm.me>
-
- Sep 24, 2021
-
-
Nick Terrell authored
Test the kernel build with the standard warnings enabled so that we don't miss issues like fixed in PR #2802. Stacked on top of PR #2802 so CI passes, so it includes the fix. But, I won't merge until it is merged, so @solbjorn gets the credit for the fix.
-
Nick Terrell authored
[contrib][linux] Fix build after introducing ASM HUF implementation
-
- Sep 23, 2021
-
-
Nick Terrell authored
[lib] Make lib compatible with `-Wfall-through` excepting legacy
-
Nick Terrell authored
[build] Fix oss-fuzz build with the dataflow sanitizer
-
Nick Terrell authored
Fix typo
-
Nick Terrell authored
The dataflow sanitizer requires all code to be instrumented. We can't instrument the ASM function, so we have to disable it.
-
Yann Collet authored
minor: constify MatchState* parameter when possible
-
Abshar Mohammed Aslam authored
-
Nick Terrell authored
Switch to a macro `ZSTD_FALLTHROUGH;` instead of a comment. On supported compilers this uses an attribute, otherwise it becomes a comment. This is necessary to be compatible with clang's `-Wfall-through`, and gcc's `-Wfall-through=2` which don't support comments. Without this the linux build emits a bunch of warnings. Also add a test to CI to ensure that we don't regress.
-
Yann Collet authored
turns out, it's possible to constify MatchState* parameter in some parts of the binary tree algorithm, making it a pure read-only parameter, as opposed to a mutable state. This is supposed to be helpful for both maintenance and the compiler.
-
Alexander Lobakin authored
The mentioned path is being created/used by the 'import' rule for generating source files for Linux kernel. Signed-off-by:
Alexander Lobakin <alobakin@pm.me>
-
Alexander Lobakin authored
Commit a5f2c455 ("Huffman ASM") added a new ASM source file, but it wasn't added to the kernel Makefile despite that it received support for Huffman ASM according to the internal definitions. This leads to undefined references, as huf_decompress.o now calls those ASM functions. Add it to the list of sources when building inside the kernel tree. Kbuild can handle .S files just fine, so none additional rules needed. Fixes: a5f2c455 ("Huffman ASM") Signed-off-by:
Alexander Lobakin <alobakin@pm.me>
-
Alexander Lobakin authored
Linux 5.15 introduces a new Kconfig option, CONFIG_WERROR, which forces -Werror for the entire kernel. Current in-kernel ZSTD implementation uses functions deprecated in 1.5.0, and thus fails on -Wdeprecated-declarations. Turn this particular error into warning to be able to build the kernel with CONFIG_WERROR. I'm not disabling them completely to make sure they'll be visible and [hopefully] fixed sooner or later. Signed-off-by:
Alexander Lobakin <alobakin@pm.me>
-
sen authored
Reduce stack usage of block splitter
-
senhuang42 authored
-
Nick Terrell authored
[contrib][linux] Reduce stack usage by 80 bytes
-
Nick Terrell authored
Instead of calling `ZSTD_compress_advanced()` and `ZSTD_initCStream_advanced()`, which each take a `ZSTD_parameters` by value, use the new advanced API. Stack usage went from 2024 -> 1944.
-
Nick Terrell authored
[contrib][linux] Fix up SPDX license identifiers
-