Remove torchcomm::<backend>:: prefix from hint keys#978
Open
pavanbalaji wants to merge 4 commits intometa-pytorch:mainfrom
Open
Remove torchcomm::<backend>:: prefix from hint keys#978pavanbalaji wants to merge 4 commits intometa-pytorch:mainfrom
pavanbalaji wants to merge 4 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 D95712701. |
3c5a501 to
9dd8710
Compare
d7eb748 to
db8c2a4
Compare
db8c2a4 to
9cecb0d
Compare
9cecb0d to
01ef064
Compare
0a1317d to
bf84d42
Compare
bf84d42 to
ace9a19
Compare
ace9a19 to
412d6e8
Compare
412d6e8 to
56dfde7
Compare
56dfde7 to
cd1f668
Compare
Summary: Move StoreManager.hpp/cpp from the top-level directory to utils/ to reflect its internal utility status. Update all include paths across backend bootstrap files and BUCK. Remove unused includes from utils/Utils.cpp. Differential Revision: D94889993
Summary: Move the internal logging utility header from the top-level torchcomms directory into utils/ alongside other utility files (Utils.hpp, StoreManager.hpp), and rename it to Logging.hpp for consistency with the project's naming conventions. Update all source files that include the header to use the new path, preserving the existing include style (double-quote, angle-bracket, and manual tag variants). Also remove unused caffe2:torch-cpp-cpu dep from tests/integration/cpp/BUCK (linter fix). Differential Revision: D94889992
Summary: Move TorchCommTracingGuard from TorchCommTracing.hpp/.cpp to utils/TracingGuard.hpp/.cpp and rename the class to TracingGuard. This matches the existing utils pattern (utils/Logging.hpp, utils/Utils.hpp, utils/StoreManager.hpp) and reflects that the class is an internal utility, not a public API. Updated include paths and class references across all backends (nccl, ncclx, rccl, rcclx, xccl, gloo, hccl, mccl). The BUCK target name torchcomms-tracing-cpp is unchanged so downstream deps are unaffected. Differential Revision: D95017391
cd1f668 to
eb7bad7
Compare
Summary: Pull Request resolved: meta-pytorch#978 A CommOptions always goes to exactly one backend, so the torchcomm::<backend>:: prefix on hint keys is unnecessary and overly verbose. This change simplifies all hint keys to bare names (e.g., "high_priority_stream" instead of "torchcomm::nccl::high_priority_stream"). The prefix-based filtering loop (starts_with + throw on unrecognized) was also a latent bug: only high_priority_stream was handled, so passing both high_priority_stream and max_event_pool_size would throw on the second key. Replace the starts_with loops in NCCL/NCCLX/RCCL/RCCLX/XCCL with direct contains() lookups, matching the pattern already used for max_event_pool_size and other keys. Add skip sets in the bootstrap populateNcclConfigFromHints functions so the TorchComm-layer keys don't trigger spurious "unsupported hint" warnings. Update all tests and documentation accordingly. No external callers use the torchcomm:: prefix -- the change is fully contained within comms/torchcomms/. Reviewed By: kapilsh Differential Revision: D95712701
eb7bad7 to
1b01ee6
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:
A CommOptions always goes to exactly one backend, so the
torchcomm:::: prefix on hint keys is unnecessary
and overly verbose. This change simplifies all hint keys to
bare names (e.g., "high_priority_stream" instead of
"torchcomm::nccl::high_priority_stream").
The prefix-based filtering loop (starts_with + throw on
unrecognized) was also a latent bug: only high_priority_stream
was handled, so passing both high_priority_stream and
max_event_pool_size would throw on the second key.
Replace the starts_with loops in NCCL/NCCLX/RCCL/RCCLX/XCCL
with direct contains() lookups, matching the pattern already
used for max_event_pool_size and other keys. Add skip sets
in the bootstrap populateNcclConfigFromHints functions so the
TorchComm-layer keys don't trigger spurious "unsupported hint"
warnings. Update all tests and documentation accordingly.
No external callers use the torchcomm:: prefix -- the change
is fully contained within comms/torchcomms/.
Differential Revision: D95712701