Skip to content

Fix flat reader subrange decode reuse#69

Merged
lukekim merged 1 commit into
spiceai-54from
lukim/flat-buffer
Jun 25, 2026
Merged

Fix flat reader subrange decode reuse#69
lukekim merged 1 commit into
spiceai-54from
lukim/flat-buffer

Conversation

@lukekim

@lukekim lukekim commented Jun 25, 2026

Copy link
Copy Markdown

No description provided.

Signed-off-by: Luke Kim <80174+lukekim@users.noreply.github.com>
Copilot AI review requested due to automatic review settings June 25, 2026 21:03
@lukekim lukekim self-assigned this Jun 25, 2026
@lukekim lukekim added the bug Something isn't working label Jun 25, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes a performance regression in vortex-layout’s FlatReader where subrange filter/projection evaluation could trigger redundant segment requests and array decodes, by caching the decoded array future and reusing it across evaluations.

Changes:

  • Cache the decoded array future inside FlatReader using OnceLock<SharedArrayFuture> to ensure the segment is requested/decoded once per reader.
  • Add a regression test suite covering several “real query” access patterns (projection-only, filter-only, computed projections, and string filters) and asserting the segment is requested exactly once.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@lukekim
lukekim merged commit e09ec32 into spiceai-54 Jun 25, 2026
20 of 59 checks passed
@lukekim
lukekim deleted the lukim/flat-buffer branch June 25, 2026 21:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants