cppassist  1.0.0.f4fab4f962ff
C++ sanctuary for small but powerful and frequently required, stand alone features.
algorithm.h
Go to the documentation of this file.
1 
2 #pragma once
3 
4 
5 namespace cppassist
6 {
7 
8 
9 template <typename T, size_t SIMD_SIZE>
10 void add(const vector<T, SIMD_SIZE> & first, const vector<T, SIMD_SIZE> & second, vector<T, SIMD_SIZE> & result);
11 template <typename T, size_t SIMD_SIZE>
12 void sub(const vector<T, SIMD_SIZE> & first, const vector<T, SIMD_SIZE> & second, vector<T, SIMD_SIZE> & result);
13 template <typename T, size_t SIMD_SIZE>
14 void mul(const vector<T, SIMD_SIZE> & first, const vector<T, SIMD_SIZE> & second, vector<T, SIMD_SIZE> & result);
15 template <typename T, size_t SIMD_SIZE>
16 void div(const vector<T, SIMD_SIZE> & first, const vector<T, SIMD_SIZE> & second, vector<T, SIMD_SIZE> & result);
17 
18 template <typename T, size_t SIMD_SIZE>
19 void add(const vector<T, SIMD_SIZE> & first, const typename vector<T, SIMD_SIZE>::primitive_type & scalar, vector<T, SIMD_SIZE> & result);
20 template <typename T, size_t SIMD_SIZE>
21 void sub(const vector<T, SIMD_SIZE> & first, const typename vector<T, SIMD_SIZE>::primitive_type & scalar, vector<T, SIMD_SIZE> & result);
22 template <typename T, size_t SIMD_SIZE>
23 void mul(const vector<T, SIMD_SIZE> & first, const typename vector<T, SIMD_SIZE>::primitive_type & scalar, vector<T, SIMD_SIZE> & result);
24 template <typename T, size_t SIMD_SIZE>
25 void div(const vector<T, SIMD_SIZE> & first, const typename vector<T, SIMD_SIZE>::primitive_type & scalar, vector<T, SIMD_SIZE> & result);
26 
27 template <typename T, size_t SIMD_SIZE>
28 void add(const typename vector<T, SIMD_SIZE>::primitive_type & scalar, const vector<T, SIMD_SIZE> & first, vector<T, SIMD_SIZE> & result);
29 template <typename T, size_t SIMD_SIZE>
30 void sub(const typename vector<T, SIMD_SIZE>::primitive_type & scalar, const vector<T, SIMD_SIZE> & first, vector<T, SIMD_SIZE> & result);
31 template <typename T, size_t SIMD_SIZE>
32 void mul(const typename vector<T, SIMD_SIZE>::primitive_type & scalar, const vector<T, SIMD_SIZE> & first, vector<T, SIMD_SIZE> & result);
33 template <typename T, size_t SIMD_SIZE>
34 void div(const typename vector<T, SIMD_SIZE>::primitive_type & scalar, const vector<T, SIMD_SIZE> & first, vector<T, SIMD_SIZE> & result);
35 
36 template <typename T, size_t SIMD_SIZE>
37 void sqrt(const vector<T, SIMD_SIZE> & first, vector<T, SIMD_SIZE> & result);
38 
39 
40 } // namespace cppassist
41 
42 
Definition: ArgumentParser.h:12
void add(const vector< T, SIMD_SIZE > &first, const vector< T, SIMD_SIZE > &second, vector< T, SIMD_SIZE > &result)
Definition: algorithm.inl:12
void sub(const vector< T, SIMD_SIZE > &first, const vector< T, SIMD_SIZE > &second, vector< T, SIMD_SIZE > &result)
Definition: algorithm.inl:23
void sqrt(const vector< T, SIMD_SIZE > &first, vector< T, SIMD_SIZE > &result)
Definition: algorithm.inl:144
void div(const vector< T, SIMD_SIZE > &first, const vector< T, SIMD_SIZE > &second, vector< T, SIMD_SIZE > &result)
Definition: algorithm.inl:45
void mul(const vector< T, SIMD_SIZE > &first, const vector< T, SIMD_SIZE > &second, vector< T, SIMD_SIZE > &result)
Definition: algorithm.inl:34
T primitive_type
Definition: vector.h:23