summaryrefslogtreecommitdiffstats
path: root/tests/fullbench.c
diff options
context:
space:
mode:
authorYann Collet <cyan@fb.com>2022-09-08 05:50:28 (GMT)
committerYann Collet <cyan@fb.com>2022-09-08 05:50:28 (GMT)
commitcedf9cd57f142327cb3b92a574125f46975d7a48 (patch)
tree9885b7ccab26b623deca0889324ed513d4f824d2 /tests/fullbench.c
parent4de3e98ad206f6afc85bbb4268f6c3a64fc2d487 (diff)
downloadlz4-cedf9cd57f142327cb3b92a574125f46975d7a48.zip
lz4-cedf9cd57f142327cb3b92a574125f46975d7a48.tar.gz
lz4-cedf9cd57f142327cb3b92a574125f46975d7a48.tar.bz2
allocation optimization for lz4frame compression
as noted by @yixiutt, the temporary buffer inside lz4frame compression is being invalidated at end of compression, forcing it to be re-allocated at next compression job. This shouldn't be necessary. This change was introduced in #236, as a way to fix #232, but neither the issue is explained, nor why the patch fixes it. This patch revert to previous behavior, where temporary buffer is kept between compression calls. This results in a net reduction of allocation workload. Additionally, the temporary buffer should only need malloc(), not calloc(), thus saving initialization. This diff implements both changes. Long fuzzer tests will be run to ensure that no sanitizer warning get triggered. Additionally : fixed a minor ubsan warning in LZ4F_decompress().
Diffstat (limited to 'tests/fullbench.c')
0 files changed, 0 insertions, 0 deletions