a_and_at.c File Reference


Detailed Description

Implementation of simultaneously multiplication by sparse $A$ and $\mathrm{op}(A) \in \{A, A^T, A^H=\bar{A}^T\}$.

This module implements the matrix type-independent version, which performs error-checking first and then calls the the appropriate kernel implementation.

#include <assert.h>
#include <oski/common.h>
#include <oski/matrix.h>

Defines

#define MatMultAndMatTransMultDefault   MANGLE_(MatMultAndMatTransMultDefault)
 Mangled name for default simultaneous multiplication by sparse $A$ and $\mathrm{op}(A)$.

Functions

static int MatMultAndMatTransMultDefault (const oski_matrix_t A_tunable, oski_value_t alpha, const oski_vecview_t x, oski_value_t beta, oski_vecview_t y, oski_matop_t op, oski_value_t omega, const oski_vecview_t w, oski_value_t zeta, oski_vecview_t z)
 A default implementation of simultaneous multiplication by sparse $A$ and $\mathrm{op}(A)$ based on multiple calls to sparse matrix-vector multiply.
int oski_CheckArgsMatMultAndMatTransMult (const oski_matrix_t A_tunable, oski_value_t alpha, const oski_vecview_t x, oski_value_t beta, oski_vecview_t y, oski_matop_t op, oski_value_t omega, const oski_vecview_t w, oski_value_t zeta, oski_vecview_t z, const char *caller)
 Verify the arguments to a function with a calling signature like oski_MatMultAndMatTransMult().
int oski_MatMultAndMatTransMult (const oski_matrix_t A_tunable, oski_value_t alpha, const oski_vecview_t x_view, oski_value_t beta, oski_vecview_t y_view, oski_matop_t op, oski_value_t omega, const oski_vecview_t w_view, oski_value_t zeta, oski_vecview_t z_view)
 Computes $y \leftarrow \alpha\cdot Ax + \beta\cdot y$ and $z \leftarrow \omega\cdot\mathrm{op}(A)x + \zeta\cdot z$, where $\mathrm{op}(A) \in \{A, A^T, A^H\}$.
void oski_MakeArglistMatMultAndMatTransMult (oski_value_t alpha, const oski_vecview_t x_view, oski_value_t beta, const oski_vecview_t y_view, oski_matop_t opA, oski_value_t omega, const oski_vecview_t w_view, oski_value_t zeta, const oski_vecview_t z_view, oski_traceargs_MatMultAndMatTransMult_t *args)
 Initialize a static argument signature for a call to oski_MatMultAndMatTransMult().


Function Documentation

static int MatMultAndMatTransMultDefault const oski_matrix_t  A_tunable,
oski_value_t  alpha,
const oski_vecview_t  x,
oski_value_t  beta,
oski_vecview_t  y,
oski_matop_t  op,
oski_value_t  omega,
const oski_vecview_t  w,
oski_value_t  zeta,
oski_vecview_t  z
[static]
 

A default implementation of simultaneous multiplication by sparse $A$ and $\mathrm{op}(A)$ based on multiple calls to sparse matrix-vector multiply.

This implementation provides a fall-back code in the event that no tuned implementation exists.

Precondition:
A_tunable != INVALID_VEC

int oski_CheckArgsMatMultAndMatTransMult const oski_matrix_t  A_tunable,
oski_value_t  alpha,
const oski_vecview_t  x,
oski_value_t  beta,
oski_vecview_t  y,
oski_matop_t  op,
oski_value_t  omega,
const oski_vecview_t  w,
oski_value_t  zeta,
oski_vecview_t  z,
const char *  caller
 

Verify the arguments to a function with a calling signature like oski_MatMultAndMatTransMult().

Returns:
0 if all arguments are OK, or an error code (plus a call to the error handler) otherwise.


Generated on Wed Sep 19 16:41:21 2007 for BeBOP Optimized Sparse Kernel Interface Library by  doxygen 1.4.6