Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add check for INVALID_ARGUMENT in NvLink checks
Unfortunately, the check to see if a link is active throws an error if an invalid linkID is passed in (instead of simply saying that the link is inactive). This causes problems since the newest nvml.h is for CUDA 11 (which has an NVML_NVLINK_MAX_LINKS of 12) and older versions had an NVML_NVLINK_MAX_LINKS of 6. This patch adds a check to see if the various calls that take a linkID fail with INVALID_ARGUMENT, and if so, silently ignore the error. This hould be OK since we are fairly confident all other arguments are valid. It would have been nice to avoid this (somewhat hacky) solution though. Signed-off-by: Kevin Klues <[email protected]>
- Loading branch information