Skip to content
Open
Show file tree
Hide file tree
Changes from 10 commits
Commits
Show all changes
15 commits
Select commit Hold shift + click to select a range
5663aa0
row-spine: add canonical Huffman byte codec (entropy layer foundation)
frankmcsherry Jun 17, 2026
1b0163c
row-spine: per-column compression framework (ColumnCodec / RowCodec)
frankmcsherry Jun 17, 2026
3ee798f
row-spine: wire RowCodec into DatumContainer (per-column compression)
frankmcsherry Jun 17, 2026
97919bf
row-spine: box the Huffman codec variant and charge its storage in se…
frankmcsherry Jun 17, 2026
19875d9
row-spine: add Frame-of-Reference and Dictionary column codecs
frankmcsherry Jun 17, 2026
fda70ed
compute: gate per-column compression behind enable_arrangement_column…
frankmcsherry Jun 17, 2026
db4cf16
row-spine: shorten CMP_SCRATCH static decls to satisfy rustfmt max_width
frankmcsherry Jun 17, 2026
2fde2c9
ci: register enable_arrangement_column_compression_alpha in test-flag…
frankmcsherry Jun 17, 2026
c360dd8
compute: make per-column compression flag replica-scoped
frankmcsherry Jun 18, 2026
7a0f6ea
row-spine: guard column codec against mixed arity; address review
frankmcsherry Jun 18, 2026
d75d3e4
row-spine: reuse a thread-local decode scratch on the read paths
frankmcsherry Jun 18, 2026
aef6edc
feature-benchmark: track per-column arrangement compression
frankmcsherry Jun 18, 2026
a6b0cfc
row-spine: buffer the Huffman bit reader and add a decode table
frankmcsherry Jun 18, 2026
5833fa7
row-spine: make per-column codecs cardinality-robust and merge/mid-fo…
frankmcsherry Jun 22, 2026
da903d2
feature-benchmark: drop spurious f-string in ArrangementColumnCompres…
frankmcsherry Jun 22, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions misc/python/materialize/mzcompose/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ def get_minimal_system_parameters(
"true" if version >= MzVersion.parse_mz("v0.132.0-dev") else "false"
),
"enable_alter_swap": "true",
"enable_arrangement_column_compression_alpha": "false",

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd like to see a test/nightly run with compression enabled.

"enable_arrangement_dictionary_compression_alpha": "false",
"enable_case_literal_transform": "true",
"enable_cast_elimination": "true",
Expand Down
3 changes: 3 additions & 0 deletions misc/python/materialize/parallel_workload/action.py
Original file line number Diff line number Diff line change
Expand Up @@ -1606,6 +1606,9 @@ def __init__(
self.flags_with_values["enable_arrangement_dictionary_compression_alpha"] = (
BOOLEAN_FLAG_VALUES
)
self.flags_with_values["enable_arrangement_column_compression_alpha"] = (
BOOLEAN_FLAG_VALUES
)
self.flags_with_values["enable_compute_peek_response_stash"] = (
BOOLEAN_FLAG_VALUES
)
Expand Down
13 changes: 13 additions & 0 deletions src/compute-types/src/dyncfgs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -399,6 +399,18 @@ pub const ENABLE_ARRANGEMENT_DICTIONARY_COMPRESSION_ALPHA: Config<bool> = Config
"Enable arrangement dictionary compression (alpha; not yet production-ready).",
);

/// Whether to enable per-column arrangement compression (the `RowCodec`
/// framework). Independent of, and not combined with, dictionary compression.
///
/// Replica-scoped: the per-replica-resolved value is applied to the process-global
/// `mz_row_spine::COLUMN_COMPRESSION` flag in the compute replica's `apply_worker_config`.
pub const ENABLE_ARRANGEMENT_COLUMN_COMPRESSION_ALPHA: Config<bool> = Config::new(
"enable_arrangement_column_compression_alpha",
false,
"Enable per-column arrangement compression (alpha; not yet production-ready).",
)
.scoped(ParameterScope::Replica);

/// Whether to enable the peek response stash, for sending back large peek
/// responses. The response stash will only be used for results that exceed
/// `compute_peek_response_stash_threshold_bytes`.
Expand Down Expand Up @@ -525,6 +537,7 @@ pub fn all_dyncfgs(configs: ConfigSet) -> ConfigSet {
.add(&COMPUTE_LOGICAL_BACKPRESSURE_MAX_RETAINED_CAPABILITIES)
.add(&COMPUTE_LOGICAL_BACKPRESSURE_INFLIGHT_SLACK)
.add(&ENABLE_ARRANGEMENT_DICTIONARY_COMPRESSION_ALPHA)
.add(&ENABLE_ARRANGEMENT_COLUMN_COMPRESSION_ALPHA)
.add(&ENABLE_PEEK_RESPONSE_STASH)
.add(&PEEK_RESPONSE_STASH_THRESHOLD_BYTES)
.add(&PEEK_RESPONSE_STASH_BATCH_MAX_RUNS)
Expand Down
12 changes: 12 additions & 0 deletions src/compute/src/compute_state.rs
Original file line number Diff line number Diff line change
Expand Up @@ -308,6 +308,16 @@ impl ComputeState {
std::sync::atomic::Ordering::Relaxed,
);

// Per-column arrangement compression is replica-scoped (see
// `ENABLE_ARRANGEMENT_COLUMN_COMPRESSION_ALPHA`), so its per-replica-resolved value
// arrives in `worker_config`; mirror it into the process-global flag row-spine reads at
// seal time. Safe to re-apply on every tick: each batch records its own codec, so a flip
// only affects batches sealed afterwards.
mz_row_spine::COLUMN_COMPRESSION.store(
ENABLE_ARRANGEMENT_COLUMN_COMPRESSION_ALPHA.get(config),
std::sync::atomic::Ordering::Relaxed,
);

// NB: arrangement dictionary compression is deliberately NOT applied here. Unlike the
// settings above, it is captured once at replica creation (see `handle_create_instance`
// and `InstanceConfig::arrangement_dictionary_compression`) and held fixed, so that
Expand Down Expand Up @@ -489,6 +499,8 @@ impl<'a> ActiveComputeState<'a> {
config.arrangement_dictionary_compression,
std::sync::atomic::Ordering::Relaxed,
);
// NB: per-column compression is replica-scoped and applied in `apply_worker_config`
// (called just above), not captured on `InstanceConfig`.
Comment on lines +502 to +503

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: Comment reads like a note-to-self.


if let Some(offset) = config.expiration_offset {
self.compute_state.apply_expiration_offset(offset);
Expand Down
Loading
Loading