CNORXZ
Container with Native Operation Routines and Expressions
Loading...
Searching...
No Matches
avx.h
Go to the documentation of this file.
1// -*- C++ -*-
12#ifndef __cxz_avx_h__
13#define __cxz_avx_h__
14
15#include <immintrin.h>
16
17#include "base/base.h"
18
19namespace CNORXZ
20{
21 namespace AVX
22 {
23 static constexpr SizeT ND = AVX_VSIZE/sizeof(Double);
24 static constexpr SizeT NF = AVX_VSIZE/sizeof(float);
25 }
26
27 template <>
28 struct PlusCC<Double,Double,AVX::ND>
29 {
30 static inline decltype(auto)
32
33 static inline decltype(auto)
35 };
36
37 template <typename X>
38 struct PlusCX<Double,X,AVX::ND>
39 {
40 static inline decltype(auto)
41 eval(const Consecutive<Double,AVX::ND>& a, const X& b);
42
43 static inline decltype(auto)
45
46 static inline decltype(auto)
47 eval(const X& a, const Consecutive<Double,AVX::ND>& b);
48 };
49
50 template <>
51 struct MinusCC<Double,Double,AVX::ND>
52 {
53 static inline decltype(auto)
55
56 static inline decltype(auto)
58 };
59
60 template <typename X>
61 struct MinusCX<Double,X,AVX::ND>
62 {
63 static inline decltype(auto)
64 eval(const Consecutive<Double,AVX::ND>& a, const X& b);
65
66 static inline decltype(auto)
68
69 static inline decltype(auto)
70 eval(const X& a, const Consecutive<Double,AVX::ND>& b);
71 };
72
73 template <>
74 struct MultipliesCC<Double,Double,AVX::ND>
75 {
76 static inline decltype(auto)
78
79 static inline decltype(auto)
81 };
82
83 template <typename X>
84 struct MultipliesCX<Double,X,AVX::ND>
85 {
86 static inline decltype(auto)
87 eval(const Consecutive<Double,AVX::ND>& a, const X& b);
88
89 static inline decltype(auto)
91
92 static inline decltype(auto)
93 eval(const X& a, const Consecutive<Double,AVX::ND>& b);
94 };
95
96 template <>
97 struct DividesCC<Double,Double,AVX::ND>
98 {
99 static inline decltype(auto)
101
102 static inline decltype(auto)
104 };
105
106 template <typename X>
107 struct DividesCX<Double,X,AVX::ND>
108 {
109 static inline decltype(auto)
110 eval(const Consecutive<Double,AVX::ND>& a, const X& b);
111
112 static inline decltype(auto)
114
115 static inline decltype(auto)
116 eval(const X& a, const Consecutive<Double,AVX::ND>& b);
117 };
118}
119
120#endif
basic headers
#define AVX_VSIZE
Definition intrin.h:15
static constexpr SizeT ND
Definition avx.h:23
static constexpr SizeT NF
Definition avx.h:24
double Double
Definition types.h:39
uint64_t SizeT
Definition types.h:38
Sptr< Range > rangeCast(const RangePtr r)
static constexpr decltype(auto) aeval(Consecutive< T, N > &a, const Consecutive< U, N > &b)
Definition reg.cc.h:250
static constexpr decltype(auto) eval(const Consecutive< T, N > &a, const Consecutive< U, N > &b)
Definition reg.cc.h:232
static constexpr decltype(auto) aeval(Consecutive< T, N > &a, const X &b)
Definition reg.cc.h:256
static constexpr decltype(auto) eval(const Consecutive< T, N > &a, const X &b)
Definition reg.cc.h:238
static constexpr decltype(auto) aeval(Consecutive< T, N > &a, const Consecutive< U, N > &b)
Definition reg.cc.h:182
static constexpr decltype(auto) eval(const Consecutive< T, N > &a, const Consecutive< U, N > &b)
Definition reg.cc.h:164
static constexpr decltype(auto) eval(const Consecutive< T, N > &a, const X &b)
Definition reg.cc.h:170
static constexpr decltype(auto) aeval(Consecutive< T, N > &a, const X &b)
Definition reg.cc.h:188
static constexpr decltype(auto) eval(const Consecutive< T, N > &a, const Consecutive< U, N > &b)
Definition reg.cc.h:198
static constexpr decltype(auto) aeval(Consecutive< T, N > &a, const Consecutive< U, N > &b)
Definition reg.cc.h:216
static constexpr decltype(auto) aeval(Consecutive< T, N > &a, const X &b)
Definition reg.cc.h:222
static constexpr decltype(auto) eval(const Consecutive< T, N > &a, const X &b)
Definition reg.cc.h:204
static constexpr decltype(auto) aeval(Consecutive< T, N > &a, const Consecutive< U, N > &b)
Definition reg.cc.h:136
static constexpr decltype(auto) eval(const Consecutive< T, N > &a, const Consecutive< U, N > &b)
Definition reg.cc.h:129
static constexpr decltype(auto) aeval(Consecutive< T, N > &a, const X &b)
Definition reg.cc.h:154
static constexpr decltype(auto) eval(const Consecutive< T, N > &a, const X &b)
Definition reg.cc.h:142