11#include "vecmem/utils/copy.hpp"
12#include "vecmem/utils/cuda/stream_wrapper.hpp"
13#include "vecmem/vecmem_cuda_export.hpp"
40 virtual void do_copy(std::size_t size,
const void*
from,
void*
to,
41 type::copy_type
cptype)
const override final;
44 virtual void do_memset(std::size_t size,
void* ptr,
45 int value)
const override final;
Class implementing (synchronous) host <-> device memory copies.
Definition copy.hpp:41
std::unique_ptr< abstract_event > event_type
Event type used by the copy class.
Definition copy.hpp:69
data::vector_buffer< std::remove_cv_t< TYPE > > to(const data::vector_view< TYPE > &data, memory_resource &resource, type::copy_type cptype=type::unknown) const
Copy a 1-dimensional vector to the specified memory resource.
Definition copy.ipp:66
Specialisation of vecmem::copy for CUDA.
Definition async_copy.hpp:27
VECMEM_CUDA_EXPORT ~async_copy()
Destructor.
Definition async_copy.cpp:88
virtual VECMEM_CUDA_EXPORT void do_copy(std::size_t size, const void *from, void *to, type::copy_type cptype) const override final
Perform an asynchronous memory copy using CUDA.
Definition async_copy.cpp:90
virtual VECMEM_CUDA_EXPORT void do_memset(std::size_t size, void *ptr, int value) const override final
Fill a memory area using CUDA asynchronously.
Definition async_copy.cpp:117
virtual VECMEM_CUDA_EXPORT event_type create_event() const override final
Create an event for synchronization.
Definition async_copy.cpp:138
Wrapper class for cudaStream_t.
Definition stream_wrapper.hpp:24
Namespace holding types that work on/with CUDA.
Definition cuda_device_atomic_ref.hpp:19
std::vector< T, vecmem::polymorphic_allocator< T > > vector
Alias type for vectors with our polymorphic allocator.
Definition vector.hpp:35