brintos

brintos / llvm-project-archived public Read only

0
0
Text · 546 B · 01dba44 Raw
13 lines · plain
1// RUN: %clang_cc1 %s --std=c++11 -triple nvptx -o - \2// RUN:   -verify -fcuda-is-device -fsyntax-only -verify-ignore-unexpected=note3// RUN: %clang_cc1 %s --std=c++11 -fgpu-rdc -triple nvptx -o - \4// RUN:   -verify=rdc -fcuda-is-device -fsyntax-only -verify-ignore-unexpected=note5// rdc-no-diagnostics6 7#include "Inputs/cuda.h"8 9__global__ void kernel1();10__global__ void kernel2() {11  kernel1<<<1,1>>>(); // expected-error {{kernel launch from __device__ or __global__ function requires relocatable device code (i.e. requires -fgpu-rdc)}}12}13