forked from duckdb/duckdb
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Dev] Update vendored ZSTD to v1.5.6 (duckdb#14360)
This PR was sparked by work on new compression related functionality, which made me notice that `ZDICT_trainFromBuffer_fastCover` was missing. In an attempt to add the definition for that function, I was already bringing in 6+ new files, so I figured I would spin it off in a new PR that updates the entire ZSTD library we vendor to 1.5.6 (and adds the missing function definitions + files)
- Loading branch information
Showing
77 changed files
with
27,694 additions
and
7,620 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
if(POLICY CMP0063) | ||
cmake_policy(SET CMP0063 NEW) | ||
endif() | ||
|
||
set(ZSTD_FILES | ||
compress/zstd_compress_superblock.cpp | ||
compress/zstdmt_compress.cpp | ||
compress/zstd_double_fast.cpp | ||
compress/zstd_fast.cpp | ||
compress/zstd_compress_sequences.cpp | ||
compress/zstd_ldm.cpp | ||
compress/hist.cpp | ||
compress/zstd_compress.cpp | ||
compress/zstd_lazy.cpp | ||
compress/zstd_compress_literals.cpp | ||
compress/huf_compress.cpp | ||
compress/zstd_opt.cpp | ||
compress/fse_compress.cpp | ||
decompress/zstd_ddict.cpp | ||
decompress/huf_decompress.cpp | ||
decompress/zstd_decompress.cpp | ||
decompress/zstd_decompress_block.cpp | ||
common/entropy_common.cpp | ||
common/fse_decompress.cpp | ||
common/debug.cpp | ||
common/xxhash.cpp | ||
common/pool.cpp | ||
common/threading.cpp | ||
common/zstd_common.cpp | ||
common/error_private.cpp | ||
dict/cover.cpp | ||
dict/divsufsort.cpp | ||
dict/fastcover.cpp | ||
dict/zdict.cpp | ||
deprecated/zbuff_common.cpp | ||
deprecated/zbuff_decompress.cpp | ||
deprecated/zbuff_compress.cpp | ||
) | ||
|
||
add_library(duckdb_zstd STATIC ${ZSTD_FILES}) | ||
|
||
target_include_directories( | ||
duckdb_zstd | ||
PUBLIC $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>) | ||
set_target_properties(duckdb_zstd PROPERTIES EXPORT_NAME duckdb_duckdb_zstd) | ||
|
||
install(TARGETS duckdb_zstd | ||
EXPORT "${DUCKDB_EXPORT_SET}" | ||
LIBRARY DESTINATION "${INSTALL_LIB_DIR}" | ||
ARCHIVE DESTINATION "${INSTALL_LIB_DIR}") | ||
|
||
disable_target_warnings(duckdb_zstd) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
/* ****************************************************************** | ||
* debug | ||
* Part of FSE library | ||
* Copyright (c) Meta Platforms, Inc. and affiliates. | ||
* | ||
* You can contact the author at : | ||
* - Source repository : https://github.com/Cyan4973/FiniteStateEntropy | ||
* | ||
* This source code is licensed under both the BSD-style license (found in the | ||
* LICENSE file in the root directory of this source tree) and the GPLv2 (found | ||
* in the COPYING file in the root directory of this source tree). | ||
* You may select, at your option, one of the above-listed licenses. | ||
****************************************************************** */ | ||
|
||
|
||
/* | ||
* This module only hosts one global variable | ||
* which can be used to dynamically influence the verbosity of traces, | ||
* such as DEBUGLOG and RAWLOG | ||
*/ | ||
|
||
#include "zstd/common/debug.h" | ||
|
||
#if !defined(ZSTD_LINUX_KERNEL) || (DEBUGLEVEL>=2) | ||
|
||
namespace duckdb_zstd { | ||
|
||
/* We only use this when DEBUGLEVEL>=2, but we get -Werror=pedantic errors if a | ||
* translation unit is empty. So remove this from Linux kernel builds, but | ||
* otherwise just leave it in. | ||
*/ | ||
int g_debuglevel = DEBUGLEVEL; | ||
|
||
} // namespace duckdb_zstd | ||
|
||
#endif |
Oops, something went wrong.