Unified Memory Group Allocator
include
GroupAllocator
Helper.h
Go to the documentation of this file.
1
4
#include <cuda_runtime.h>
5
#include <cstdio>
6
7
#pragma once
8
9
namespace
groupallocator {
10
18
inline
void
gpuAssert
(cudaError_t code,
const
char
*file,
int
line,
19
bool
abort =
true
) {
20
if
(code != cudaSuccess) {
21
fprintf(stderr,
"GPUassert: %s %s %d\n"
, cudaGetErrorString(code), file,
22
line);
23
if
(abort)
24
exit(code);
25
}
26
}
27
28
}
// namespace groupallocator
29
groupallocator::gpuAssert
void gpuAssert(cudaError_t code, const char *file, int line, bool abort=true)
Definition:
Helper.h:18
Generated by
1.8.17