petsc-3.14.6 2021-03-30
PetscCUDAInitializeCheck
Check if CUDA is initialized. If not, initialize it.
Synopsis
PETSC_EXTERN PetscErrorCode PetscCUDAInitializeCheck(void)
Logically collective
Notes
In PETSc lazy device initialization, PETSc calls this function right before creating the first CUDA/HIP object.
It can be used by application developers who want to lazily initialize CUDA/HIP when they start to use it (which may before a PETSc CUDA/HIP object is created.)
.seealso: PetscCUDAInitialize(), PetscHIPInitialize(), PetscHIPInitializeCheck()
Level
beginner
Location
src/sys/objects/cupminit.inc
Index of all Sys routines
Table of Contents for all manual pages
Index of all manual pages