ViennaCL - The Vienna Computing Library  1.7.1
Free open-source GPU-accelerated linear algebra and solver library.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
viennacl::backend::typesafe_host_array< T, special > Class Template Reference

Helper class implementing an array on the host. Default case: No conversion necessary. More...

#include <util.hpp>

Public Member Functions

 typesafe_host_array ()
 
 typesafe_host_array (mem_handle const &handle, vcl_size_t num=0)
 
 ~typesafe_host_array ()
 
void * get ()
 
vcl_size_t raw_size () const
 
vcl_size_t element_size () const
 
vcl_size_t size () const
 
template<typename U >
void set (vcl_size_t index, U value)
 
void raw_resize (mem_handle const &, vcl_size_t num)
 Resize without initializing the new memory. More...
 
void resize (mem_handle const &handle, vcl_size_t num)
 Resize including initialization of new memory (cf. std::vector<>) More...
 
cpu_type operator[] (vcl_size_t index) const
 

Detailed Description

template<typename T, bool special = detail::convert_to_opencl<T>::special>
class viennacl::backend::typesafe_host_array< T, special >

Helper class implementing an array on the host. Default case: No conversion necessary.

Definition at line 92 of file util.hpp.

Constructor & Destructor Documentation

template<typename T, bool special = detail::convert_to_opencl<T>::special>
viennacl::backend::typesafe_host_array< T, special >::typesafe_host_array ( )
inlineexplicit

Definition at line 98 of file util.hpp.

template<typename T, bool special = detail::convert_to_opencl<T>::special>
viennacl::backend::typesafe_host_array< T, special >::typesafe_host_array ( mem_handle const &  handle,
vcl_size_t  num = 0 
)
inlineexplicit

Definition at line 100 of file util.hpp.

template<typename T, bool special = detail::convert_to_opencl<T>::special>
viennacl::backend::typesafe_host_array< T, special >::~typesafe_host_array ( )
inline

Definition at line 105 of file util.hpp.

Member Function Documentation

template<typename T, bool special = detail::convert_to_opencl<T>::special>
vcl_size_t viennacl::backend::typesafe_host_array< T, special >::element_size ( ) const
inline

Definition at line 112 of file util.hpp.

template<typename T, bool special = detail::convert_to_opencl<T>::special>
void* viennacl::backend::typesafe_host_array< T, special >::get ( )
inline

Definition at line 110 of file util.hpp.

template<typename T, bool special = detail::convert_to_opencl<T>::special>
cpu_type viennacl::backend::typesafe_host_array< T, special >::operator[] ( vcl_size_t  index) const
inline

Definition at line 149 of file util.hpp.

template<typename T, bool special = detail::convert_to_opencl<T>::special>
void viennacl::backend::typesafe_host_array< T, special >::raw_resize ( mem_handle const &  ,
vcl_size_t  num 
)
inline

Resize without initializing the new memory.

Definition at line 125 of file util.hpp.

template<typename T, bool special = detail::convert_to_opencl<T>::special>
vcl_size_t viennacl::backend::typesafe_host_array< T, special >::raw_size ( ) const
inline

Definition at line 111 of file util.hpp.

template<typename T, bool special = detail::convert_to_opencl<T>::special>
void viennacl::backend::typesafe_host_array< T, special >::resize ( mem_handle const &  handle,
vcl_size_t  num 
)
inline

Resize including initialization of new memory (cf. std::vector<>)

Definition at line 138 of file util.hpp.

template<typename T, bool special = detail::convert_to_opencl<T>::special>
template<typename U >
void viennacl::backend::typesafe_host_array< T, special >::set ( vcl_size_t  index,
value 
)
inline

Definition at line 115 of file util.hpp.

template<typename T, bool special = detail::convert_to_opencl<T>::special>
vcl_size_t viennacl::backend::typesafe_host_array< T, special >::size ( ) const
inline

Definition at line 113 of file util.hpp.


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