29#include "Kernels/aclKernelConfiguration.h"
47 template <
class T>
class Array;
49 typedef std::shared_ptr<ElementBase>
Element;
55 namespace elementOperators
329 Element parse(
const std::vector<std::pair<Element, std::string> > & elementNamePairs,
330 const std::string & statement);
351 const std::vector<Element> & thenBody,
352 const std::vector<Element> & elseBody);
365 const std::vector<Element> & body);
395 template <
typename T>
void copy(
MemBlock &source, std::vector<T> &destination);
399 template <
typename T>
void copy(std::vector<T> &source,
MemBlock &destination);
407 template <
typename T>
void copy(
Element source, std::vector<T> &destination);
411 template <
typename T>
void copy(std::vector<T> &source,
Element destination);
427 const std::vector<Element> & a);
434 std::vector<Element> & operator<<(std::vector<Element> & ec,
435 const std::vector<Element> & a);
ACL Kernel configuration class.
The class represents a matrix elements of Element.
The class represents several Element.
ExpressionContainer & operator<<(ExpressionContainer &ec, const std::vector< Element > &a)
puts a vector<Element> in ExpressionContainer
ExpressionContainer & operator<<(ExpressionContainer &ec, const ExpressionContainer &a)
puts a ExpressionContainer in ExpressionContainer
ExpressionContainer & operator<<(ExpressionContainer &ec, const MatrixOfElements &a)
puts a MatrixOfElements in ExpressionContainer
CommandQueue interface for cl_command_queue.
Element operator+=(Element e1, Element e2)
Element operatorAssignment(Element e1, Element e2)
Element operator-=(Element e1, Element e2)
Element operator/=(Element e1, Element e2)
Element operator*=(Element e1, Element e2)
Element operatorAssignmentSafe(Element e1, Element e2)
Element atomic_add(Element e1, Element e2)
Element atomic_xchg(Element e1, Element e2)
Element atomic_sub(Element e1, Element e2)
Element operator&&(Element e1, Element e2)
Element operator<=(Element e1, Element e2)
Element isNotEqual(Element e1, Element e2)
Element operator>=(Element e1, Element e2)
Element operator>(Element e1, Element e2)
Element operator<(Element e1, Element e2)
Element isEqual(Element e1, Element e2)
Element operator||(Element e1, Element e2)
Element forLoop(Element initialization, Element condition, Element increase, const std::vector< Element > &body)
Element select(Element e1, Element e2, Element e3)
Element returnStatement()
Element ifElse(Element condition, const std::vector< Element > &thenBody, const std::vector< Element > &elseBody)
const KernelConfiguration KERNEL_BASIC
Element max(Element a, Element b)
Element mad(Element e1, Element e2, Element e3)
Element min(Element a, Element b)
Element abs_diff(Element a, Element b)
Element copysign(Element a, Element b)
Element powI(Element a, unsigned int i)
Element operator+(Element e1, Element e2)
Element operator!(Element e)
Element operator-(Element e)
Element operator*(Element e1, Element e2)
Element operator%(Element e1, Element e2)
Element operator/(Element e1, Element e2)
void initData(Element a, Element initializationValue, const KernelConfiguration &kernelConfig=KERNEL_BASIC)
Element convert(const TypeID tName, Element e1, bool strong=true)
Element printfFunction(std::string args)
Element parse(const std::vector< std::pair< Element, std::string > > &elementNamePairs, const std::string &statement)
Element excerpt(Element source, Element filter)
Element syncCopy(Element source, Element destination, Element srcOffset, Element dstOffset, Element length)
Element barrier(std::string flags="CLK_LOCAL_MEM_FENCE")
Element any(Element e)
Corresponds to the openCL operation any.
Element all(Element e)
Corresponds to the openCL operation all.
Advanced Computational Language.
ElementData generateElementArray(TypeID typeID, unsigned int size)
bool isConstant(Element e)
bool isMemBlock(Element e)
std::shared_ptr< cl::CommandQueue > CommandQueue
Element generateElementLocalArray(TypeID typeID, unsigned int size)
bool isSingleValue(Element e)
The function returns true when the input is a single valued object e.g. aclConstatnt,...
Element generateSubElement(Element, unsigned int size, int offset)
function creates subElement with given length and offset; offset is constant
void copy(MemBlock &source, T *destination)
Element generateShiftedElement(Element, int offset)
std::shared_ptr< MemBlock > ElementData
void swapBuffers(std::shared_ptr< Array< T > >a, std::shared_ptr< Array< T > > b)
std::shared_ptr< ElementBase > Element
The OpenCL C++ bindings are defined within this namespace.