ViennaCL - The Vienna Computing Library  1.5.2
Public Member Functions | Static Public Member Functions
vector_saxpy Class Reference

OpenCL kernel generation class for vector expressions of AXPY type, i.e. x = alpha * y + beta * z, where the number of summands can in principle be arbitrarily large. More...

#include <saxpy.hpp>

Inheritance diagram for vector_saxpy:
profile_base

Public Member Functions

std::string csv_representation () const
 csv representation of an operation More...
 
 vector_saxpy (unsigned int v, vcl_size_t gs, vcl_size_t ng, unsigned int d)
 
void configure_range_enqueue_arguments (vcl_size_t kernel_id, statements_type const &statements, viennacl::ocl::kernel &k, unsigned int &n_arg) const
 Configures the range and enqueues the arguments associated with the profile. More...
 
void kernel_arguments (statements_type const &, std::string &arguments_string) const
 
- Public Member Functions inherited from profile_base
 profile_base (unsigned int vectorization, vcl_size_t local_size_1, vcl_size_t local_size_2, vcl_size_t num_kernels)
 The constructor. More...
 
virtual ~profile_base ()
 The destructor. More...
 
unsigned int vector_size () const
 Get the vector size of the kernel. More...
 
bool is_slow (viennacl::ocl::device const &dev) const
 returns whether or not the profile is likely to be slow on a particular device More...
 
bool is_invalid (viennacl::ocl::device const &dev, vcl_size_t scalartype_size) const
 returns whether or not the profile leads to undefined behavior on particular device More...
 
vcl_size_t num_kernels () const
 Returns the number of kernels needed by this operation. More...
 
virtual void operator() (utils::kernel_generation_stream &stream, vcl_size_t device_offset, statements_type const &statements) const
 Generates the code associated with this profile onto the provided stream Redirects to the virtual core() method. More...
 

Static Public Member Functions

static std::string csv_format ()
 

Additional Inherited Members

- Public Types inherited from profile_base
typedef std::list< std::pair
< scheduler::statement,
scheduler::statement_node > > 
statements_type
 
- Protected Member Functions inherited from profile_base
virtual bool invalid_impl (viennacl::ocl::device const &, vcl_size_t) const
 
virtual bool is_slow_impl (viennacl::ocl::device const &) const
 
virtual vcl_size_t lmem_used (vcl_size_t) const
 
void configure_local_sizes (viennacl::ocl::kernel &k, vcl_size_t) const
 
virtual void print (std::ostream &s) const
 
- Protected Attributes inherited from profile_base
unsigned int vector_size_
 
vcl_size_t local_size_1_
 
vcl_size_t local_size_2_
 
vcl_size_t num_kernels_
 

Detailed Description

OpenCL kernel generation class for vector expressions of AXPY type, i.e. x = alpha * y + beta * z, where the number of summands can in principle be arbitrarily large.

Constructor & Destructor Documentation

vector_saxpy ( unsigned int  v,
vcl_size_t  gs,
vcl_size_t  ng,
unsigned int  d 
)
inline

Member Function Documentation

void configure_range_enqueue_arguments ( vcl_size_t  kernel_id,
statements_type const &  statements,
viennacl::ocl::kernel k,
unsigned int &  n_arg 
) const
inlinevirtual

Configures the range and enqueues the arguments associated with the profile.

Implements profile_base.

static std::string csv_format ( )
inlinestatic
std::string csv_representation ( ) const
inlinevirtual

csv representation of an operation

Useful when writing to a file

Implements profile_base.

void kernel_arguments ( statements_type const &  ,
std::string &  arguments_string 
) const
inlinevirtual

Implements profile_base.


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