Skip to content

Commit f6649ca

Browse files
author
Holger Kohr
committed
ENH: add INFINITY to CUDA kernel preamble
1 parent 80a7734 commit f6649ca

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

src/gpuarray_buffer_cuda.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -318,6 +318,10 @@ static const char CUDA_PREAMBLE[] =
318318
"#undef NAN\n"
319319
"#endif\n"
320320
"#define NAN __int_as_float(0x7fffffff)\n"
321+
"#ifdef INFINITY\n"
322+
"#undef INFINITY\n"
323+
"#endif\n"
324+
"#define INFINITY __int_as_float(0x7f800000)\n"
321325
"#define LID_0 threadIdx.x\n"
322326
"#define LID_1 threadIdx.y\n"
323327
"#define LID_2 threadIdx.z\n"

0 commit comments

Comments
 (0)