-
Notifications
You must be signed in to change notification settings - Fork 25.1k
[SymmMem] Move code to where it is used #157611
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/157611
Note: Links to docs will display an error until the docs builds have been completed. ⏳ No Failures, 30 PendingAs of commit b281ab8 with merge base a6fab82 ( This comment was automatically generated by Dr. CI and updates every 15 minutes. |
// Print version | ||
int major, minor; | ||
::nvshmem_info_get_version(&major, &minor); | ||
LOG(INFO) << "NVSHMEM is available, version: " << major << "." << minor; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LOG(INFO) << "NVSHMEM is available, version: " << major << "." << minor; | |
LOG(INFO) << "NVSHMEM is available, version: " << major << '.' << minor; |
int result = (stmt); \ | ||
TORCH_CHECK( \ | ||
result == 0, \ | ||
std::string(__FILE__) + ":" + std::to_string(__LINE__) + " " + msg + \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, this string is always constructed whether the torch check fails or passes... Reformulate to c10::LazyStr or atleast fmtlib.
`maybe_initialize_env_vars` and `initialize_nvshmem_with_store` are only used in `NVSHMEMSymmetricMemory.cu`. Moving them there. cc H-Huang awgu wanchaol fegin fduwjj wz337 wconstab d4l3k [ghstack-poisoned]
@pytorchbot merge -f "CI passed; minor format change" |
Merge startedYour change will be merged immediately since you used the force (-f) flag, bypassing any CI checks (ETA: 1-5 minutes). Please use Learn more about merging in the wiki. Questions? Feedback? Please reach out to the PyTorch DevX Team |
Stack from ghstack (oldest at bottom):
maybe_initialize_env_vars
andinitialize_nvshmem_with_store
are only used inNVSHMEMSymmetricMemory.cu
. Moving them there.cc @H-Huang @awgu @wanchaol @fegin @fduwjj @wz337 @wconstab @d4l3k