diff options
Diffstat (limited to 'test/SemaCUDA/implicit-intrinsic.cu')
-rw-r--r-- | test/SemaCUDA/implicit-intrinsic.cu | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/SemaCUDA/implicit-intrinsic.cu b/test/SemaCUDA/implicit-intrinsic.cu new file mode 100644 index 0000000..3d24aa7 --- /dev/null +++ b/test/SemaCUDA/implicit-intrinsic.cu @@ -0,0 +1,10 @@ +// RUN: %clang_cc1 -std=gnu++11 -triple nvptx64-unknown-unknown -fsyntax-only -verify %s + +#include "Inputs/cuda.h" + +// expected-no-diagnostics +__device__ void __threadfence_system() { + // This shouldn't produce an error, since __nvvm_membar_sys is inferred to + // be __host__ __device__ and thus callable from device code. + __nvvm_membar_sys(); +} |