Skip to content

perf(cuda): pipeline local file reads through cacheable pinned buffers - #9936

Open
0ax1 wants to merge 3 commits into
developfrom
ad/cuda-pipelined-local-reads
Open

0ax1 wants to merge 3 commits into
developfrom
ad/cuda-pipelined-local-reads

Conversation

@0ax1

@0ax1 0ax1 commented Sep 18, 2026

Copy link
Copy Markdown
Contributor

Pipeline large local CUDA reads in 4 MiB chunks, transferring completed chunks into one device allocation without waiting for the full read.

  • Use cacheable pooled pinned memory for staging.
  • Bound concurrent host reads per file and retain buffers safely through cancellation and asynchronous transfers.
  • Preserve requested byte ranges, excluding direct-I/O alignment padding from chunked transfers.
  • Add regression coverage for chunk placement, short reads, overflow, cancellation, and buffer reuse.

Signed-off-by: Alexander Droste <alexander.droste@protonmail.com>
@0ax1 0ax1 added the changelog/performance A performance improvement label Sep 18, 2026
Signed-off-by: Alexander Droste <alexander.droste@protonmail.com>
@codspeed

codspeed Bot commented Sep 18, 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.

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

⚡ 3 improved benchmarks
❌ 1 regressed benchmark
✅ 2243 untouched benchmarks
⏩ 176 skipped benchmarks1
🗄️ 1 archived benchmark run2

Warning

Please fix the performance issues or acknowledge them on CodSpeed.

Performance Changes

Mode Benchmark BASE HEAD Efficiency
WallTime arrow_checked_add_u32_neon[16384] 12.9 µs 20.3 µs -36.5%
Simulation decode_primitives[f32, (1000, 512)] 64.7 µs 42.5 µs +52.26%
Simulation decompress[u64, (4000, 1024)] 87.1 µs 71.6 µs +21.8%
Simulation allocate_drop_bytes[0] 635.5 ns 527.2 ns +20.55%

Tip

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


Comparing ad/cuda-pipelined-local-reads (314f2df) with develop (75b6225)

Open in CodSpeed

Footnotes

  1. 176 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.

  2. 1 benchmark was run, but is now archived. If it was deleted in another branch, consider rebasing to remove it from the report. Instead if it was added back, click here to restore it.

Signed-off-by: Alexander Droste <alexander.droste@protonmail.com>
@0ax1
0ax1 requested a review from myrrc September 18, 2026 13:41
@0ax1
0ax1 marked this pull request as ready for review September 18, 2026 13:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog/performance A performance improvement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant