clang/test/SemaCUDA/call-kernel-from-kernel.cu
raw| 1 | // RUN: %clang_cc1 %s --std=c++11 -triple nvptx -o - \ |
| 2 | // RUN: -verify -fcuda-is-device -fsyntax-only -verify-ignore-unexpected=note |
| 3 | |
| 4 | #include "Inputs/cuda.h" |
| 5 | |
| 6 | __global__ void kernel1(); |
| 7 | __global__ void kernel2() { |
| 8 | kernel1<<<1,1>>>(); // expected-error {{reference to __global__ function 'kernel1' in __global__ function}} |
| 9 | } |