xref: /aosp_15_r20/external/pytorch/aten/src/ATen/cuda/CUDAConfig.h.in (revision da0073e96a02ea20f0ac840b70461e3646d07c45)
1#pragma once
2
3// Test these using #if AT_CUDNN_ENABLED(), not #ifdef, so that it's
4// obvious if you forgot to include Config.h
5//    c.f. https://stackoverflow.com/questions/33759787/generating-an-error-if-checked-boolean-macro-is-not-defined
6//
7// NB: This header MUST NOT be included from other headers; it should
8// only be included from C++ files.
9#define AT_CUDNN_ENABLED() @AT_CUDNN_ENABLED@
10#define AT_CUSPARSELT_ENABLED() @AT_CUSPARSELT_ENABLED@
11#define AT_ROCM_ENABLED() @AT_ROCM_ENABLED@
12#define AT_MAGMA_ENABLED() @AT_MAGMA_ENABLED@
13
14// Needed for hipMAGMA to correctly identify implementation
15#if (AT_ROCM_ENABLED() && AT_MAGMA_ENABLED())
16#define HAVE_HIP 1
17#endif
18
19#define NVCC_FLAGS_EXTRA "@NVCC_FLAGS_EXTRA@"
20