Namespaces | |
detail | |
Classes | |
struct | buffer |
A container which may or may not own its own data on host or device. More... | |
struct | bad_cuda_call |
struct | out_of_bounds |
struct | wrong_device_type |
struct | mem_type_mismatch |
struct | wrong_device |
struct | gpu_unsupported |
struct | handle_t |
Typedefs | |
using | cuda_stream = int |
template<typename T , typename U , typename V = void> | |
using | const_agnostic_same_t = std::enable_if_t< std::is_same_v< std::remove_const_t< T >, std::remove_const_t< U > >, V > |
template<typename T , bool host = !GPU_COMPILATION> | |
using | host_only_throw = detail::host_only_throw< T, host > |
template<device_type D, typename T > | |
using | non_owning_buffer = detail::non_owning_buffer< D, T > |
template<device_type D, typename T > | |
using | owning_buffer = detail::owning_buffer< D, T > |
template<device_type D> | |
using | device_id = detail::device_id< D > |
using | device_id_variant = std::variant< device_id< device_type::cpu >, device_id< device_type::gpu > > |
using | device_setter = detail::device_setter< device_type::gpu > |
Enumerations | |
enum class | device_type { cpu , gpu } |
Functions | |
template<bool bounds_check, typename T , typename U > | |
const_agnostic_same_t< T, U > | copy (buffer< T > &dst, buffer< U > const &src, typename buffer< T >::index_type dst_offset, typename buffer< U >::index_type src_offset, typename buffer< T >::index_type size, cuda_stream stream) |
template<bool bounds_check, typename T , typename U > | |
const_agnostic_same_t< T, U > | copy (buffer< T > &dst, buffer< U > const &src, cuda_stream stream) |
template<bool bounds_check, typename T , typename U > | |
const_agnostic_same_t< T, U > | copy (buffer< T > &dst, buffer< U > const &src) |
template<bool bounds_check, typename T , typename U > | |
const_agnostic_same_t< T, U > | copy (buffer< T > &&dst, buffer< U > &&src, typename buffer< T >::index_type dst_offset, typename buffer< U >::index_type src_offset, typename buffer< T >::index_type size, cuda_stream stream) |
template<bool bounds_check, typename T , typename U > | |
const_agnostic_same_t< T, U > | copy (buffer< T > &&dst, buffer< U > &&src, typename buffer< T >::index_type dst_offset, cuda_stream stream) |
template<bool bounds_check, typename T , typename U > | |
const_agnostic_same_t< T, U > | copy (buffer< T > &&dst, buffer< U > &&src, cuda_stream stream) |
template<bool bounds_check, typename T , typename U > | |
const_agnostic_same_t< T, U > | copy (buffer< T > &&dst, buffer< U > &&src) |
template<typename T , typename U > | |
HOST DEVICE constexpr auto | ceildiv (T dividend, U divisor) |
template<typename error_t > | |
void | cuda_check (error_t const &err) noexcept(!GPU_ENABLED) |
void | synchronize (cuda_stream stream) |
template<device_type dst_type, device_type src_type, typename T > | |
void | copy (T *dst, T const *src, uint32_t size, uint32_t dst_offset, uint32_t src_offset) |
template<device_type dst_type, device_type src_type, typename T > | |
void | copy (T *dst, T const *src, uint32_t size, uint32_t dst_offset, uint32_t src_offset, cuda_stream stream) |
template<device_type dst_type, device_type src_type, typename T > | |
void | copy (T *dst, T const *src, uint32_t size) |
template<device_type dst_type, device_type src_type, typename T > | |
void | copy (T *dst, T const *src, uint32_t size, cuda_stream stream) |
template<typename T > | |
void | copy (T *dst, T const *src, uint32_t size, device_type dst_type, device_type src_type, uint32_t dst_offset, uint32_t src_offset, cuda_stream stream) |
template<typename T > | |
void | copy (T *dst, T const *src, uint32_t size, device_type dst_type, device_type src_type) |
template<typename T > | |
void | copy (T *dst, T const *src, uint32_t size, device_type dst_type, device_type src_type, cuda_stream stream) |
template<typename T , typename U > | |
HOST DEVICE auto | padding_size (T val, U alignment) |
template<typename T , typename U > | |
HOST DEVICE auto | padded_size (T val, U alignment) |
template<typename T , typename U > | |
HOST DEVICE auto | downpadding_size (T val, U alignment) |
template<typename T , typename U > | |
HOST DEVICE auto | downpadded_size (T val, U alignment) |
Variables | |
template<typename T , typename U > | |
constexpr auto | const_agnostic_same_v |
using raft_proto::const_agnostic_same_t = typedef std::enable_if_t<std::is_same_v<std::remove_const_t<T>, std::remove_const_t<U> >, V> |
using raft_proto::cuda_stream = typedef int |
using raft_proto::device_id = typedef detail::device_id<D> |
using raft_proto::device_id_variant = typedef std::variant<device_id<device_type::cpu>, device_id<device_type::gpu> > |
using raft_proto::device_setter = typedef detail::device_setter<device_type::gpu> |
using raft_proto::host_only_throw = typedef detail::host_only_throw<T, host> |
using raft_proto::non_owning_buffer = typedef detail::non_owning_buffer<D, T> |
using raft_proto::owning_buffer = typedef detail::owning_buffer<D, T> |
|
strong |
|
constexpr |
const_agnostic_same_t<T, U> raft_proto::copy | ( | buffer< T > && | dst, |
buffer< U > && | src | ||
) |
const_agnostic_same_t<T, U> raft_proto::copy | ( | buffer< T > && | dst, |
buffer< U > && | src, | ||
cuda_stream | stream | ||
) |
const_agnostic_same_t<T, U> raft_proto::copy | ( | buffer< T > && | dst, |
buffer< U > && | src, | ||
typename buffer< T >::index_type | dst_offset, | ||
cuda_stream | stream | ||
) |
const_agnostic_same_t<T, U> raft_proto::copy | ( | buffer< T > && | dst, |
buffer< U > && | src, | ||
typename buffer< T >::index_type | dst_offset, | ||
typename buffer< U >::index_type | src_offset, | ||
typename buffer< T >::index_type | size, | ||
cuda_stream | stream | ||
) |
const_agnostic_same_t<T, U> raft_proto::copy | ( | buffer< T > & | dst, |
buffer< U > const & | src | ||
) |
const_agnostic_same_t<T, U> raft_proto::copy | ( | buffer< T > & | dst, |
buffer< U > const & | src, | ||
cuda_stream | stream | ||
) |
const_agnostic_same_t<T, U> raft_proto::copy | ( | buffer< T > & | dst, |
buffer< U > const & | src, | ||
typename buffer< T >::index_type | dst_offset, | ||
typename buffer< U >::index_type | src_offset, | ||
typename buffer< T >::index_type | size, | ||
cuda_stream | stream | ||
) |
void raft_proto::copy | ( | T * | dst, |
T const * | src, | ||
uint32_t | size | ||
) |
void raft_proto::copy | ( | T * | dst, |
T const * | src, | ||
uint32_t | size, | ||
cuda_stream | stream | ||
) |
void raft_proto::copy | ( | T * | dst, |
T const * | src, | ||
uint32_t | size, | ||
device_type | dst_type, | ||
device_type | src_type | ||
) |
void raft_proto::copy | ( | T * | dst, |
T const * | src, | ||
uint32_t | size, | ||
device_type | dst_type, | ||
device_type | src_type, | ||
cuda_stream | stream | ||
) |
void raft_proto::copy | ( | T * | dst, |
T const * | src, | ||
uint32_t | size, | ||
device_type | dst_type, | ||
device_type | src_type, | ||
uint32_t | dst_offset, | ||
uint32_t | src_offset, | ||
cuda_stream | stream | ||
) |
void raft_proto::copy | ( | T * | dst, |
T const * | src, | ||
uint32_t | size, | ||
uint32_t | dst_offset, | ||
uint32_t | src_offset | ||
) |
void raft_proto::copy | ( | T * | dst, |
T const * | src, | ||
uint32_t | size, | ||
uint32_t | dst_offset, | ||
uint32_t | src_offset, | ||
cuda_stream | stream | ||
) |
|
noexcept |
HOST DEVICE auto raft_proto::downpadded_size | ( | T | val, |
U | alignment | ||
) |
HOST DEVICE auto raft_proto::downpadding_size | ( | T | val, |
U | alignment | ||
) |
|
inline |
|
inlineconstexpr |