8 #ifndef BLACKCATTENSOR_TENSORS_EXPRESSION_TEMPLATES_ARRAY_KERNEL_ARRAY_H_     9 #define BLACKCATTENSOR_TENSORS_EXPRESSION_TEMPLATES_ARRAY_KERNEL_ARRAY_H_    40 template<
class Shape, 
class ValueType, 
class SystemTag, 
class... Tags>
    57 using return_type = std::conditional_t<
    77         class=std::enable_if_t<
    79                         decltype(std::declval<AllocatorType>().allocate(0))>>>
    82         m_data(allocator.allocate(this->
size())) {};
   107     template<
class ... Integers> 
BCINLINE   112     template<
class ... Integers> 
BCINLINE   117     template<
class Allocator> 
BCHOT   119         allocator.deallocate(
data(), this->
size());
   125     template<
class Allocator> 
BCHOT   133 template<
int N, 
class Allocator, 
class... Tags>
   138     return array_t(shape, allocator);
 auto make_kernel_array(Shape< N > shape, Allocator allocator, Tags...)
Definition: array_kernel_array.h:134
#define BCINLINE
Definition: common.h:96
value_type * m_data
Definition: array_kernel_array.h:64
size_t value_type
Definition: shape.h:26
BCINLINE Kernel_Array(shape_type shape, value_type *ptr)
Definition: array_kernel_array.h:72
static constexpr int tensor_iterator_dim
Definition: array_kernel_array.h:47
BCINLINE Kernel_Array()
Definition: array_kernel_array.h:69
ValueType value_type
Definition: array_kernel_array.h:51
BCINLINE size_t dims_to_index(Integers... ints) const
Definition: shape.h:102
static constexpr int tensor_dim
Definition: shape.h:24
Definition: array_kernel_array.h:41
BCHOT void deallocate(Allocator allocator)
Definition: array_kernel_array.h:118
Definition: expression_template_traits.h:49
BCINLINE shape_type get_shape() const
Definition: array_kernel_array.h:93
BCINLINE size_t size() const
Definition: shape.h:79
bc::traits::conditional_detected_t< bc::traits::query_system_tag, Allocator, host_tag > system_tag
Definition: allocator_traits.h:23
Shape shape_type
Definition: array_kernel_array.h:53
BCHOT void reset(Allocator allocator)
Definition: array_kernel_array.h:126
Kernel_Array(shape_type shape, AllocatorType allocator)
Definition: array_kernel_array.h:80
Definition: allocator_traits.h:20
int size_t
Definition: common.h:283
BCINLINE Shape()
Definition: shape.h:35
BCINLINE const return_type & operator[](bc::size_t index) const
Definition: array_kernel_array.h:98
Definition: allocators.h:20
void deallocate() const
Definition: array_kernel_array.h:123
BCINLINE const return_type & operator()(Integers ... ints) const
Definition: array_kernel_array.h:108
BCINLINE auto shape(Integers... ints)
Definition: shape.h:264
static constexpr int tensor_dim
Definition: array_kernel_array.h:46
#define BCHOT
Definition: common.h:97
BCINLINE size_t coefficientwise_dims_to_index(size_t index) const
Definition: shape.h:93
Definition: expression_template_traits.h:62
BCINLINE value_type * data() const
Definition: array_kernel_array.h:88
Definition: expression_template_base.h:107
The Evaluator determines if an expression needs to be greedily optimized. 
Definition: algorithms.h:22
bc::allocator_traits< Allocator >::system_tag system_tag
Definition: array_kernel_array.h:52