-
Notifications
You must be signed in to change notification settings - Fork 24.6k
[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
base: gh/kwen2501/191/base
Are you sure you want to change the base?
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 FailuresAs of commit 41ac62d 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.
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