Skip to content

glm cuda: warm only the selected ring neighbours (#1971) - #2126

Merged
ashhart merged 1 commit into
mainfrom
lead/t506
Nov 4, 2026
Merged

ashhart merged 1 commit into
mainfrom
lead/t506

Conversation

@ashhart

@ashhart ashhart commented Nov 4, 2026

Copy link
Copy Markdown
Owner

Refs #1971, the warm-up half only.

What this changes

At startup, GLM on CUDA posts a warm-up exchange to every other rank, while a ring only ever talks to its next and previous neighbours. On a switchless ring there's no direct link to the opposite node, so that warm-up can't complete. Startup now passes the existing ranks.Settings.ring selector into the warm-up: a ring visits only its next and previous ranks, once each at TP=2. Split and gather keep every other peer.

The 4 MiB message, buffer offsets, allocation size, stream and position before weight loading are unchanged. An opened group is ended after a failed posting, and nothing posts after it.

No new flag, relay, fabric/tp code, transport default, checkpoint arithmetic or kernel. This fixes the warm-up, not the rest of a four-node ring.

Checks, all host-only

  • 11 of 11 tests pass, four of them new fake-NCCL groups.
  • Every rank of worlds 2 to 8: wraparound, reciprocal sends and receives, unique neighbours at TP=2, unchanged direct peers. World 1 posts nothing.
  • Failure injection at GroupStart, every send and receive, and GroupEnd: every opened group closes and nothing posts after the failure.
  • Restoring the old all-peer behaviour fails two of the topology tests.
  • Lean adds nothing. The real Linux GLM open path compiles for aarch64-linux-gnu.

Not run: any ring. We have no switchless ring here, so the check on real hardware would have to come from someone who does.

@ashhart
ashhart merged commit b85fd1f into main Nov 4, 2026
8 of 11 checks passed
ashhart added a commit that referenced this pull request Nov 10, 2026
The recipe still said gather warms every peer and that there is no
switchless RoCE relay. Gather's warm-up is now one all-gather (#2569),
ring's touches only its neighbours (#2126), and TF_TP_ROCE_RELAY=1
relays gathers on a four-rank ring with no opposite links (#2352).
Add the NCCL settings the ring needs: the engine sets NCCL_CUMEM_ENABLE
and NCCL_RUNTIME_CONNECT to 0 when unset (cuda_native.zig:244,247).
ashhart added a commit that referenced this pull request Nov 10, 2026
The recipe still said gather warms every peer and that there is no
switchless RoCE relay. Gather's warm-up is now one all-gather (#2569),
ring's touches only its neighbours (#2126), and TF_TP_ROCE_RELAY=1
relays gathers on a four-rank ring with no opposite links (#2352).
Add the NCCL settings the ring needs: the engine sets NCCL_CUMEM_ENABLE
and NCCL_RUNTIME_CONNECT to 0 when unset (cuda_native.zig:244,247).
@ashhart
ashhart deleted the lead/t506 branch November 10, 2026 16:35
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.

1 participant