Skip to content

coll/circ_graph: fix schedules for p > 32 - #8045

Merged
hzhou merged 3 commits into
pmodels:mainfrom
hzhou-muse:circ-graph-rsched-fix
Oct 22, 2026
Merged

hzhou merged 3 commits into
pmodels:mainfrom
hzhou-muse:circ-graph-rsched-fix

Conversation

@hzhou-muse

@hzhou-muse hzhou-muse commented Oct 22, 2026 •

Copy link
Copy Markdown
Contributor

Pull Request Description

The circ_graph broadcast schedules are wrong for many process counts above 32 (172 values of p up to 600, starting at p=33, e.g. 33, 65-73, 129-153). Processes send blocks before they have them, and sends disagree with the receivers' schedules. Both schedule generators had departed from Träff's algorithms (TOPC 2025, arXiv 2407.18004):

  • gen_rsched (Algorithms 4-5): the chosen intermediate process r' must strictly decrease from round to round, and the shortest path in range must win. Without these rules it could pick the same r' twice through different paths.
  • gen_ssched (Algorithm 6): the region-end bound e is now tracked in place of Skip[k+1], so the cases that need a lookup in the target's receive schedule are detected correctly.

After the fix, both functions match the paper's algorithms for every rank at every p ≤ 2100.

Additional change:

  • test/units/circ_graph.unit now checks every p up to 300 instead of 32.

Author Checklist

  • Provide Description
  • Commits Follow Good Practice
  • Passes All Tests
  • Contribution Agreement

🤖 Generated with Claude Code

@hzhou-muse
hzhou-muse force-pushed the circ-graph-rsched-fix branch 2 times, most recently from fb22ff1 to 5f8fc9a Compare October 22, 2026 17:10
@hzhou-muse

Copy link
Copy Markdown
Contributor Author

test:mpich/ch3/tcp

@hzhou-muse

Copy link
Copy Markdown
Contributor Author

test:mpich/ch4/ofi

gen_rsched now follows allblocks() in Traff's paper: the picked r' must
strictly decrease from round to round, and a path is backed off when the
shorter path without its last skip still falls in the range.

Previously, for some p > 32 (e.g. 33, 65-73, 129-153), it could pick
the same r' twice via different paths, or a deeper path with a smaller
baseblock, producing receive schedules that broadcast blocks a process
does not have yet.

model: Opus 5.5
gen_ssched now follows sendschedule() (Algorithm 6) in Traff's paper. It
tracks the end of the region r' is in, and uses it rather than
Skip[k+1] to decide when a send has to be looked up from the receive
schedule of the target.

Previously, for some p > 32 (e.g. 33, 65-73, 129-153), the send schedule
disagreed with the receive schedule of the target.

model: Opus 5.5
@hzhou
hzhou force-pushed the circ-graph-rsched-fix branch from 5f8fc9a to 3308166 Compare October 22, 2026 19:57
@hzhou
hzhou merged commit 348963c into pmodels:main Oct 22, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants