FreeTensor
Loading...
Searching...
No Matches
gpu.h
Go to the documentation of this file.
1#ifndef FREE_TENSOR_GPU_H
2#define FREE_TENSOR_GPU_H
3
4#include <sstream>
5
6#ifdef FT_WITH_CUDA
7#include <cuda_runtime.h>
8
9#include <except.h>
10
11#define checkCudaError(call) \
12 { \
13 auto err = (call); \
14 if (cudaSuccess != err) { \
15 throw DriverError(cudaGetErrorString(err)); \
16 } \
17 }
18
19#endif // FT_WITH_CUDA
20
21#endif // FREE_TENSOR_GPU_H