Skip to content

refactor: store bitpacked chunk widths in a child - #9939

Draft
mhk197 wants to merge 1 commit into
mk/bitpacked-stack-02-cpu-layoutfrom
mk/bitpacked-stack-03-width-child
Draft

mhk197 wants to merge 1 commit into
mk/bitpacked-stack-02-cpu-layoutfrom
mk/bitpacked-stack-03-width-child

Conversation

@mhk197

@mhk197 mhk197 commented Sep 18, 2026

Copy link
Copy Markdown
Contributor

Replace the in-memory scalar width with a non-nullable u8 child. Uniform encoders use a constant child; bulk kernels prepare the layout once per operation. V1 serialization omits the child. Update callers and CUDA's Rust adapters; CUDA continues to accept only uniform widths.

Part 3/9 of the bitpacked-v2 stack (700 added + removed lines). Merge in order; each draft targets the preceding branch, starting from develop.

123456789

Validation: All 6 focused plugin, serde, and chunk-layout tests passed on this commit, including the regression that rejects direct vtable serde. Changed Rust files were formatted with nightly; git diff --check passed.

GPU execution was not tested. CUDA validation and workspace-wide all-feature Clippy were previously blocked by the nvCOMP 5.1 SDK download in this environment.

@codspeed

codspeed Bot commented Sep 18, 2026

Copy link
Copy Markdown

Merging this PR will regress 2 benchmarks

⚠️ Unknown Walltime execution environment detected

Using the Walltime instrument on standard Hosted Runners will lead to inconsistent data.

For the most accurate results, we recommend using CodSpeed Macro Runners: bare-metal machines fine-tuned for performance measurement consistency.

⚠️ Different runtime environments detected

Some benchmarks with significant performance changes were compared across different runtime environments,
which may affect the accuracy of the results.

Open the report in CodSpeed to investigate

⚡ 3 improved benchmarks
❌ 2 regressed benchmarks
✅ 2248 untouched benchmarks
⏩ 218 skipped benchmarks1

Warning

Please fix the performance issues or acknowledge them on CodSpeed.

Performance Changes

Mode Benchmark BASE HEAD Efficiency
Simulation bitpacked_compress_u32 36.5 µs 47.1 µs -22.52%
Simulation random_i16[0.8] 79.4 µs 97.8 µs -18.85%
WallTime arrow_checked_add_u32_neon[16384] 20.4 µs 12.3 µs +66.78%
Simulation decode_primitives[f32, (1000, 512)] 64.2 µs 42 µs +52.92%
Simulation random_i8[0.5] 96 µs 72.4 µs +32.6%

Tip

Investigate this regression by commenting @codspeedbot fix this regression on this PR, or directly use the CodSpeed MCP with your agent.


Comparing mk/bitpacked-stack-03-width-child (d740f8f) with mk/bitpacked-stack-02-cpu-layout (9737c00)2

Open in CodSpeed

Footnotes

  1. 218 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

  2. No successful run was found on mk/bitpacked-stack-02-cpu-layout (7390ffe) during the generation of this report, so 64a967c was used instead as the comparison base. There might be some changes unrelated to this pull request in this report.

Signed-off-by: "Matt Katz" <mhkatz97@gmail.com>
@mhk197
mhk197 force-pushed the mk/bitpacked-stack-03-width-child branch from bcd5b9c to d740f8f Compare September 18, 2026 19:42
@mhk197
mhk197 deployed to duckdb-build September 18, 2026 19:43 — with GitHub Actions Active
@mhk197
mhk197 deployed to duckdb-build September 18, 2026 19:43 — with GitHub Actions Active
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant