Skip to content

Conversation

@lyang24
Copy link
Contributor

@lyang24 lyang24 commented Jan 24, 2026

Which issue does this PR close?

  • Closes #NNN.

Rationale for this change

the Page Header of datapage v2 has num values and num nulls if all values are null we can skip setting up decoder.

What changes are included in this PR?

Are these changes tested?

Are there any user-facing changes?

no

@github-actions github-actions bot added the parquet Changes to the parquet crate label Jan 24, 2026
@lyang24 lyang24 force-pushed the datapagev2_opt1 branch 5 times, most recently from 16c49e0 to dd6fd06 Compare January 24, 2026 18:55
When a DataPageV2 has num_nulls == num_values, skip the values decoder
setup since there are no actual values to decode. This avoids unnecessary
work for all-null pages.

Also add early returns for num_values == 0 in all ColumnValueDecoder
implementations to safely handle the case when the decoder is called
with zero values (which happens when all values are null).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

parquet Changes to the parquet crate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant