Home
Install
Use
Develop
Support
News
Credits
hosted by
|
9 #ifndef __dsp_MemoryCUDA_h_
10 #define __dsp_MemoryCUDA_h_
12 #include "dsp/MemoryHost.h"
14 #include <cuda_runtime.h>
22 void* do_allocate ( size_t nbytes) override;
23 void do_free ( void*) override;
31 DeviceMemory (cudaStream_t _stream = 0, int _device = 0);
33 void* do_allocate ( size_t nbytes);
35 void do_copy ( void* to, const void* from, size_t bytes);
36 void do_zero ( void*, size_t);
37 bool on_host () const { return false; }
39 void set_stream (cudaStream_t _stream) { stream = _stream; }
40 cudaStream_t get_stream () { return stream; }
41 cudaStream_t get_stream () const { return stream; }
43 int get_device () { return device; };
44 int get_device () const { return device; };
55 void * do_allocate ( size_t nbytes);
Manages CUDA device memory allocation and destruction. Definition: MemoryCUDA.h:32
Manages memory allocation and destruction on the host machine. Definition: MemoryHost.h:22
Pure virtual base class of objects that manage memory allocation and destruction. Definition: Memory.h:23
Generated using doxygen 1.8.17
|