/
githubmirror
/
cmssw
Обзор
Документация
Войти
/
githubmirror
/
cmssw
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
HeterogeneousCore/CUDAUtilities/test/assert_t.cu
19 строк
544 B
Andrea Bocci
Import CUDA interaction layer from Patatrack, part 1
18 янв 2020, 01:00
18 янв 2020, 01:00
f143441
Код
Авторство
О чём код?
#include "HeterogeneousCore/CUDAUtilities/interface/cuda_assert.h" #include "HeterogeneousCore/CUDAUtilities/interface/requireDevices.h" /** * This file tests that the assert() and #include ".../cuda_assert.h" * compiles and runs when compiled with and without -DGPU_DEBUG (see * also BuildFile.xml). */ __global__ void testIt(int one) { assert(one == 1); } int main(int argc, char* argv[]) { cms::cudatest::requireDevices(); testIt<<<1, 1>>>(argc); cudaDeviceSynchronize(); return (argc == 1) ? EXIT_SUCCESS : EXIT_FAILURE; }