Home | History | Annotate | Download | only in CodeGenCUDA
      1 // RUN: %clang_cc1 %s -triple nvptx-unknown-unknown -fcuda-is-device -emit-llvm -o - | FileCheck %s
      2 
      3 #include "../SemaCUDA/cuda.h"
      4 
      5 // CHECK: define void @device_function
      6 extern "C"
      7 __device__ void device_function() {}
      8 
      9 // CHECK: define void @global_function
     10 extern "C"
     11 __global__ void global_function() {
     12   // CHECK: call void @device_function
     13   device_function();
     14 }
     15 
     16 // CHECK: !{{[0-9]+}} = metadata !{void ()* @global_function, metadata !"kernel", i32 1}
     17