TensorSycl.h
00001 // This file is part of Eigen, a lightweight C++ template library
00002 // for linear algebra.
00003 //
00004 // Mehdi Goli    Codeplay Software Ltd.
00005 // Ralph Potter  Codeplay Software Ltd.
00006 // Luke Iwanski  Codeplay Software Ltd.
00007 // Contact: eigen@codeplay.com
00008 //
00009 // This Source Code Form is subject to the terms of the Mozilla
00010 // Public License v. 2.0. If a copy of the MPL was not distributed
00011 // with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
00012 
00013 // General include header of SYCL target for Tensor Module
00014 #ifndef UNSUPPORTED_EIGEN_CXX11_SRC_TENSOR_TENSORSYCL_H
00015 #define UNSUPPORTED_EIGEN_CXX11_SRC_TENSOR_TENSORSYCL_H
00016 
00017 #ifdef EIGEN_USE_SYCL
00018 
00019 // global pointer to set different attribute state for a class
00020 template <class T>
00021 struct MakeGlobalPointer {
00022   typedef typename cl::sycl::global_ptr<T>::pointer_t Type;
00023 };
00024 
00025 // global pointer to set different attribute state for a class
00026 template <class T>
00027 struct MakeLocalPointer {
00028   typedef typename cl::sycl::local_ptr<T>::pointer_t Type;
00029 };
00030 
00031 
00032 namespace Eigen {
00033 namespace TensorSycl {
00034 namespace internal {
00035 
00037   struct NoOP;
00038 
00039 template<bool IsConst, typename T> struct GetType{
00040   typedef const T Type;
00041 };
00042 template<typename T> struct GetType<false, T>{
00043   typedef T Type;
00044 };
00045 
00046 }
00047 }
00048 }
00049 
00050 // tuple construction
00051 #include "TensorSyclTuple.h"
00052 
00053 // counting number of leaf at compile time
00054 #include "TensorSyclLeafCount.h"
00055 
00056 // The index PlaceHolder takes the actual expression and replaces the actual
00057 // data on it with the place holder. It uses the same pre-order expression tree
00058 // traverse as the leaf count in order to give the right access number to each
00059 // node in the expression
00060 #include "TensorSyclPlaceHolderExpr.h"
00061 
00062 // creation of an accessor tuple from a tuple of SYCL buffers
00063 #include "TensorSyclExtractAccessor.h"
00064 
00065 // this is used to change the address space type in tensor map for GPU
00066 #include "TensorSyclConvertToDeviceExpression.h"
00067 
00068 // this is used to extract the functors
00069 #include "TensorSyclExtractFunctors.h"
00070 
00071 // this is used to create tensormap on the device
00072 // this is used to construct the expression on the device
00073 #include "TensorSyclExprConstructor.h"
00074 
00076 #include "TensorReductionSycl.h"
00077 
00078 // kernel execution using fusion
00079 #include "TensorSyclRun.h"
00080 
00081 #endif  // end of EIGEN_USE_SYCL
00082 #endif  // UNSUPPORTED_EIGEN_CXX11_SRC_TENSOR_TENSORSYCL_H
 All Classes Functions Variables Typedefs Enumerator