Caffe
Public Types | Public Member Functions | List of all members
caffe::SyncedMemory Class Reference

Manages memory allocation and synchronization between the host (CPU) and device (GPU). More...

#include <syncedmem.hpp>

Public Types

enum  SyncedHead { UNINITIALIZED, HEAD_AT_CPU, HEAD_AT_GPU, SYNCED }
 

Public Member Functions

 SyncedMemory (size_t size)
 
const void * cpu_data ()
 
void set_cpu_data (void *data)
 
const void * gpu_data ()
 
void set_gpu_data (void *data)
 
void * mutable_cpu_data ()
 
void * mutable_gpu_data ()
 
SyncedHead head ()
 
size_t size ()
 
void async_gpu_push (const cudaStream_t &stream)
 

Detailed Description

Manages memory allocation and synchronization between the host (CPU) and device (GPU).

TODO(dox): more thorough description.


The documentation for this class was generated from the following files: