From 4dc6761e60552e66f176b3331bb9aaa96596795a Mon Sep 17 00:00:00 2001 From: ddidderr Date: Sun, 19 Jul 2026 10:52:42 +0200 Subject: [PATCH] docs(rust): refresh migration boundary Document the Rust-owned public end-of-frame compression orchestration and both multi-file compression scheduler boundaries, including the C callbacks that remain responsible for private file and codec operations. Test Plan: - git diff --cached --check --- rust/README.md | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/rust/README.md b/rust/README.md index 7ff2f587a..8417308c2 100644 --- a/rust/README.md +++ b/rust/README.md @@ -61,8 +61,9 @@ zstd ABI: Rust while C retains the private contexts and mutation callbacks. The public sequence APIs likewise use Rust-owned validation, frame-header, checksum, and output-accounting orchestration around C-owned block state. - The `ZSTD_compress2_c` fallback also uses a Rust-owned stable-buffer - orchestration boundary while C retains the context reset and stream adapter. + The public end-of-frame path and the `ZSTD_compress2_c` fallback also use + Rust-owned orchestration boundaries while C retains the context reset, + stream adapter, checksum/epilogue, and trace callbacks. - `zstd_compress_params` owns the compression-level tables (formerly `clevels.h`), parameter bounds, clamping, validation, table selection, source/dictionary adjustment, and match-state/CDict size estimation. @@ -118,8 +119,10 @@ zstd ABI: asynchronous-pool adapters, metadata, zstd codec/error mapping, and adaptive-policy integration, while Rust owns the mixed-format probe/dispatch loop, zstd stream-compression I/O loop, scalar adaptive decisions, - optional-format decompression loops, and decompression result policy/final - accounting. + optional-format decompression loops, decompression result policy/final + accounting, and both shared- and separate-destination multi-file + compression schedulers. C retains destination-name construction and the + private file/resource callbacks for the separate-destination path. Rust already owns the file preference policy, filename decisions, source/destination opening, dictionary buffers, asynchronous I/O pools, and pass-through copy leaf. @@ -134,16 +137,17 @@ zstd ABI: Dictionary-ingestion dispatch, CCtx dictionary/prefix attachment dispatch, the CLI zstd compression stream loop, scalar adaptive decisions, and the -shared-destination multi-file compression scheduler, +shared- and separate-destination multi-file compression schedulers, single-threaded stream initialization and the buffered/stable stream state machine, MT stream initialization, MT outer scheduling and flush policy, MT compression-job stage sequencing and error flow, public sequence-API orchestration, sequence-store and block policy, external-sequence/literals block loop, optional-format decompression loops, -block decoder wrappers, and decompression result policy now run in Rust. CDict -lifecycle, the private dictionary-content loader, reset policy, private -CCtx/matchfinder/workspace operations, and codec/adaptive-policy callbacks -remain in C. The remaining C paths must move before the rewrite is complete. +block decoder wrappers, decompression result policy, and public end-of-frame +compression orchestration now run in Rust. CDict lifecycle, the private +dictionary-content loader, reset policy, private CCtx/matchfinder/workspace +operations, and codec/adaptive-policy callbacks remain in C. The remaining C +paths must move before the rewrite is complete. Keeping that boundary explicit prevents a passing hybrid build from being mistaken for the final all-Rust result.