Repository navigation
fix: Cooperate while splitting cached batches - #184
Merged
osipovartem merged 1 commit intoNov 13, 2026
Merged
Conversation
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.
Summary
BatchSplitStreamoutputs consume the existing cooperative scheduling budget. They previously bypassed the upstream yield points.CooperativeStreamAPI.Targets
df55-physical-udf-instance, the runtime branch used by Rustice, rather than the diverged upstream-sync branch.Validation
cargo fmt --all--all-targets --all-features -- -D warnings./dev/rust_lint.sh, including rustdoc; repository Rust 1.97 and CI-pinned license/typo toolsper_streamandtokio_fallbackpoliciesLocal Cost Screen
Same native
MemoryStream -> cooperative -> BatchSplitStream -> drainpipeline, frozen dependency/feature graphs and explicit optimized CI profile (opt-level=1, Rust 1.99). Inputs contain 1M Int32 rows; batch size 1,024 produces 977 batches. Order, buffer sharing and metrics are checked before timing; every timed sample checks row/batch totals.Eight fixed-CPU processes follow ABBAABBA order, four per revision, with 20 warmups and 1,001 samples per case/process. Medians below are the median of four run medians; tails pool 4,004 samples per revision/case.
The cached-path tail increase is explicitly accepted as an observed cost of restoring cooperation: +5.474 us at p95 and +14.109 us at p99 in this synthetic screen. The existing 128-unit policy is retained; ordinary unsplit outputs receive no new charge and slicing/allocation behavior is unchanged.
The earlier, separately retained short cohort (two warmups, 101 samples per process) showed larger cached-tail increases: +16.92% at p95 and +33.93% at p99. The cohorts are not pooled, and attribution of every tail increment remains incomplete. Independent review accepted this narrow fairness/cancellation tradeoff. These workstation measurements establish neither a production latency bound nor a general query speedup.