1 #ifndef VIENNACL_TOOLS_ENTRY_PROXY_HPP_ 
    2 #define VIENNACL_TOOLS_ENTRY_PROXY_HPP_ 
   40 template<
typename NumericT>
 
   53     : index_(mem_offset), mem_handle_(mem_handle) {}
 
  178 template<
typename NumericT>
 
  179 class const_entry_proxy
 
  181   typedef const_entry_proxy<NumericT>      self_type;
 
  192     : index_(mem_offset), mem_handle_(mem_handle) {}
 
  212   unsigned int index()
 const { 
return index_; }
 
const_entry_proxy(vcl_size_t mem_offset, handle_type const &mem_handle)
The constructor for the proxy class. Declared explicit to avoid any surprises created by the compiler...
void memory_write(mem_handle &dst_buffer, vcl_size_t dst_offset, vcl_size_t bytes_to_write, const void *ptr, bool async=false)
Writes data from main RAM identified by 'ptr' to the buffer identified by 'dst_buffer'. 
This class represents a single scalar value on the GPU and behaves mostly like a built-in scalar type...
handle_type & handle()
Returns the memory handle, non-const version. 
This file provides the forward declarations for the main types used within ViennaCL. 
void memory_read(mem_handle const &src_buffer, vcl_size_t src_offset, vcl_size_t bytes_to_read, void *ptr, bool async=false)
Reads data from a buffer back to main RAM. 
entry_proxy & operator-=(NumericT value)
Inplace subtraction of a CPU floating point value. 
viennacl::backend::mem_handle handle_type
entry_proxy & operator/=(NumericT value)
Inplace division by a CPU floating point value. 
entry_proxy & operator+=(NumericT value)
Inplace addition of a CPU floating point value. 
vcl_size_t index() const 
Returns the index of the represented element. 
entry_proxy & operator=(entry_proxy const &other)
Assignment of another GPU value. 
entry_proxy & operator=(NumericT value)
Assignment of a CPU floating point value. 
entry_proxy & operator*=(NumericT value)
Inplace multiplication with a CPU floating point value. 
entry_proxy(vcl_size_t mem_offset, handle_type &mem_handle)
The constructor for the proxy class. Declared explicit to avoid any surprises created by the compiler...
handle_type const & handle() const 
Returns the memory viennacl::ocl::handle. 
void memory_copy(mem_handle const &src_buffer, mem_handle &dst_buffer, vcl_size_t src_offset, vcl_size_t dst_offset, vcl_size_t bytes_to_copy)
Copies 'bytes_to_copy' bytes from address 'src_buffer + src_offset' to memory starting at address 'ds...
Main abstraction class for multiple memory domains. Represents a buffer in either main RAM...
viennacl::backend::mem_handle handle_type
unsigned int index() const 
Returns the index of the represented element. 
A proxy class for a single element of a vector or matrix. This proxy should not be noticed by end-use...
Implementation of the ViennaCL scalar class. 
handle_type const & handle() const 
Returns the memory handle. 
entry_proxy & operator=(scalar< NumericT > const &value)
Assignment of a GPU floating point value. Avoids unnecessary GPU->CPU->GPU transfers.