41constexpr uint8_t FZM_VERSION_MINOR = 1;
43 |
static_cast<uint16_t
>(FZM_VERSION_MINOR);
56 return (v <= 0xFF) ?
static_cast<uint8_t
>(v) :
static_cast<uint8_t
>(v >> 8);
60 return (v <= 0xFF) ? 0u :
static_cast<uint8_t
>(v & 0xFF);
158constexpr size_t FZM_MAX_STAGE_INPUTS = 8;
159constexpr size_t FZM_MAX_STAGE_OUTPUTS = 8;
192 std::memset(
this, 0,
sizeof(*
this));
205static_assert(
sizeof(FZMStageInfo) == 256,
"FZMStageInfo must be 256 bytes");
245 std::memset(
this, 0,
sizeof(*
this));
261static_assert(
sizeof(FZMBufferEntry) == 256,
"FZMBufferEntry must be 256 bytes");
320static_assert(
sizeof(FZMHeaderCore) == 80,
"FZMHeaderCore must be 80 bytes");
329 case DataType::UINT8:
case DataType::INT8:
return 1;
330 case DataType::UINT16:
case DataType::INT16:
return 2;
331 case DataType::UINT32:
case DataType::INT32:
case DataType::FLOAT32:
return 4;
332 case DataType::UINT64:
case DataType::INT64:
case DataType::FLOAT64:
return 8;
333 default:
throw std::runtime_error(
"Unknown data type");
340 case DataType::UINT8:
return "uint8";
341 case DataType::UINT16:
return "uint16";
342 case DataType::UINT32:
return "uint32";
343 case DataType::UINT64:
return "uint64";
344 case DataType::INT8:
return "int8";
345 case DataType::INT16:
return "int16";
346 case DataType::INT32:
return "int32";
347 case DataType::INT64:
return "int64";
348 case DataType::FLOAT32:
return "float32";
349 case DataType::FLOAT64:
return "float64";
350 default:
return "unknown";
357 case StageType::LORENZO_QUANT:
return "LorenzoQuant";
358 case StageType::DIFFERENCE:
return "Difference";
359 case StageType::SCALE:
return "Scale";
360 case StageType::PASSTHROUGH:
return "PassThrough";
361 case StageType::RLE:
return "RLE";
362 case StageType::HUFFMAN:
return "Huffman";
363 case StageType::BITPACK:
return "BitPack";
364 case StageType::SPLIT:
return "Split";
365 case StageType::MERGE:
return "Merge";
369 case StageType::QUANTIZER:
return "Quantizer";
370 case StageType::ZIGZAG:
return "Zigzag";
371 case StageType::NEGABINARY:
return "Negabinary";
372 case StageType::BITSHUFFLE:
return "Bitshuffle";
373 case StageType::RZE:
return "RZE";
380 case StageType::LORENZO:
return "Lorenzo";
394 default:
return "Unknown";
size_t getDataTypeSize(DataType type)
Definition fzm_format.h:327
constexpr uint8_t FZM_VERSION_MAJOR
Definition fzm_format.h:40
std::string dataTypeToString(DataType type)
Definition fzm_format.h:338
std::string stageTypeToString(StageType type)
Definition fzm_format.h:355
constexpr uint8_t fzmVersionMinor(uint16_t v)
Definition fzm_format.h:59
constexpr uint16_t FZM_STAGE_FLAG_PRIMARY_SOURCE
Definition fzm_format.h:78
constexpr size_t FZM_MAX_SOURCES
Maximum source stages per pipeline.
Definition fzm_format.h:66
constexpr size_t FZM_STAGE_CONFIG_SIZE
Per-stage serialized config slot (bytes)
Definition fzm_format.h:65
constexpr uint8_t fzmVersionMajor(uint16_t v)
Definition fzm_format.h:55
constexpr uint16_t FZM_FLAG_HAS_DATA_CHECKSUM
data_checksum field is valid
Definition fzm_format.h:48
constexpr uint32_t FZM_MAGIC
Definition fzm_format.h:28
StageType
Stage type identifiers written into the FZM header.
Definition fzm_format.h:88
@ TUPL
Tuple deinterleave (AoS -> SoA) transpose (LC framework lossless component)
@ SZP
SZp / fZ-light: quantize + 1-D Lorenzo delta + fixed-length bitpack. QUARANTINED experimental referen...
@ ADAPTIVE_BITPACK
Per-block adaptive fixed-rate bit-plane coder (cuSZp plain mode)
@ LOG_TRANSFORM
Log-space transform for point-wise relative bounds (Liang et al., CLUSTER'18)
@ ANS
rANS entropy coder (GPU, via dietGPU)
@ SPECK2D
GPU-parallel "wavefront" SPECK-like coder (2-D), decode-parallel format.
@ GPULZ
TODO: describe this stage.
@ RRE
Repeated-word bitmap reducer with recursive bitmap compression (LC component)
@ ROIBIN_SPLIT
Region-of-interest / binned-background split (ROIBIN-style dual-error-bound branching)
@ GOLOMB_RICE
Chunk-local Golomb-Rice entropy coder (exact per-chunk k, escape-bounded)
@ CLOG
Per-subchunk leading-zero compression and bit packing (LC framework component)
@ CDF97
CDF 9/7 biorthogonal wavelet transform (SPERR's DWT front-half)
@ TILED_LORENZO
Dimension-aware (tiled separable) Lorenzo predictor (cuSZp3 delta)
@ BITPLANE_RZE
Fused bitplane transpose + zero-group RZE (FZ-GPU lossless encoder)
@ RARE
Adaptive top-bit matching generalization of RRE (LC component)
@ SZX
SZx ultrafast EB compressor: per-block constant/non-constant classification + fixed-length residuals ...
@ ADAPTIVE_LORENZO
Per-tile adaptive multi-order Lorenzo + centering (FSZ prediction stage)
@ RAZE
Adaptive leading-zero-bit generalization of RZE (LC component)
@ CDF97_OUTLIER_CORRECT
Sparse outlier correction, guarantees the GPU SPERR pipeline's pointwise bound.
@ G_INTERP
Spline interpolation predictor + quantizer (cuSZ-Hi G-Interp)
@ FUSED_QUANT_ADAPTIVE_LORENZO
AdaptiveLorenzo with the upstream linear Quantizer fused into its forward kernel (FSZ "M1" partial fu...
@ HCLOG
CLOG bit packing with per-subchunk TCMS selection (LC framework component)
constexpr uint16_t FZM_FLAG_HAS_HEADER_CHECKSUM
header_checksum field is valid
Definition fzm_format.h:49
DataType
Element data type identifiers used in buffer and stage descriptors.
Definition fzm_format.h:142
constexpr size_t FZM_LEGACY_HEADER_CORE_SIZE
Definition fzm_format.h:46
constexpr size_t FZM_MAX_NAME_LEN
Maximum output port name length (bytes, null-terminated)
Definition fzm_format.h:64
constexpr size_t FZM_MAX_BUFFERS
Maximum pipeline output buffers per file.
Definition fzm_format.h:63
Per-buffer metadata record written into the FZM header (256 bytes).
Definition fzm_format.h:215
StageType stage_type
Producer stage type (2B)
Definition fzm_format.h:216
uint64_t data_size
Actual compressed bytes in this segment (8B)
Definition fzm_format.h:223
uint8_t producer_output_idx
Which output port of the producer (1B)
Definition fzm_format.h:219
uint64_t uncompressed_size
Bytes after fully decompressing this stage's output (8B)
Definition fzm_format.h:225
uint8_t stage_config[FZM_STAGE_CONFIG_SIZE]
Producer stage config, see Stage::serializeHeader() (128B)
Definition fzm_format.h:228
char name[FZM_MAX_NAME_LEN]
Output port name, null-terminated (64B)
Definition fzm_format.h:221
DataType data_type
Element data type in this buffer (1B)
Definition fzm_format.h:218
uint64_t allocated_size
Buffer capacity required for decompression (8B)
Definition fzm_format.h:224
uint8_t reserved2[14]
Reserved for future use (14B)
Definition fzm_format.h:231
uint32_t config_size
Valid bytes in stage_config (4B)
Definition fzm_format.h:229
uint16_t dag_buffer_id
DAG buffer ID used for inverse routing; 0xFFFF = unassigned (2B)
Definition fzm_format.h:220
uint16_t stage_version
Producer stage config version (2B)
Definition fzm_format.h:217
uint64_t byte_offset
Byte offset of this segment within the compressed payload (8B)
Definition fzm_format.h:226
Per-stage metadata record written into the FZM header (256 bytes).
Definition fzm_format.h:170
uint8_t stage_config[FZM_STAGE_CONFIG_SIZE]
Serialized stage config, see Stage::serializeHeader() (128B)
Definition fzm_format.h:180
uint8_t num_inputs
Number of input ports (1B)
Definition fzm_format.h:173
uint8_t num_outputs
Number of output ports (1B)
Definition fzm_format.h:174
StageType stage_type
Stage type (2B)
Definition fzm_format.h:171
uint8_t reserved2[84]
Reserved for future use (84B)
Definition fzm_format.h:183
uint16_t stage_flags
FZM_STAGE_FLAG_* bits; 0 on pre-flag archives (2B, was reserved1)
Definition fzm_format.h:175
uint16_t input_buffer_ids[FZM_MAX_STAGE_INPUTS]
Input buffer indices (16B); 0xFFFF = unused.
Definition fzm_format.h:177
uint16_t stage_version
Config format version (2B)
Definition fzm_format.h:172
uint32_t config_size
Valid bytes in stage_config (4B)
Definition fzm_format.h:181
uint16_t output_buffer_ids[FZM_MAX_STAGE_OUTPUTS]
Output buffer indices (16B); 0xFFFF = unused.
Definition fzm_format.h:178