feat: NVLink-only topology template + microbenchmark calibration (H20 8-GPU)#277
Open
tianhao909 wants to merge 1 commit into
Open
feat: NVLink-only topology template + microbenchmark calibration (H20 8-GPU)#277tianhao909 wants to merge 1 commit into
tianhao909 wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
Pull request overview
Adds an NVLink-only topology generation path and an accompanying SimAI config preset to support reproducible single-node (8-GPU) microbenchmarks without changing existing RDMA defaults.
Changes:
- Added
--no-asw/--no-pswflags to generate an NVSwitch-only (NVLink-only) topology file fromgen_Topo_Template.py. - Added
SimAI_nvlink_only.confpreset (matchesSimAI.confexceptENABLE_QCN 0) for NVLink-only runs. - Extended
.gitignorewith additional transient-artifact patterns.
Reviewed changes
Copilot reviewed 2 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| astra-sim-alibabacloud/inputs/topo/gen_Topo_Template.py | Adds NVLink-only topology generator + CLI flags and output path support. |
| astra-sim-alibabacloud/inputs/config/SimAI_nvlink_only.conf | New preset config for NVLink-only runs (QCN disabled). |
| .gitignore | Adds ignore patterns for additional generated/transient files. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+9
to
+15
| def NVLink_Only(parameters): | ||
| if parameters['gpu'] % parameters['gpu_per_server'] != 0: | ||
| raise ValueError("NVLink-only topology requires gpu to be divisible by gpu_per_server") | ||
| servers = int(parameters['gpu'] / parameters['gpu_per_server']) | ||
| nv_switch_num = servers * parameters['nv_switch_per_server'] | ||
| nodes = parameters['gpu'] + nv_switch_num | ||
| links = parameters['gpu'] * parameters['nv_switch_per_server'] |
| def NVLink_Only(parameters): | ||
| if parameters['gpu'] % parameters['gpu_per_server'] != 0: | ||
| raise ValueError("NVLink-only topology requires gpu to be divisible by gpu_per_server") | ||
| servers = int(parameters['gpu'] / parameters['gpu_per_server']) |
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.
PR-β: NVLink-only 8-GPU topology template + config preset
Target repository:
aliyun/SimAISummary
Adds two
gen_Topo_Template.pyCLI flags (--no-asw,--no-psw) and a newSimAI_nvlink_only.confpreset, enabling reproducible single-node 8-GPU NVLink-only microbenchmarks on H20/H100 systems without changing any RDMA-path defaults. The defaultSimAI.confis left untouched so existing RDMA users are not affected.Key Changes
astra-sim-alibabacloud/inputs/topo/gen_Topo_Template.py—+53 lines--no-asw(skip aggregation-switch tier) and--no-psw(skip pod-switch tier)9 8 1 0 8 H20(meaningnodes=9 gpu_per_server=8 nv_switch_num=1 (reserved)=0 edges=8 gpu_type=H20) and 8 GPU↔NVSwitch edges (star topology: every GPU connects to the single NVSwitch; there are no GPU↔GPU direct edges)astra-sim-alibabacloud/inputs/config/SimAI_nvlink_only.conf— NEW,~66 linesSimAI.confexceptENABLE_QCN 0(QCN is RDMA-specific; NVLink-only runs should not enable it)SimAI.confis NOT modified (deliberate choice — see Reviewer FAQ).gitignore—+4 lineshousekeeping entries for common transient artefacts (*.log.tmp, generated topo dumps)Total diff: ~123 lines across 3 files, 1 commit.
Testing
Fingerprint (inline):
Topology generation smoke (runs in < 1 second, no build needed):
End-to-end microbenchmark reproduction on H20 (single node, 8× GPU, NVLink only):
7751d90879921a8854c25da21516759679038e79ca89d2402f1a252f778884c3The precision numbers above depend on operator-wise
AS_SEND_LATcalibration applied as environment variables at run time, not as source-tree values. This PR introduces no such constants into the codebase — see c1 and c3.Known Limitations
c1 — HIL verdict =
WARN-PASS. The human-in-the-loop acceptance review classified this set as PASS but with caveats documented here; it is not an unconditional acceptance.c2 — Holdout worst_err = 44.20% (Caveat tier). The 12-case holdout set (sizes/operators not used in calibration) reveals that size-axis generalization is bounded; the in-distribution 12.22% figure cannot be extrapolated without the same calibration policy.
c3 —
AS_SEND_LAT=80for AllToAll is out-of-scan. The calibration scan covered[0, 30]; theAS_SEND_LAT=80value used for AllToAll is a manual extrapolation chosen to match ground truth. It is external (env var), not in source.c4 — 2/10 cases use a split-proxy. AllReduceAllToAll as a native fused operator crashes (
exit 139) onaliyun/SimAI:master(even after the companion PR-α's UB fix, which has a different root cause). The reported results for those 2 cases use an AllReduce ∘ AllToAll split. This PR does not claim to fix the fused-op crash.c5 — Path evidence is not packet-level. Verification is at the topology header + NVLink edge count + NCCL/MockNccl-layer log level, not at ns-3 packet trace level.
Scope Disclaimer
Notes
aliyun/SimAI:master(currentlyf5efb5a)tianhao909/SimAI:pr/plan07-nvlink-topology-templatefeat: NVLink-only 8-GPU topology template + config presetrdma-hw.cc, no build-system change, no submodule bump in this PRChecklist
feat: …)SimAI.confNOT touched>blockquoteReviewer FAQ
SimAI.confdefaultENABLE_QCN=1→0?--no-asw --no-pswredundant? Why not a single--nvlink-only?--nvlink-onlyas an alias if preferred.9 8 1 0 8 H20documented?nodes=9 (8 GPU + 1 NVSwitch), gpu_per_server=8, nv_switch_num=1, (reserved)=0, edges=8, gpu_type=H20. A follow-up can add a schema block to the generator's--helpoutput if reviewers prefer.tests/topo/test_nvlink_only.pyasserting the header string plus link count== 8, i.e. the star-topology edge count). Held back from this PR to keep the diff minimal and topic-focused.