You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Parquet writer: encode definition and repetition levels a group at a time #12194
The Parquet writer encodes definition and repetition levels one value at a time. RleEncoder already has a group-of-8 path (put_batch) that dictionary indices use. Routing levels through it keeps the encoded bytes identical (88/88 written files hash the same) and, on the arrow_writer benches (i7-14700, one pinned core, 5 interleaved rounds, about ±1% noise), takes less time for:
This is most of apache/datafusion-comet#6918. A few dictionary benches moved 3-11% in the default build, which looks like code placement: the same or fewer instructions, and within ±2% with one codegen unit.
I’d split it into a PR adding level-encoding and nested-writer benches, then the change. @HippoBaro does this fit with #11273?
Good point, thanks. With a whole group of 8 in hand, the encoder can see that a short repeated run is followed by literals and keep it as literals. I’ll measure decoding on the #7739 case too.
Activity
jhorstmann commentedon Nov 12, 2026
Might also help in solving #7739, if the last rle run was short and the next run is bitpacked, the short rle run could be converted to bitpacked.
JonSnow1807 commentedon Nov 12, 2026
Good point, thanks. With a whole group of 8 in hand, the encoder can see that a short repeated run is followed by literals and keep it as literals. I’ll measure decoding on the #7739 case too.
bench(parquet): add level encoding and nested writer cases (apache#12213