mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
Labels
No labels
needs-format
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Niko1221/Strata#3382
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Niko1221/Strata/pull/1323
Author: @malloc32
Created: 10/7/2026
Status: ❌ Closed
Base:
main← Head:pr/833-stager-reads📝 Commits (1)
d3659bcprefill: batched unbuffered expert reads in the stager; close the experts.bin view once reads are unbuffered📊 Changes
4 files changed (+124 additions, -19 deletions)
View changed files
📝
include/strata/core/expert_source.hpp(+12 -0)📝
src/core/expert_source.cpp(+61 -1)📝
src/prefill/prefill.cpp(+43 -18)📝
src/program/generate.cpp(+8 -0)📄 Description
AI-written. This PR was prepared by an AI (Claude Opus 5.5, via Claude Code) at the submitter's request; the code, the port and the measurements were done by the AI on the submitter's machine, and the submitter reviewed it before opening.
Update 2026-10-07: rebased onto 0.1.40.2 (
e8ca9af). The one conflict was the Stager's wait insrc/prefill/prefill.cpp: the release's sleeping wait (stager_sleep(), Linux by default) now applies to each job of a claimed run, beside the batched reads.What
A port of @adonizm's #833 onto the current
main(it was closed by the history rewrite, not rejected). Two changes:read_directbatch (ExpertSource::copy_blobs), merging neighbouring blobs into requests of up to 32 MiB.STRATA_STAGER_BATCH(default 8 for file-backed blobs, 1 otherwise).experts.binis closed (FileExpertSource::drop_mapping, Windows): while it is mapped, NTFS serves the unbuffered reads one at a time.STRATA_KEEP_MAPPING=1keeps it.Two fixes on the way:
unmapped_is declared on every platform (mapped_blobreads it outside the Windows block, so Linux did not compile), andcopy_blobsasksresident_blob, which follows the exchange rotation (STRATA_EXCHANGE_ROTATE).Measured
i7-12700K, 64 GB, 2x RTX 5060 Ti (layer split), IQ3_S,
experts.binon a Samsung 990 PRO,--resident-budget-gib 8, unbuffered reads: prompt 513 -> 623 tok/s at 8K, 962 -> 1,198 at 32K. Batching gives most of it; closing the view adds 4-5%. The original author's numbers: 1,261 -> 1,669 tok/s at 47.6K.Not tested
Linux and HIP builds (the Linux fix was checked with a syntax-only compile).
🤖 Generated with Claude Code
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.