1 #pragma once 2 3 #include <petscmacros.h> 4 #include <petscdevice_cuda.h> 5 #include <petscdevice_hip.h> 6 7 /* MANSEC = Sys */ 8 9 #if PetscDefined(USING_HCC) && PetscDefined(USING_NVCC) 10 #error using both nvcc and hipcc at the same time? 11 #endif 12 13 #if PetscDefined(HAVE_CUDA) || PetscDefined(HAVE_HIP) 14 #define PETSC_HAVE_CUPM 1 15 #endif 16 17 #if PetscDefined(USING_NVCC) || PetscDefined(USING_HCC) 18 #define PETSC_USING_CUPMCC 1 19 #endif 20