Repository navigation
Description
Close most of the size gap between BtrBlocksCompressor and VortexCompact (Pco) on integer, timestamp, and float columns while keeping fast scans, random access, predicate pushdown, and GPU decode.
- RLE decompression fails when Delta encodes values_idx_offsets #11888 Fix
RLEdecode whenDeltaencodesvalues_idx_offsets - BitPacked take: avoid slow per-index patch search when patch density is high #11889 Faster
BitPackedtakewith many patches (Speed up medium-density takes on patched BitPacked arrays #11898) - Retire blocked BitPacked (fastlanes.bitpacked.v2) #11886 Remove
fastlanes.bitpacked.v2(Retire blocked BitPacked (fastlanes.bitpacked.v2) #11905) - Tracking Issue: Finish blocked FoR (fastlanes.for.v2) selector, residual narrowing, and kernels #11885 Finish blocked
FoR(Complete blocked FoR compute kernels and selector #11906) - Frequency-sort dictionary values in FloatDictScheme before assigning codes #11887 Sort dictionary values by frequency (Order float dictionary codes by descending value frequency #11900, Order integer and decimal dictionary codes by frequency #12044)
- Tracking Issue: Lossless float Widen and FloatWidenScheme #11883 Lossless float
Widenundervortex.widen(Support lossless float narrowing in Widen and BtrBlocks #11901) - Tracking Issue: Pow2-Bin + PIVCO integer leaf encoding (vortex.pivco) #11892
Pow2-Bin + PIVCOinteger leaf encoding (vortex.pivco, plus standaloneZigZagSpeed up ZigZag encode and decode of shared buffers #12048 andDicttakeDictionary-shaped takes decode every row of FoR, ALP and ZigZag values #12071) - Add compression levels 0-9 to the Vortex compressor #11979 Add compression levels
0..=9to the Vortex compressor -
Tracking Issue: Land Affine encoding (fastlanes.affine) and default-ready AffineScheme #11884(dropped, Add Affine integer encoding and default-ready AffineScheme #11907)Affinefor stepped and drifting integers
Results, dropped candidates, and open questions
We evaluated the full encoding portfolio across 45 datasets (13.32 GB raw, 451 leaf columns = 23 existing benchmark datasets + 22 out-of-sample spiraldb/raincloud tables) and 1M-row microbenchmarks. Full measurements are in the comments below.
Encoding tier (45 datasets, 13.32 GB raw) |
E2E Size (Ratio / vs core) |
Write (MB/s / 1T) |
Scan (E2E / Leaf GB/s) |
Random access (RA-1K / take 1% / scalar_at GM) |
GPU (CUDA) |
|---|---|---|---|---|---|
core (develop baseline) |
3,817.9 MB (3.49×) |
3,449 / 761 |
30.0 / 18.2 GB/s |
5.21 µs/row / 130.8 ms / 181 ns |
Native |
+ FoR.v2 + FloatWiden (#11906, #11901) |
3,344.5 MB (3.98×, -12.4%) |
3,082 / 667 |
27.9 / 17.5 GB/s |
5.40 µs/row / 125.8 ms / 193 ns |
Native (FoR.v2 & float Widen CUDA kernels pending) |
+ Delta + PIVCO-PH (raw bitmaps) |
3,051.9 MB* (4.36×, -20.1%) |
2,862 / 600 |
19.7 / 7.61 GB/s |
5.96 µs/row / 471.3 ms / 241 ns |
Parallel BlockScan + popc |
+ Delta + PIVCO-PHA (#11892) |
2,940.3 MB (4.53×, -23.0%) |
2,783 / 566 |
18.0 / 7.00 GB/s |
6.89 µs/row / 532.5 ms / 335 ns |
Parallel + 32-lane warp rANS |
+ Delta + vortex.rans (dropped, #11978) |
3,068.5 MB (4.34×, -19.6%) |
2,767 / 575 |
12.8 / 4.76 GB/s |
7.24 µs/row / 888.2 ms / 403 ns |
1 warp / block, LUT contention |
VortexCompact (Pco + Zstd) |
2,593.0 MB (5.14×, -32.1%) |
1,351 / 283 |
10.6 / 3.70 GB/s |
24.62 µs/row / 1,229.1 ms / 5,654 ns |
None |
*base_pivco_ph shown without Delta; with Delta, FoR.v2 + FloatWiden + Delta + PIVCO-PHA captures 71.7% of Compact (Pco + Zstd) total savings (-877.6 MB of -1,225.0 MB) while writing 2.06× faster, scanning 1.70× faster, serving 1K random access 3.57× faster, and executing scalar_at 16.9× faster (335 ns vs 5,654 ns).
Key findings
Pow2-Bin + PIVCO(Tracking Issue: Pow2-Bin + PIVCO integer leaf encoding (vortex.pivco) #11892) replacesvortex.rans(Add a rANS entropy-coded integer encoding in the unstable edition #11978): Both share the samePow2-Bin + Raw-Bitsouter split, so they compose underZigZag,FoR,ALP,Dict.codes, andDateTimeParts. Across all 45 datasets,vortex.pivcosaved66.5%more bytes thanvortex.rans(-325.9 MBvs-195.8 MBoverFoR.v2 + FloatWiden), scanned+43.6%faster (18.95vs13.20 GB/s), decoded leaves+44.9%faster (7.20vs4.97 GB/s), ran 1%filter/take1.54×–1.67×faster, achieved259 nsgeomeanscalar_atvia top-down wavelet-treeaccess(pos), and added direct bitmapcomparepushdown (PH,PHA, andOP-PHAshare onevortex.pivcowire format).- Lossless float
Widenships under existingvortex.widen(Tracking Issue: Lossless float Widen and FloatWidenScheme #11883, Support lossless float narrowing in Widen and BtrBlocks #11901): Becausepreview-2026-11is still a draft (min_library_version: None) andWidenMetadataalready encodes tag 1 as aPTypeenum, float narrowing (f64 -> f32/f16,f32 -> f16) reusesvortex.widen(ChildType::Primitive) with zero new array IDs or protobuf tags. Across the 45 datasets,FloatWidenSchemesaves-432.2 MB(-11.4%), led byOpenaiSmall50k(-278.0 MB) andraincloud'scohere-embed(-149.5 MB). - Four-encoding active portfolio (
FoR.v2, floatWiden,Delta,vortex.pivco) across compression levels0..=9(Add compression levels 0-9 to the Vortex compressor #11979):0(Fast):FoR.v2 + BitPacked + Widen + ALP + ALPRD(~3.1 GB/swrite,~28 GB/sscan).3/6(Default/Dense): addsDict + RunEnd + Sparse + FSST + Delta + vortex.pivco(includingFoR(Pivco)andALPRD.left_parts -> Pivcocascading).9(Compact): CPU-onlyPco + Zstdfor cold archival.
- Dropped candidates (verified across all 45 datasets / 451 columns):
vortex.rans(Add a rANS entropy-coded integer encoding in the unstable edition #11978): closed; strictly Pareto-dominated byvortex.pivcoboth in-sample (Existing-23) and out-of-sample (Raincloud-22).fastlanes.bitpacked.v2(Retire blocked BitPacked (fastlanes.bitpacked.v2) #11886, Retire blocked BitPacked (fastlanes.bitpacked.v2) #11905): retiring. Even a zero-cost, zero-false-positive per-column Oracle ceiling saves only-20.2 MB(-0.68%) overFoR.v2 + FloatWiden + Pivcoand-9.0 MB(-0.31%) withDelta(89%of its standalone savings are subsumed byPivco), while regressing full scans by-24%to-43%andscalar_attails by11×–38×.Affine(Tracking Issue: Land Affine encoding (fastlanes.affine) and default-ready AffineScheme #11884, Add Affine integer encoding and default-ready AffineScheme #11907): closed. OnceFoR.v2 + FloatWiden + Delta + vortex.pivcoare active (2,940.3 MB),Affinesaves only-19.2 MB(-0.65%) net across13.32 GB(~63%of which is coarses/ms-in-µstimestamps/times addressable inDateTimeParts) while slowing single-threaded encoding by-15.5%.- Earlier dropped candidates:
FloatQuant(Add pco-inspired lightweight numeric schemes #9544) andOrderedFloat.
Earlier prototypes: #9544, #10127, #10159, #10167, #10733, #11489, and #11978.
Open questions:
- Should
FoRScheme(encoded),ALPRDScheme(left_parts), andDeltabe enabled atDefault(level3) or split betweenDefault(3) andDense(6) (Tracking Issue: Finish blocked FoR (fastlanes.for.v2) selector, residual narrowing, and kernels #11885, Tracking Issue: Pow2-Bin + PIVCO integer leaf encoding (vortex.pivco) #11892, Add compression levels 0-9 to the Vortex compressor #11979)? - For dictionary-shaped takes (
DictoverFoR,ZigZag,ALP,Widen), should decoding values before gathering live centrally inTakeExecuteAdaptoror per encoding, and at what codes-to-values ratio (Dictionary-shaped takes decode every row of FoR, ALP and ZigZag values #12071)?
Activity
lwwmanning commentedon Nov 24, 2026
Posted by Claude Opus 5.5 on Will's behalf.
These are the ablation measurements that were in the bodies of this epic and its sub-issues before the bodies were shortened. The runs covered all 110 integer and temporal columns in
compress-benchand 37 float columns fromcompress-benchandvector-search(OpenaiSmall50k,GloveSmall100k). Each forced encoding was measured apart from the sample-based selector, for compressed bytes, encode and decode time,scalar_at,filterandtakeat 1%, 10%, and 50%, andcompare.Corpus totals
VortexCompact(Pco)DeltaoffFoR.v2 + Affine)scalar_at)Deltaonv1+Delta)FoR.v2 + Affine + Delta)v1+D, −24.18% vsv1Widen)OpenaiSmall50k(f64embeddings)Integers (#11884, #11885)
AffineSchemealone: 863.7 → 676.8 MB (−21.64%, −186.9 MB) withDeltaoff, and 796.1 → 656.0 MB (−17.59%, −140.1 MB) overv1 + DeltawithDeltaon.Affine: −50.5% (−137 MB). Full decode oftaxi.pickup_datetimetakes 3.42 ms, and 24.66 ms withDict. A 1%filtertakes 3.75 ms, and 0.65 ms withDict.Affine(without theoptions != FORguard): +63.4 MB net, withbimbo.Producto_ID+36.5%,bimbo.Cliente_ID+52.7%, andbimbo.Dev_uni_proxima+70.7%. Encoding is 2–5× slower.choose_moderuns 4 candidate modes × 16 sampled chunks. Encoding is 2–5× slower onbimbo.Venta_uni_hoyandeuro2016.tweeted_at.FoRScheme::v2(): 0.00% on the 97 native integer columns, and −1.03% overall.Deltaoff.euro2016.id−19.0%,airquality.pm_10−28.4%,bimbo.Dev_uni_proxima−33.4%. The penalty caused no regression on any of the 110 columns, and it prevented size regressions onhashtags.FoR.v2ontpch_lineitem.l_shipdate: 2.26× slower decode for +5 KB. WrappingRunEnd.endsmakesscalar_at10× slower onbimbo.Cliente_ID.FoR.v2with 64-bit residuals ontaxi.trip_time, where the residuals fit inu16: 2.3× slower decode thanAffine[FOR].Blocked
BitPacked(#11886)FoR.v2withDeltaoff: 828.3 → 822.4 MB (−0.70%, −5.83 MB). Gross wins of 17.16 MB, offset by 11.91 MB of selector regressions, mostlytaxi.on_scene_datetime(+11.58 MB).Deltaon: 796.7 → 795.3 MB (−0.18%, −1.41 MB).scalar_at: 1.2–4.6× slower with plainblock_offsets, and 15–35× slower (4.5–8.8 µs per probe) whenDeltaencodes them.bimbo.Venta_uni_hoygoes from 248 ns to 8,742 ns per probe, andeuro2016.idfrom 29 ns to 6,946 ns.BitPacked.v1.Floats (#11883, #11887)
Widenacross the 37 columns: 1,412.5 → 1,132.3 MB (−19.84%, −280.3 MB), which is 57.5% of the gap toPco.OpenaiSmall50k(76.8M values, 614.4 MB raw):f64ALPRD548.57 MB, 34.20 ms decode.Widen270.17 MB (−50.7%), 28.23 ms decode.Pco255.44 MB, 113.74 ms decode.FloatQuant326.40 MB.Widencaptures 95.0% of thePcogap, beatsFloatQuantby 56.23 MB (17.2%), and decodes 1.21× faster thanALPRDand 4.03× faster thanPco(M4 Max).FloatQuantalso decodes 1.30× slower thanWiden. On tabular floats with trailing mantissa zeros,ALPandDictbeat it by 15%–600%. Its secondsecondarychild saved 0.01% (91.8 KB of 4.22 GB) and brokecomparepushdown. The suite has nobf16-in-f32chunks.OrderedFloat(withFoR.v2orDelta) helps only two small 4 MBHashTagscolumns: −0.05% (−638 KB) across 1.41 GB, with 6 selector regressions. WithDelta, it wins 0 of 37 columns.Taxi.congestion_surchargedictionary: 4.79 MB asf64with 2-bit codes, 2.94 MB (−38.6%) asf32with 1-bit codes.The remaining gap to
Pco(#11892)f32-in-f64and 2 are local-drift floats (HashTags). The other 34 owe the gap to entropy coding, mostly integerPcoonALPresiduals andDictcodes.Pcois 35% to 44% smaller on those columns. Full decode takes 113.7 ms onOpenaiSmall50kand 45.1 ms onGloveSmall100k(0.3–0.6 GB/s), and a randomscalar_attakes 13–20 µs.BitPackedtake(#11889)cmsprovider.BENE_DAY_SRVC_CNT(bw=10, 147,510 patches): 10%take4.67 ms, full decode 1.76 ms, 50%take3.11 ms.food.subscribers(bw=6, 168,246 patches): 10%take3.43 ms, full decode 0.29 ms, 50%take1.08 ms.Add heavily patched medium-density BitPacked take benchmarks (#11897)
lwwmanning commentedon Nov 25, 2026
Posted with AI assistance on Will's behalf.
Phase 2 head-to-head measurements comparing
Pow2-Bin + PIVCO(vortex.pivcoinPH,PHA, andOP-PHAmodes, #11892) againstvortex.rans(with adaptiveblock_shift1,024 / 2,048 / 4,096, #11978),NoRegrets(FoR.v2#11906 +FloatDict#11900 +BitPackedtake#11898), andVortexCompact(Pco + Zstd). All runs executed sequentially in release mode on an Apple M4 Max (MiMalloc) with bit-exact round-trip verification across all 24 datasets and 182 leaf columns.24-dataset end-to-end
VortexFiletotals (11,001.5 MBraw)NoRegretsvortex.ransRA-1K(ms)Sel 1%(ms)Pred < med(ms)no_regretsrans(+ Delta + rANS)pivco_ph(+ Delta + PH)pivco_pha(+ Delta + PHA)pivco_op_pha(+ Delta + OP-PHA)compact_pcoLargest dataset differences (
PIVCO-PHAvsvortex.rans)StatPopGen(1,697.4 MBraw, 10,000 variants):223.69 MB(NoRegrets,6.4 GB/s) →171.51 MB(rANS,2.9 GB/s) →157.83 MB(PIVCO-PH,4.5 GB/s) →144.93 MB(PIVCO-PHA,4.2 GB/s, −26.58 MB vsrANS).Pco:113.73 MB(2.4 GB/s,608.6 msRA-1Kvs193.9 msPIVCO-PHA).Bimbo(3,115.6 MBraw):422.62 MB→364.68 MB(rANS,31.8 GB/s) →338.54 MB(PIVCO-PHA,43.1 GB/s, −26.14 MB vsrANS).Taxi(2,299.8 MBraw):408.84 MB→381.28 MB(rANS,54.3 GB/s) →356.81 MB(PIVCO-PHA,65.0 GB/s, −24.47 MB vsrANS).CMSprovider(687.5 MBraw):335.77 MB→290.82 MB(rANS,17.1 GB/s) →267.26 MB(PIVCO-PHA,22.5 GB/s, −23.56 MB vsrANS).Arade(435.1 MBraw):131.64 MB→131.46 MB(rANS) →127.00 MB(PIVCO-PHA, −4.46 MB).GloveSmall100k(81.6 MBraw):65.56 MB→65.56 MB(rANS) →62.00 MB(PIVCO-PHA, −3.56 MB).Food(83.5 MBraw):34.73 MB→25.85 MB(rANS,17.7 GB/s) →24.64 MB(PIVCO-PHA,30.5 GB/s, −1.21 MB).1M-row single-core microbenchmarks (
PIVCOvsvortex.ransvsPco)scalar_at(ns)filter 1%(ms)take 1%(ms)cmp == 0(GB/s)cmp < K(GB/s)GT_u64({0,1,2})rANS(b12=4K)GT_u64PIVCO-PH(b12=4K)GT_u64PIVCO-PHA(b12=4K)Skew95_u32(95% 0)rANS(b12=4K)Skew95_u32PIVCO-PHA(b12=4K)Zipf64_u32(K=8)rANS(b12=4K)Zipf64_u32PIVCO-PHA(b12=4K)Zipf64_u32PIVCO-OP-PHA(b12=4K)PL_i32(K=64)rANS(b10=1K)PL_i32rANS(b12=4K)PL_i32PIVCO-PH(b11=2K)PL_i32PIVCO-PHA(b12=4K)PL_i32PIVCO-OP-PHA(b12=4K)Geom_u32(K=8)rANS(b12=4K)Geom_u32PIVCO-PHA(b12=4K)Geom_u32PIVCO-OP-PHA(b12=4K)Laplacian_zz_i32rANS(b12=4K)Laplacian_zz_i32PIVCO-PHA(b12=4K)Speed up medium-density takes on patched BitPacked arrays (#11898)
lwwmanning commentedon Nov 26, 2026
Posted with AI assistance on Will's behalf.
Phase 3 portfolio and ablation measurements across 45 unique datasets (
13,318.3 MBraw, 451 numeric/temporal/decimal leaf columns) = 23 existing benchmark datasets (10,388.3 MBraw, 182 leaf columns) + 22 out-of-samplespiraldb/rainclouddatasets (2,930.0 MBraw, 269 leaf columns). All arms ran sequentially in--release(MiMalloc, Apple M4 Max) with bit-exact round-trip verification (10,898+checks,0failures).1. 45-Dataset Compression Ladder (
13,318.3 MBraw Part A,451leaf columns Part B)coreRA-1K(µs/row)Flt 1%(ms)Take 1%(ms)scalar_atMed / GM (ns)core(develop)core_for_v2(+ FoR.v2)base(+ FoR.v2 + FloatWiden)base_delta(+ Delta)base_rans(+ vortex.rans)base_pivco(+ vortex.pivco)base_delta_ransbase_delta_pivco(FoR.v2+Widen+Delta+Pivco)base_all_pivco(+ Affine)compact_pco(Pco + Zstd)2. Corpus Split: Existing-23 (
10.39 GB) vs Out-of-SampleRaincloud-22 (2.93 GB)Raincloud-22 Size (MB)Raincloud-22 Δ vscoreRaincloud-22 Scan / Dec (GB/s)corecore_for_v2base(+ FloatWiden)base_ransbase_pivcobase_delta_pivcobase_all_pivco(+ Affine)compact_pco3.
BitPacked.v2(#11886) Marginal & Oracle Ceiling Ablation (451 Leaf Columns, v1 Active Alongside v2)without→with + bp.v2)Σ min(w/o, w/)Raincloud/PublicBI)scalar_atGM (Adopted)core → core_bp_v2325 → 392 nsbase → base_bp_v2356 → 417 nsbase_delta → base_bp_v2_delta431 → 540 nsbase_pivco → base_bp_v2_pivco521 → 577 nsbase_all_pivco → base_all_pivco_bp_v2758 → 859 nsSpeed up ZigZag encode and decode of shared buffers (#12048)
Order float dictionary codes by descending value frequency (#11900)
Order integer and decimal dictionary codes by frequency (#12044)
Order string, binary, and streaming dictionary codes by frequency (#1…