xref: /linux/lib/zstd/compress/zstd_compress_superblock.h (revision 03ab8e6297acd1bc0eedaa050e2a1635c576fd11)
1*e0c1b49fSNick Terrell /*
2*e0c1b49fSNick Terrell  * Copyright (c) Yann Collet, Facebook, Inc.
3*e0c1b49fSNick Terrell  * All rights reserved.
4*e0c1b49fSNick Terrell  *
5*e0c1b49fSNick Terrell  * This source code is licensed under both the BSD-style license (found in the
6*e0c1b49fSNick Terrell  * LICENSE file in the root directory of this source tree) and the GPLv2 (found
7*e0c1b49fSNick Terrell  * in the COPYING file in the root directory of this source tree).
8*e0c1b49fSNick Terrell  * You may select, at your option, one of the above-listed licenses.
9*e0c1b49fSNick Terrell  */
10*e0c1b49fSNick Terrell 
11*e0c1b49fSNick Terrell #ifndef ZSTD_COMPRESS_ADVANCED_H
12*e0c1b49fSNick Terrell #define ZSTD_COMPRESS_ADVANCED_H
13*e0c1b49fSNick Terrell 
14*e0c1b49fSNick Terrell /*-*************************************
15*e0c1b49fSNick Terrell *  Dependencies
16*e0c1b49fSNick Terrell ***************************************/
17*e0c1b49fSNick Terrell 
18*e0c1b49fSNick Terrell #include <linux/zstd.h> /* ZSTD_CCtx */
19*e0c1b49fSNick Terrell 
20*e0c1b49fSNick Terrell /*-*************************************
21*e0c1b49fSNick Terrell *  Target Compressed Block Size
22*e0c1b49fSNick Terrell ***************************************/
23*e0c1b49fSNick Terrell 
24*e0c1b49fSNick Terrell /* ZSTD_compressSuperBlock() :
25*e0c1b49fSNick Terrell  * Used to compress a super block when targetCBlockSize is being used.
26*e0c1b49fSNick Terrell  * The given block will be compressed into multiple sub blocks that are around targetCBlockSize. */
27*e0c1b49fSNick Terrell size_t ZSTD_compressSuperBlock(ZSTD_CCtx* zc,
28*e0c1b49fSNick Terrell                                void* dst, size_t dstCapacity,
29*e0c1b49fSNick Terrell                                void const* src, size_t srcSize,
30*e0c1b49fSNick Terrell                                unsigned lastBlock);
31*e0c1b49fSNick Terrell 
32*e0c1b49fSNick Terrell #endif /* ZSTD_COMPRESS_ADVANCED_H */
33