Skip to content

feat(scan): select the V2 scan from vortex-file, DataFusion and DuckDB - #10551

Draft
joseph-isaacs wants to merge 1 commit into
ji/scan-v2-3-layoutfrom
ji/scan-v2-4-wiring
Draft

joseph-isaacs wants to merge 1 commit into
ji/scan-v2-3-layoutfrom
ji/scan-v2-4-wiring

Conversation

@joseph-isaacs

Copy link
Copy Markdown
Contributor

Summary

4/5 of the V2 scan stack, stacked on #10550. Split out of #10464.

Stack:

  1. IO service (feat(file): a coalescing IO service for planning-protocol scans #10548)
  2. Planning driver (feat(scan): a planning driver for planners and morsels #10549)
  3. V2 scan in vortex-layout (feat(layout): planner-driven V2 scan over physical plans #10550)
  4. Wiring into vortex-file, DataFusion and DuckDB (this PR)
  5. Split-boundary search perf

From #10464, on a 4-core VM, DataFusion over Vortex at SF=1, V2 vs the default scan: TPC-H geomean 0.93x, TPC-DS 0.94x.

Changes

  • vortex-file.
  • DataFusion and DuckDB select V2 when it is enabled and supported. Files with list columns, and scans combining a filter with a limit, use the default executor: a list's element range is only known after its offsets are read, and pipelines are compiled before any read.
  • DuckDB can prepare later files while earlier ones scan (VORTEX_DUCKDB_FILE_PREFETCH, off by default).
  • DataFusion reports predicate and IO diagnostics.

Rebase note: develop gained #10486, which moves a DuckDB file's reader and cache into a FileScanState dropped outside the global multi-file lock. The opened VortexFile that V2 reads through now lives in that state too, so it gets the same guarantee, and a skipped file (including one skipped during prefetch) drops its state right away.

Checks run:

  • cargo clippy -p vortex-io -p vortex-scan -p vortex-layout -p vortex-file -p vortex-datafusion --all-targets --all-features -- -D warnings
  • cargo +nightly-2026-09-10 fmt --check for the changed crates
  • cargo test -p vortex-layout -p vortex-scan -p vortex-file --lib, and -p vortex-layout -p vortex-file with VORTEX_SCAN_V2=1

Not run: vortex-duckdb was not built, because its build downloads the DuckDB source and that download is blocked in this environment. The DuckDB conflict resolution with #10486 is unchecked by a compiler and needs CI.

🤖 Generated with Claude Code

https://claude.ai/code/session_01Hai26WGsNERxRHXpA3JboE


Generated by Claude Code

- vortex-file: footer open and footer prune stages, `scan_file` to describe
  a file to the scan, and end-to-end tests of the IO services.
- DataFusion and DuckDB select V2 when it is enabled and supported. Files
  with list columns, and scans combining a filter with a limit, use the
  default executor.
- DuckDB can prepare later files while earlier ones scan
  (`VORTEX_DUCKDB_FILE_PREFETCH`, off by default); DataFusion reports
  predicate and IO diagnostics.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Hai26WGsNERxRHXpA3JboE
Signed-off-by: Claude <noreply@anthropic.com>
@codspeed

codspeed Bot commented Oct 16, 2026

Copy link
Copy Markdown

Merging this PR will regress 1 benchmark

⚠️ 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.

⚠️ 1 benchmark measured no execution time

Nothing ran under measurement, usually because the compiler removed the code under test. This result is not comparable, so it counts as unchanged.

Preventing compiler optimizations

⚠️ 25 benchmarks spent significant time in system calls

System calls cannot be consistently instrumented, so they are not included in the measure, which understates the real cost. Please switch to the Walltime instrument to accurately measure system calls.

Measurement and system calls

ℹ️ 40 benchmarks have no flame graph

The flamegraph could not be generated because we failed to resolve the symbols in the profiling trace. This happens when we fail to harvest information about language frames.

⚠️ 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

⚡ 2 improved benchmarks
❌ 1 regressed benchmark
✅ 2244 untouched benchmarks
⏩ 12 skipped benchmarks1

Warning

Please fix the performance issues or acknowledge them on CodSpeed.

Performance Changes

Mode Benchmark BASE HEAD Efficiency
❌ WallTime bitpack_blocked_compress_avx2 6.8 µs 7.6 µs -11.01%
⚡ ℹ️ Simulation test_scan_filter[int] 3.4 ms 3 ms +12.79%
⚡ WallTime words_gather_dispatch_neon[65536] 2.3 µs 2 µs +10.22%

Tip

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


Comparing ji/scan-v2-4-wiring (9f5906e) with ji/scan-v2-3-layout (29f589d)

Open in CodSpeed

Footnotes

  1. 12 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. ↩

This branch has not been deployed

No deployments
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.

2 participants