33 #ifndef LINALG_BACKEND_GPU_BASE_H__ 34 #define LINALG_BACKEND_GPU_BASE_H__ 36 #include <shogun/lib/config.h> 52 #define DEFINE_FOR_ALL_PTYPE(METHODNAME, Container) \ 53 METHODNAME(char, Container); \ 54 METHODNAME(uint8_t, Container); \ 55 METHODNAME(int16_t, Container); \ 56 METHODNAME(uint16_t, Container); \ 57 METHODNAME(int32_t, Container); \ 58 METHODNAME(uint32_t, Container); \ 59 METHODNAME(float32_t, Container); \ 60 METHODNAME(float64_t, Container); \ 67 #define BACKEND_GENERIC_TO_GPU(Type, Container) \ 68 virtual GPUMemoryBase<Type>* to_gpu(const Container<Type>&) const = 0;\ 72 #undef BACKEND_GENERIC_TO_GPU 79 #define BACKEND_GENERIC_FROM_GPU(Type, Container) \ 80 virtual void from_gpu(const Container<Type>&, Type* data) const = 0;\ 84 #undef BACKEND_GENERIC_FROM_GPU 86 #undef DEFINE_FOR_ALL_PTYPE 91 #endif //LINALG_BACKEND_GPU_BASE_H__
#define DEFINE_FOR_ALL_PTYPE(METHODNAME, Container)
#define BACKEND_GENERIC_TO_GPU(Type, Container)
Base interface of generic GPU linalg methods and generic GPU memory transfer methods.
#define BACKEND_GENERIC_FROM_GPU(Type, Container)
all of classes and functions are contained in the shogun namespace
Base interface of generic linalg methods and generic memory transfer methods.