Repository navigation
bench/shuffle: the runs on sai and their write-up (PR 5 of the plan) - #180
Merged
Merged
Conversation
bench/runlib.py holds what bench/embed/run.py's sampler did, so the shuffle runner shares it; SHUFFLE_WORKERS sets the workers of both dista programs and a local Ray's CPUs. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017TycsyUqdnuDeZrYc3z6wV
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017TycsyUqdnuDeZrYc3z6wV
A Partition's task starts only once its input's stream has ended, and the batches before it are held outside any budget, so a stream never waits for it: the read no longer leaves a slot free for it. Flows without a Partition, or with an operator in the read's group before it, are as they were. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017TycsyUqdnuDeZrYc3z6wV
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017TycsyUqdnuDeZrYc3z6wV
…ther builds Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017TycsyUqdnuDeZrYc3z6wV
The flow, the hand-written shuffle and Ray on sai, 8 and 16 workers, PARTS 16 and 64, 3 passes each, and the flow with a small store; four builds of the flow to separate the read's reserved slot from the Partition's budget. The bench's budget is now 64. Results in bench/shuffle/README.md and bench/shuffle/results/2026-11-29-sai; PR 5 marked done and the plan complete in DESIGN.md. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017TycsyUqdnuDeZrYc3z6wV
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR 5, the last PR of the plan "Keyed partitions in flows" (DESIGN.md): the measured runs on
saiand what they found. On one machine, the same group-by runs three ways: as a flow, as the hand-written dista shuffle, and on Ray. The runs cover 8 and 16 workers of one slot each, PARTS 16 and 64, 3 passes each, and a run of the flow with a small store. The results are inbench/shuffle/README.mdunder "Results", and every run is a row inbench/shuffle/results/2026-11-29-sai/runs.tsv.The bars
Partitionbudget of 64). With dista's default budget of 4 it is 1.23 to 1.40×, and before this PR it was 1.30 to 1.34×.What the gap was
Partition's budget of 4 was the larger cost. While 4 files are waiting for or running their partition task, the read opens no stream, and slots stand idle after each wave of streams ends.Changes
dista.flow: a read whose batches go straight to itsPartitionnow opens a stream on every slot.FlowRun._needs_free_slotchecks only the operators before thePartition. Flows without aPartitioncompile to what they did before. A new test intests/test_flow_partition.mojoruns such a flow on one slot; before this change it raised.-D SHUFFLE_SPLITS, default 64.SHUFFLE_WORKERSsets the worker count of both dista programs, and the CPUs of a local Ray.bench/shuffle/run.py,runs.sh,timeline.pyandsummarize.py.bench/runlib.pyisbench/embed/run.py's sampler, moved out so both runners share it.Follow-up for the maintainer to decide
Whether
Partition's default budget of 4 should be raised. A larger budget lets the read keep every slot busy. It costs memory: up to the read's streams plus the budget, counted in inputs, of batches held before the barrier. Here that raised the store's peak from 230 to 263 MB.Tested on the Mac
test_flow,test_flow_partition,flow_loss.sh,head_restart.shandtest_partition_keepall pass.🤖 Generated with Claude Code
https://claude.ai/code/session_017TycsyUqdnuDeZrYc3z6wV