summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaCUDA/Inputs/cuda.h
diff options
context:
space:
mode:
Diffstat (limited to 'clang/test/SemaCUDA/Inputs/cuda.h')
-rw-r--r--clang/test/SemaCUDA/Inputs/cuda.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/clang/test/SemaCUDA/Inputs/cuda.h b/clang/test/SemaCUDA/Inputs/cuda.h
index 18cafdf96af..d0546704598 100644
--- a/clang/test/SemaCUDA/Inputs/cuda.h
+++ b/clang/test/SemaCUDA/Inputs/cuda.h
@@ -21,4 +21,9 @@ typedef struct cudaStream *cudaStream_t;
int cudaConfigureCall(dim3 gridSize, dim3 blockSize, size_t sharedSize = 0,
cudaStream_t stream = 0);
+
+// Device-side placement new overloads.
+__device__ void *operator new(__SIZE_TYPE__, void *p) { return p; }
+__device__ void *operator new[](__SIZE_TYPE__, void *p) { return p; }
+
#endif // !__NVCC__
OpenPOWER on IntegriCloud