cuda::shared_managed_memory_pool#

class shared_managed_memory_pool : public cuda::__shared_memory_pool_base<shared_managed_memory_pool>#

Shared managed memory pool#

shared_managed_memory_pool provides shared ownership of a managed memory pool. It is copyable and each copy shares the same underlying cudaMemPool_t via reference counting. This makes it usable with any_resource and other contexts that require copyable resources.

Public Types

using default_queries = ::cuda::mr::properties_list<::cuda::mr::device_accessible, ::cuda::mr::host_accessible>#

Public Functions

inline shared_managed_memory_pool(
const shared_managed_memory_pool &__other
) noexcept#
inline shared_managed_memory_pool(
shared_managed_memory_pool &&__other
) noexcept#
shared_managed_memory_pool &operator=(
const shared_managed_memory_pool&
) = default#
shared_managed_memory_pool &operator=(
shared_managed_memory_pool&&
) = default#
inline explicit shared_managed_memory_pool(no_init_t) noexcept#

Constructs an empty shared managed memory pool.

inline explicit shared_managed_memory_pool(
memory_pool_properties __properties = {}
)#

Constructs a shared managed memory pool.

Parameters:

__properties – Optional pool creation properties.

inline constexpr const _Derived &query(
const __get_memory_resource_t&
) const noexcept#

Public Static Functions

static inline shared_managed_memory_pool from_native_handle(
::cudaMemPool_t __pool
) noexcept#

Constructs a shared managed memory pool from an existing native handle.

Parameters:

__pool – The cudaMemPool_t to take shared ownership of.

Friends

inline friend constexpr void get_property(
const shared_managed_memory_pool&,
::cuda::mr::device_accessible
) noexcept#
inline friend constexpr void get_property(
const shared_managed_memory_pool&,
::cuda::mr::host_accessible
) noexcept#