#ifndef __AMSCULIB3_HPP__ #define __AMSCULIB3_HPP__ //Std Lib Includes #include #include #include #include #include #include #include //where all the cuda functions live #include #include //Dependencies //Predeclarations class cuvect2; class cuvect3; class cuvect4; class cuvec2f; class cuvec3f; class cuvec4f; //Need a way to define the same symbols using both host and device code //A solution was found here: https://stackoverflow.com/questions/9457572/cuda-host-and-device-using-same-constant-memory #ifdef __CUDA_ARCH__ #define AMSCU_CONST __constant__ #else #define AMSCU_CONST #endif namespace amscuda { //default thread and block execution AMSCU_CONST static const int amscu_defnblocks = 256; AMSCU_CONST static const int amscu_defnthreads = 512; //default numthreads to execute on cpu AMSCU_CONST static const int amscu_defcputhreads = 8; }; //end namespace amscuda //Components #include #include #include #include #include #include #include #include #endif