Skip to content

perf(glm52): connect remote rank hosts concurrently#712

Open
Nyvo-io wants to merge 4 commits into
openinfer-project:mainfrom
Nyvo-io:perf/glm52-parallel-rank-host-663
Open

perf(glm52): connect remote rank hosts concurrently#712
Nyvo-io wants to merge 4 commits into
openinfer-project:mainfrom
Nyvo-io:perf/glm52-parallel-rank-host-663

Conversation

@Nyvo-io

@Nyvo-io Nyvo-io commented Jul 18, 2026

Copy link
Copy Markdown
Contributor

Summary

Part of #663. Connect independent remote GLM5.2 rank-hosts concurrently during startup while preserving the CLI-defined global rank order.

What changed

  • compute contiguous (host, first_rank, rank_count) spans in CLI order;
  • run all remote handshakes concurrently in a scoped thread group;
  • join every handshake before returning, and fail closed with contextual host errors;
  • rely on existing worker ownership/drop behavior to close successful connections when another host fails;
  • add CPU-only tests for rank-span ordering and the no-remote-host case.

This leaves the worker/load protocol unchanged. Local worker spawn and pinned staging remain separate follow-ups from #663.

Validation

  • git diff --check passed locally.
  • Rust formatting, compilation, Clippy, and startup timing are delegated to CI because this checkout has no local Rust toolchain and the AutoDL machine is currently offline.

Learning focus

This change exercises scoped concurrency, deterministic rank assignment, failure cleanup, and distributed inference startup critical paths.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 7a230cd986

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread openinfer-glm52/src/lib.rs Outdated
model_path: &Path,
moe_topo: Glm52MoeTopo,
first_remote_rank: usize,
) -> Result<Vec<Glm52RemoteRankWorker>> {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Qualify the remote worker return type

When building the GLM5.2 crate, this new signature refers to Glm52RemoteRankWorker without bringing it into scope; the module only imports remote::Glm52RemoteNode near the top, while the worker type remains under crate::remote. As a result, any build that includes openinfer-glm52 fails name resolution before the new startup path or tests can run; qualify this as remote::Glm52RemoteRankWorker or add it to the existing import.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in 547f4bd: the return type is now explicitly Vec<remote::Glm52RemoteRankWorker>, matching the owning module and avoiding the missing import. I also rewrote the PR commits to add valid DCO trailers without changing the tree. The new head passes all 15 checks, including Rust formatting, CPU Clippy/tests, E2E, and Qwen3 CUDA compile/Clippy. The separate EP16/32/64 startup A/B requested on the PR is still pending suitable multi-rank-host hardware.

@Nyvo-io

Nyvo-io commented Jul 18, 2026

Copy link
Copy Markdown
Contributor Author

Validation update:

  • GitHub CI run 29642085585 is fully green, including CUDA compile and CUDA Clippy.
  • AutoDL verification host is now online with an RTX 5090 D (SM 12.0); direct nightly rustfmt --edition 2024 --check openinfer-glm52/src/lib.rs passes.
  • A full cargo test -p openinfer-glm52 --lib attempt is blocked before this PR code by the host's qwen35: migrate GDN prefill to FlashInfer and retire Triton AOT where supported #691 vLLM stub environment: the stub dynamo-tokens lacks the real TokenBlock/SaltHash/PositionalLineageHash API used by kvbm-logical.
  • The host has no GLM5.2 checkpoint, so no startup A/B number is claimed. The real EP16/32/64 timing gate remains a follow-up requiring weights and multiple rank-hosts.

xiaguan commented Jul 19, 2026

Copy link
Copy Markdown
Collaborator

Do you have an end-to-end startup speedup measurement for EP16/EP32/EP64? The current CI does not exercise the GLM5.2 rank-host startup path, so green CI alone does not validate this performance change.

@github-actions

github-actions Bot commented Jul 20, 2026

Copy link
Copy Markdown

Commit attribution notice

This pull request contains commits attributed to an account other than the PR author @Nyvo-io without a verified signature from that account:

If you are mentioned above and did not take part in this pull request, please say so here. Attributing a commit to someone else normally requires that person to be involved; maintainers should treat unacknowledged attribution as a review blocker.

This check never fails the build.

CAICAIIs added 4 commits July 20, 2026 23:40
Signed-off-by: CAICAII <3360776475@qq.com>
Signed-off-by: CAICAII <3360776475@qq.com>
Signed-off-by: CAICAII <3360776475@qq.com>
Signed-off-by: CAICAII <3360776475@qq.com>
@Nyvo-io
Nyvo-io force-pushed the perf/glm52-parallel-rank-host-663 branch from 52a16d8 to 547f4bd Compare July 20, 2026 15:41
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.

3 participants