Skip to content
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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot use AT_CUDA_DRIVER_CHECK from user code #98587

Open
lw opened this issue Apr 7, 2023 · 2 comments
Open

Cannot use AT_CUDA_DRIVER_CHECK from user code #98587

lw opened this issue Apr 7, 2023 · 2 comments
Labels
module: build Build system issues module: cpp-extensions Related to torch.utils.cpp_extension module: cuda Related to torch.cuda, and CUDA support in general module: internals Related to internal abstractions in c10 and ATen triaged This issue has been looked at a team member, and triaged and prioritized into an appropriate module

Comments

@lw
Copy link
Contributor

lw commented Apr 7, 2023

馃悰 Describe the bug

In my C++ extension that links against PyTorch I cannot use the AT_CUDA_DRIVER_CHECK macro to check the return code of a call to the CUDA driver API, because that macro makes use of the at::cuda::NVRTC struct which is defined in the ATen/cuda/nvrtc_stub/ATenNVRTC.h header, which doesn't get installed/shipped by PyTorch!

Versions

I'm using PyTorch 2.0.0 installed from the official conda channels (build py3.9_cuda11.7_cudnn8.5.0_0).

cc @malfet @seemethere @zou3519 @ezyang @bhosmer @smessmer @ljk53 @bdhirsh @ngimel

@zou3519 zou3519 added module: internals Related to internal abstractions in c10 and ATen triaged This issue has been looked at a team member, and triaged and prioritized into an appropriate module module: cuda Related to torch.cuda, and CUDA support in general module: build Build system issues labels Apr 10, 2023
@zou3519
Copy link
Contributor

zou3519 commented Apr 10, 2023

Hmm, we should make this better. Is it as simple as shipping that header with PyTorch?

@zou3519 zou3519 added the module: cpp-extensions Related to torch.utils.cpp_extension label Apr 10, 2023
@ezyang
Copy link
Contributor

ezyang commented Apr 11, 2023

yes, probably

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
module: build Build system issues module: cpp-extensions Related to torch.utils.cpp_extension module: cuda Related to torch.cuda, and CUDA support in general module: internals Related to internal abstractions in c10 and ATen triaged This issue has been looked at a team member, and triaged and prioritized into an appropriate module
Projects
None yet
Development

No branches or pull requests

3 participants