|
BeBOP Optimized Sparse Kernel Interface Library
1.0.1h
|
Multivector view implementation. More...
#include <oski/mangle.h>Go to the source code of this file.
Data Structures | |
| struct | oski_vecstruct_t |
| Multivector view structure. More... | |
Defines | |
| #define | INC_OSKI_VECTOR_H |
| oski/vector.h included. | |
| #define | MAKE_VECSTRUCT_INIT(m, n, orient, stride, rowinc, colinc, val) {m, n, orient, stride, rowinc, colinc, val} |
| Macro for initializing a declared oski_vecstruct_t variable. | |
| #define | VECRM_GET(v, i, j, s) (v)[(i)*(s) + (j)] |
| Get the (i, j) element from an array v stored in row-major layout with stride s. | |
| #define | VECCM_GET(v, i, j, s) (v)[(i) + (j)*(s)] |
| Get the (i, j) element from an array v stored in column-major layout with stride s. | |
| #define | VECVIEW_GET(x, i, j) |
| Get the (i, j) element of an arbitrary vector view. | |
| #define | IS_VECVIEW_COLVEC(x) ((x)->num_cols == 1) |
| Returns 1 if x is a column vector. | |
| #define | IS_VECVIEW_COLVEC_STRIDE1(x) |
| Returns 1 if x is a unit stride column vector. | |
Multivector view implementation.
| #define INC_OSKI_VECTOR_H |
oski/vector.h included.
| #define IS_VECVIEW_COLVEC | ( | x | ) | ((x)->num_cols == 1) |
Returns 1 if x is a column vector.
| #define IS_VECVIEW_COLVEC_STRIDE1 | ( | x | ) |
( \
IS_VECVIEW_COLVEC(x) \
&& ( \
(((x)->orient == LAYOUT_ROWMAJ) && ((x)->stride == 1)) \
|| (((x)->orient == LAYOUT_COLMAJ)) \
) \
)
Returns 1 if x is a unit stride column vector.
| #define MAKE_VECSTRUCT_INIT | ( | m, | |
| n, | |||
| orient, | |||
| stride, | |||
| rowinc, | |||
| colinc, | |||
| val | |||
| ) | {m, n, orient, stride, rowinc, colinc, val} |
Macro for initializing a declared oski_vecstruct_t variable.
| #define VECCM_GET | ( | v, | |
| i, | |||
| j, | |||
| s | |||
| ) | (v)[(i) + (j)*(s)] |
Get the (i, j) element from an array v stored in column-major layout with stride s.
| [in] | v | Raw vector array storage. |
| [in] | i | Row index (zero-based). |
| [in] | j | Column index (zero-based). |
| [in] | s | Stride (leading-dimension). |
Referenced by oski_PrintDebugVecView(), and ZeroDenseMatColmaj().
| #define VECRM_GET | ( | v, | |
| i, | |||
| j, | |||
| s | |||
| ) | (v)[(i)*(s) + (j)] |
Get the (i, j) element from an array v stored in row-major layout with stride s.
| [in] | v | Raw vector array storage. |
| [in] | i | Row index (zero-based). |
| [in] | j | Column index (zero-based). |
| [in] | s | Stride (leading-dimension). |
Referenced by oski_PrintDebugVecView(), and ZeroDenseMatRowmaj().
| #define VECVIEW_GET | ( | x, | |
| i, | |||
| j | |||
| ) |
(((x)->orient == LAYOUT_ROWMAJ) \ ? VECRM_GET((x)->val, i, j, (x)->stride) \ : VECCM_GET((x)->val, i, j, (x)->stride) \ )
Get the (i, j) element of an arbitrary vector view.
| [in] | x | Vector view object (handle). |
| [in] | i | Row index (zero-based). |
| [in] | j | Column index (zero-based). |
Referenced by oski_PrintDebugVecView().
1.7.6.1