2014-06-18 6 views
0
내가 VS2012를 사용하고

, CUDA 5.5 SDKCUDA __launch_bounds __() 인텔리 오류

나는 커널에 __launch_bounds__()를 추가하면, VS 인텔리 내가의 정의를 검색 incomplete type is not allowed

오류의 많은 미쳐 프로젝트의 컴파일이 제대로 작동

#define __launch_bounds__(...) \ 
     __annotate__(launch_bounds(__VA_ARGS__)) 

"host_defines.h"에서 발견 헤더, 단지 인텔리가 잘못

편집 : 나는 해결책을 발견했습니다

__global__ void kernel(int* result, int* input){} //fine 
__global__ void __launch_bounds__(256, 8) kernel(int* result, int* input){} //intellisense error 

답변

2

CUDA 커널의 예는

#ifdef __CUDACC__ 
    #define L(x,y) __launch_bounds__(x,y) 
#else 
    #define L(x,y) 
#endif 

__global__ void L(256, 8) kernel(int* result, int* input){} 

이 인텔리 문제없이 잘 컴파일