MCPcopy Create free account
hub / github.com/QuEST-Kit/QuEST / gpu_getComputeCapability

Function gpu_getComputeCapability

quest/src/gpu/gpu_config.cpp:152–164  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

150
151
152int gpu_getComputeCapability() {
153#if COMPILE_CUDA
154 assert_gpuHasBeenBound(hasGpuBeenBound);
155
156 cudaDeviceProp props;
157 CUDA_CHECK( cudaGetDeviceProperties(&props, getBoundGpuId()) );
158 return props.major * 10 + props.minor;
159
160#else
161 error_gpuQueriedButGpuNotCompiled();
162 return -1;
163#endif
164}
165
166
167bool gpu_isGpuCompiled() {

Callers 1

Calls 3

assert_gpuHasBeenBoundFunction · 0.85
getBoundGpuIdFunction · 0.85

Tested by

no test coverage detected