Repository navigation
[graph_trainer] Overlap HybridEP and paging across combined PP graphs - #5542
Draft
sanketpurandare wants to merge 1 commit into
Draft
sanketpurandare wants to merge 1 commit into
sanketpurandare wants to merge 1 commit into
Conversation
sanketpurandare
added this pull request to stack #5544
October 19, 2026 17:47
sanketpurandare
force-pushed
the
ep-overlap-05-graph-pp
branch
from
October 19, 2026 20:07
a0dd588 to
8a99659
Compare
sanketpurandare
force-pushed
the
ep-overlap-05-graph-pp
branch
from
October 19, 2026 23:15
8a99659 to
1890994
Compare
sanketpurandare
force-pushed
the
ep-overlap-05-graph-pp
branch
2 times, most recently
from
October 20, 2026 13:14
19f6b73 to
bdee747
Compare
Consume independent Interleaved1F1BCombined and DualPipeV F/B pairs through explicit source annotations and the shared native/paging scheduling contracts. Prefer ready complementary work after native launches, without token chunking or capacity division. Preserve positional ABI and the existing pipeline callbacks and gradient ownership. Select native varlen Flash attention with fixed document metadata for PP acceptance. Reuse native DualPipeV full/split-backward actions and exercise exact control/overlap/paging comparisons with whole-pipeline CUDA capture, actual dI/dW lifetime and device trace evidence. Extend the PP recipes and real full-CUDA regression to no activation recomputation, consuming the pager policy supplied by the earlier owning commit unchanged. Document native graph-topology-based allocator reuse for long multistream captures and remove the obsolete future-EP-composition limitation. Consume the earlier pager's live-prefix calibration fix without replacing its implementation or adding a PP-specific workaround. Extend the existing complementary-work preference to paging launches as well as EP exchanges. Consume the earlier source-aware paging issue/lifetime contract and high-priority side streams unchanged, without restricting compute resources or adding another scheduler.
sanketpurandare
force-pushed
the
ep-overlap-05-graph-pp
branch
from
October 20, 2026 17:54
bdee747 to
3e8944f
Compare
This branch has not been deployed
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.
AI-Generated Details
Prepared with Codex from the author's GraphPP multiplexing design.
Interleaved1F1BCombined uses the companion native PyTorch schedule:
pytorch/pytorch#201439
Multiplex independent forward/backward graphs without EP token chunking or
capacity division. Explicit source annotations preserve ownership and input/
output ABI. Reuse the earlier eager scheduler's native request/input validator,
tensor/mutation dependencies and paging queue contracts. Existing pipeline code
retains receives, unshards, sends, gradient accumulation and callbacks. The
earlier pager owns calibration/live-prefix handling, the no-AC policy and
source-aware paging dependencies; this PR consumes them unchanged.
Each communication launch, including paging, now yields to ready compute in
the complementary source. The shared early-launch/late-wait scheduler now
prefers launch-enabling computations over unrelated wgrad, without another
scheduler or timing heuristic. Source-aware paging order allows F/B interleaving while the
single high-priority page stream serializes freelist updates. High-priority EP
and page streams and their environment-controlled launch budgets come from the
earlier owning PRs. Compute is not SM-bounded. No new scheduling framework,
copied kernel, capacity division or paging-buffer change is added.
Native varlen Flash selects FA4 on Blackwell. Combined and DualPipeV coverage
uses real control/overlap/paging paths. DualPipeV retains its native two-stage-
per-rank V mapping, full backward for combined actions and separate dI/dW for
bubbles. dI keeps required live-ins until dW produces parameter gradients.
There is no copied schedule or patched acceptance path.
Whole-step CUDA capture includes all microbatches' distinct routing state.
Native experimental
graph_capture_record_stream_reusereleases storage onlyafter graph dependencies prove asynchronous uses joined; keep it equal in both
arms. It does not replace ownership, annotations or stream waits. The obsolete
future-EP-composition limitation is removed. DeepEP and full-graph Inductor are
outside scope; the companion PyTorch draft is unchanged by this update.
Verification
The native eager MoE graph regression passed: the final chunk0 input-gradient
combine issues before both independent expert weight-gradient GEMMs. It uses
the production tracer and mandatory graph normalization, not patched metadata.
The launch-ancestor preference is derived once from the existing annotated DAG;
no kernel, arithmetic, capacity, compute-SM policy or extra scheduler changes.
Full-CUDA SPMD no-AC, combined PP no-AC and DualPipeV paging numerical comparisons
and the packaged-runtime 16B profile must pass on this exact revision before
publication. Earlier native API/paging checks passed non-default budgets,
invalid settings, captured node priorities, grids, lifetimes and exact replay
bytes. New scale speedup or near-complete hiding is not claimed by this update.
Original source
bdee7476completed 16B 64-GPU PP runs: PP=2, DP=EP=32, TP=1,four stages per rank, 64 microbatches of 4 sequences, length 1024, no AC/SAC,
FA4, paging in both arms and full CUDA. Balanced 1x measured 1,239,218 ->
1,295,503 configured tokens/s (1.045x); real-routing balanced 8x measured
605,265 -> 660,787 (1.092x). All seven raw paired loss/norm samples matched.
Sixty steps, throughput 11-50, profiler 59-60, snapshot 60 and identical
allocator/history settings were used.
Those original traces retain substantial exposed EP/page work: forced
EP 1557.59 ms/page 304.35 ms and real EP 2650.64 ms/page 293.34 ms, rank 0 over
two full replays. They do not meet the author's 1.2x target or prove near-complete hiding.
Improved overlap-only 32/64-GPU measurements remain pending and are not inferred
from pass logs, stream IDs or older gains. Owned lint/doc hooks passed; the
untouched video typing baseline remains outside scope.