mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[PR #1120] [CLOSED] layer split: overlap the stages' hand-off (STRATA_SPLIT_OVERLAP=1, opt-in) #3040
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#3040
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/1120
Author: @bsvinay
Created: 10/6/2026
Status: ❌ Closed
Base:
main← Head:split-overlap📝 Commits (4)
e4fc9c3layer split: overlap the stages' hand-off (STRATA_SPLIT_OVERLAP=1, opt-in)6f843d4layer split overlap: bound the GPU-side hand-off wait (STRATA_SPLIT_WAIT_MS)7d5e325layer split overlap: the hand-off publish reads the test word only with STRATA_TEST_HANDOFF_DROP setdf7ed7flayer split overlap: off beside --pipeline-windows (#859)📊 Changes
6 files changed (+330 additions, -31 deletions)
View changed files
📝
docs/MULTI_GPU.md(+28 -0)📝
include/strata/core/verify.hpp(+23 -0)📝
include/strata/kernels/verify_kernels.hpp(+11 -0)📝
src/core/verify.cpp(+169 -30)📝
src/kernels/cuda/verify_kernels.cu(+70 -0)📝
src/program/generate.cpp(+29 -1)📄 Description
Resubmitted from #936, which GitHub closed when main's history was rewritten. Same 4 commits, cherry-picked onto the new main (no conflicts). The review discussion and test results from others are in #936.
On 2x RX 7900 XTX the layer split decoded slower than one card. The cause is the order inside every verify window: stage 1 finishes, the host syncs its stream, then stages and launches stage 2's graph. Under HIP both the sync and the graph launch are expensive, and they sit on the critical path of every window while both cards are idle.
With STRATA_SPLIT_OVERLAP=1 (off by default; stages on different devices only):
handoff_publish: the payload with volatile stores (RDNA keeps plain stores to mapped memory in L2, same reason as doorbell_ring_kernel), a system fence, and the last block raises the flag;Verifier::runlaunches the next stage's window on a helper thread while it serves its own layers, and syncs the earlier stage only once the chain is done;release_gpu_waitsalso raises the hand-in flag, and an early return after the early launch releases the next stage (#267).Changes since #936 (from the review there):
Measured on 2x RX 7900 XTX (gfx1100, ROCm 10.0.0, Linux), Ryzen 9 9900X, 52 GB RAM, Swift 1.5 IQ3_XXS, 128K context, 8-bit KV, split 0-25 / 26-47, 512-token greedy answers:
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.