where can I find the macro

Are there any macors in cuda?And where can I find a list of them.Such as the macors defines the maximum threads per block.

There are compiler macros defined by NVCC. These include NVCC, CUDACC, and CUDA_ARCH. These are discussed in the CUDA Compiler Driver NVCC document (http://docs.nvidia.com/cuda/cuda-compiler-driver-nvcc/index.html).

Compute capability limits such as maximum threads per blocks are queried through cudaDeviceGetAttributes and cudaGetDeviceProperties and are not available as macros. For more information see the CUDA Runtime API http://docs.nvidia.com/cuda/cuda-runtime-api/index.html#group__CUDART__DEVICE_1g1b092b57223ac999485f351c0e0f8ec8.

CUDA C Device code supports a number of built-in variables. These include gridDim, blockIdx, blockDim, threadIdx, and warpSize. These are defeind in the CUDA C Programming Guide section on Built-in Varaibles (http://docs.nvidia.com/cuda/cuda-c-programming-guide/index.html#built-in-variables).

Thank You!!