copyCreateHost2HostArray

copyCreateHost2HostArray#

stdgpu: copyCreateHost2HostArray
stdgpu Latest
Efficient STL-like Data Structures on the GPU

◆ copyCreateHost2HostArray()

template<typename T >
T * copyCreateHost2HostArray ( const T *  host_array,
const stdgpu::index64_t  count,
const MemoryCopy  check_safety = MemoryCopy::RANGE_CHECK 
)

Creates and copies the given host array to the host.

Template Parameters
TThe type of the array
Parameters
[in]host_arrayThe host array
[in]countThe number of elements of host_array
[in]check_safetyTrue if this function should check whether copying is safe, false otherwise
Returns
The same array allocated on the host
Note
The source array might also be a managed array