• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 #include <torch/extension.h>
2 #include <ATen/cuda/CUDAContext.h>
3 
4 #include <cusolverDn.h>
5 
6 
noop_cusolver_function(torch::Tensor x)7 torch::Tensor noop_cusolver_function(torch::Tensor x) {
8   cusolverDnHandle_t handle;
9   TORCH_CUSOLVER_CHECK(cusolverDnCreate(&handle));
10   TORCH_CUSOLVER_CHECK(cusolverDnDestroy(handle));
11   return x;
12 }
13 
14 
PYBIND11_MODULE(TORCH_EXTENSION_NAME,m)15 PYBIND11_MODULE(TORCH_EXTENSION_NAME, m) {
16     m.def("noop_cusolver_function", &noop_cusolver_function, "a cusolver function");
17 }
18