Accept hints with or without "ncclx::" prefix#1016
Open
pavanbalaji wants to merge 3 commits intometa-pytorch:mainfrom
Open
Accept hints with or without "ncclx::" prefix#1016pavanbalaji wants to merge 3 commits intometa-pytorch:mainfrom
pavanbalaji wants to merge 3 commits intometa-pytorch:mainfrom
Conversation
Contributor
|
@pavanbalaji has exported this pull request. If you are a Meta employee, you can view the originating Diff in D95972681. |
3116f4e to
017c53e
Compare
Summary: Each public comm-creation API now immediately creates a guaranteed non-null internalConfigPtr (using the user-passed config or a default) and calls ncclxParseCommConfig on it. This ensures each communicator gets a freshly allocated ncclx::Config with sole ownership, preventing a double-free when callers reuse the same ncclConfig_t for multiple comms. Public APIs updated: ncclCommInitRank, ncclCommInitAll, ncclCommInitRankConfig, ncclCommInitRankScalable, ncclCommSplit, ncclCommShrink, and ncclCommGrow (v2_29). Inside ncclxParseCommConfig, assert that config is non-null and ncclxConfig is still at NCCL_CONFIG_UNDEF_PTR, rather than silently returning or doing an idempotency check. Removed ncclxParseCommConfig call from ncclCommInitChildComm (private helper) since the public caller already did it. Reviewed By: minsii Differential Revision: D95714601
Summary: Add unit tests exercising ncclxParseCommConfig, covering flat ncclConfig_t fields, hints-based configuration, default values, idempotency, and conflict detection between flat fields and hints. Applied identically to v2_27, v2_28, and v2_29. Reviewed By: minsii Differential Revision: D95714600
Summary: Strip the "ncclx::" prefix in Hints::set() and Hints::get() so that callers can use either "fastInitMode" or "ncclx::fastInitMode" interchangeably. The prefix is stripped before key matching, storage, and lookup, so the internal map always uses bare key names (compatible with ncclxParseCommConfig). Reviewed By: minsii Differential Revision: D95972681
017c53e to
d12ce55
Compare
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.
Summary:
Strip the "ncclx::" prefix in Hints::set() and Hints::get()
so that callers can use either "fastInitMode" or
"ncclx::fastInitMode" interchangeably. The prefix is
stripped before key matching, storage, and lookup, so the
internal map always uses bare key names (compatible with
ncclxParseCommConfig).
Differential Revision: D95972681