====== Core.h ====== The ``Core.h`` header file defines some useful types and some macros functions to faciliate the dual CPU-CUDA compilation targets. Additionally, it introduces several classes to enable the usage of CUDA streams, kernels, and graphs. Types ===== These numeric types are defined to faciliate the special types used for CUDA, and is *necessary* to use them for functions to work properly. It is recommended to bring them into the global namespace if possible, by writing ``using namespace CudaTools::Types;``. .. doxygentypedef:: CudaTools::Types::real32 .. doxygentypedef:: CudaTools::Types::real64 .. doxygentypedef:: CudaTools::Types::complex64 .. doxygentypedef:: CudaTools::Types::complex128 These are types provided by the CUDA Math API, which cannot be easily used as computational types on host code. Take care when transferring these back to host functions, as further processing may require a type conversion. .. doxygentypedef:: CudaTools::Types::real16 .. doxygentypedef:: CudaTools::Types::realb16 Macro Definitions ================= Device Indicators ----------------- .. doxygendefine:: CUDACC .. doxygendefine:: DEVICE Host-Device Automation ---------------------- .. doxygendefine:: HD .. doxygendefine:: DEVICE_FUNC .. doxygendefine:: SHARED Compilation Options ------------------- .. doxygendefine:: CUDATOOLS_ARRAY_MAX_AXES Macro Functions =============== .. doxygendefine:: KERNEL Device Helpers -------------- .. doxygendefine:: BASIC_LOOP Device Class ------------ .. doxygendefine:: DEVICE_CLASS Memory Functions ================ .. doxygenfunction:: CudaTools::malloc .. doxygenfunction:: CudaTools::free .. doxygenfunction:: CudaTools::copy .. doxygenfunction:: CudaTools::memset .. doxygenfunction:: CudaTools::pin Streams and Handles =================== CudaTools::StreamID ------------------- .. doxygenstruct:: CudaTools::StreamID CudaTools::Manager ------------------ .. doxygenclass:: CudaTools::Manager :members: Kernels ======= .. doxygenfunction:: CudaTools::Kernel::launch .. doxygenfunction:: CudaTools::Kernel::basic CudaTools::Kernel::Settings --------------------------- .. doxygenstruct:: CudaTools::Kernel::Settings :members: Graphs ====== CudaTools::Graph ---------------- .. doxygenclass:: CudaTools::Graph :members: CudaTools::GraphManager ----------------------- .. doxygenstruct:: CudaTools::GraphManager :members: