safe_host_allocator< T >

safe_host_allocator< T >#

stdgpu: stdgpu::safe_host_allocator< T >
stdgpu Latest
Efficient STL-like Data Structures on the GPU

Detailed Description

template<typename T>
struct stdgpu::safe_host_allocator< T >

An allocator for host memory.

Template Parameters
TA type

Public Types

using value_type = T
 

Public Member Functions

 safe_host_allocator () noexcept=default
 
 safe_host_allocator (const safe_host_allocator &) noexcept=default
 
template<typename U >
 safe_host_allocator (const safe_host_allocator< U > &other) noexcept
 
 safe_host_allocator (safe_host_allocator &&) noexcept=default
 
 ~safe_host_allocator () noexcept=default
 
T * allocate (index64_t n)
 
void deallocate (T *p, index64_t n)
 
safe_host_allocatoroperator= (const safe_host_allocator &) noexcept=default
 
safe_host_allocatoroperator= (safe_host_allocator &&) noexcept=default
 

Static Public Attributes

static constexpr dynamic_memory_type memory_type