single precision
[GPU kernels for non-symmetric sparse LA]

Functions

magma_int_t magma_sbajac_csr (magma_int_t localiters, magma_s_sparse_matrix D, magma_s_sparse_matrix R, magma_s_vector b, magma_s_vector *x)
 This routine is a block-asynchronous Jacobi iteration performing s local Jacobi-updates within the block.
magma_int_t magma_sbcsrvalcpy (magma_int_t size_b, magma_int_t num_blocks, magma_int_t num_zblocks, float **Aval, float **Bval, float **Bval2)
 For a Block-CSR ILU factorization, this routine copies the filled blocks from the original matrix A and initializes the blocks that will later be filled in the factorization process with zeros.
magma_int_t magma_sbcsrluegemm (magma_int_t size_b, magma_int_t num_brows, magma_int_t kblocks, float **dA, float **dB, float **dC)
 For a Block-CSR ILU factorization, this routine updates all blocks in the trailing matrix.
magma_int_t magma_sbcsrlupivloc (magma_int_t size_b, magma_int_t kblocks, float **dA, magma_int_t *ipiv)
 For a Block-CSR ILU factorization, this routine updates all blocks in the trailing matrix.
magma_int_t magma_sbcsrswp (magma_int_t r_blocks, magma_int_t size_b, magma_int_t *ipiv, float *x)
 For a Block-CSR ILU factorization, this routine swaps rows in the vector *x according to the pivoting in *ipiv.
magma_int_t magma_sbcsrtrsv (magma_uplo_t uplo, magma_int_t r_blocks, magma_int_t c_blocks, magma_int_t size_b, float *A, magma_index_t *blockinfo, float *x)
 For a Block-CSR ILU factorization, this routine performs the triangular solves.
void magma_scompact (magma_int_t m, magma_int_t n, float *dA, magma_int_t ldda, float *dnorms, float tol, magma_index_t *active, magma_index_t *cBlock)
 ZCOMPACT takes a set of n vectors of size m (in dA) and their norms and compacts them into the cBlock size<=n vectors that have norms > tol.
magma_int_t magma_sjacobisetup_vector_gpu (int num_rows, float *b, float *d, float *c, float *x)
 Prepares the Jacobi Iteration according to x^(k+1) = D^(-1) * b - D^(-1) * (L+U) * x^k x^(k+1) = c - M * x^k.
magma_int_t magma_slobpcg_maxpy (magma_int_t num_rows, magma_int_t num_vecs, float *X, float *Y)
 This routine computes a axpy for a mxn matrix:.
int magma_sbicgmerge1 (int n, float *skp, float *v, float *r, float *p)
 Mergels multiple operations into one kernel:.
int magma_sbicgmerge2 (int n, float *skp, float *r, float *v, float *s)
 Mergels multiple operations into one kernel:.
int magma_sbicgmerge3 (int n, float *skp, float *p, float *s, float *t, float *x, float *r)
 Mergels multiple operations into one kernel:.
int magma_sbicgmerge4 (int type, float *skp)
 Performs some parameter operations for the BiCGSTAB with scalars on GPU.
magma_int_t magma_sbicgmerge_spmv1 (magma_s_sparse_matrix A, float *d1, float *d2, float *d_p, float *d_r, float *d_v, float *skp)
 Merges the first SpmV using CSR with the dot product and the computation of alpha.
magma_int_t magma_sbicgmerge_spmv2 (magma_s_sparse_matrix A, float *d1, float *d2, float *d_s, float *d_t, float *skp)
 Merges the second SpmV using CSR with the dot product and the computation of omega.
magma_int_t magma_sbicgmerge_xrbeta (int n, float *d1, float *d2, float *rr, float *r, float *p, float *s, float *t, float *x, float *skp)
 Merges the second SpmV using CSR with the dot product and the computation of omega.
magma_int_t magma_scgmerge_spmv1 (magma_s_sparse_matrix A, float *d1, float *d2, float *d_d, float *d_z, float *skp)
 Merges the first SpmV using different formats with the dot product and the computation of rho.

Function Documentation

magma_int_t magma_sbajac_csr ( magma_int_t  localiters,
magma_s_sparse_matrix  D,
magma_s_sparse_matrix  R,
magma_s_vector  b,
magma_s_vector *  x 
)

This routine is a block-asynchronous Jacobi iteration performing s local Jacobi-updates within the block.

Input format is two CSR matrices, one containing the diagonal blocks, one containing the rest.

Parameters:
localiters magma_int_t number of local Jacobi-like updates
D magma_s_sparse_matrix input matrix with diagonal blocks
R magma_s_sparse_matrix input matrix with non-diagonal parts
b magma_s_vector RHS
x magma_s_vector* iterate/solution
magma_int_t magma_sbcsrluegemm ( magma_int_t  size_b,
magma_int_t  num_brows,
magma_int_t  kblocks,
float **  dA,
float **  dB,
float **  dC 
)

For a Block-CSR ILU factorization, this routine updates all blocks in the trailing matrix.

Parameters:
size_b magma_int_t blocksize in BCSR
num_brows magma_int_t number of block rows
kblocks magma_int_t number of blocks in row
dA float** input blocks of matrix A
dB float** input blocks of matrix B
dC float** output blocks of matrix C
magma_int_t magma_sbcsrlupivloc ( magma_int_t  size_b,
magma_int_t  kblocks,
float **  dA,
magma_int_t *  ipiv 
)

For a Block-CSR ILU factorization, this routine updates all blocks in the trailing matrix.

Parameters:
size_b magma_int_t blocksize in BCSR
kblocks magma_int_t number of blocks
dA float** matrix in BCSR
ipiv magma_int_t* array containing pivots
magma_int_t magma_sbcsrswp ( magma_int_t  r_blocks,
magma_int_t  size_b,
magma_int_t *  ipiv,
float *  x 
)

For a Block-CSR ILU factorization, this routine swaps rows in the vector *x according to the pivoting in *ipiv.

Parameters:
r_blocks magma_int_t number of blocks
size_b magma_int_t blocksize in BCSR
ipiv magma_int_t* array containing pivots
x float* input/output vector x
magma_int_t magma_sbcsrtrsv ( magma_uplo_t  uplo,
magma_int_t  r_blocks,
magma_int_t  c_blocks,
magma_int_t  size_b,
float *  A,
magma_index_t *  blockinfo,
float *  x 
)

For a Block-CSR ILU factorization, this routine performs the triangular solves.

Parameters:
uplo magma_uplo_t upper/lower fill structure
r_blocks magma_int_t number of blocks in row
c_blocks magma_int_t number of blocks in column
size_b magma_int_t blocksize in BCSR
A float* upper/lower factor
blockinfo magma_int_t* array containing matrix information
x float* input/output vector x
magma_int_t magma_sbcsrvalcpy ( magma_int_t  size_b,
magma_int_t  num_blocks,
magma_int_t  num_zblocks,
float **  Aval,
float **  Bval,
float **  Bval2 
)

For a Block-CSR ILU factorization, this routine copies the filled blocks from the original matrix A and initializes the blocks that will later be filled in the factorization process with zeros.

Parameters:
size_b magma_int_t blocksize in BCSR
num_blocks magma_int_t number of nonzero blocks
num_zblocks magma_int_t number of zero-blocks (will later be filled)
Aval float** pointers to the nonzero blocks in A
Bval float** pointers to the nonzero blocks in B
Bval2 float** pointers to the zero blocks in B
int magma_sbicgmerge1 ( int  n,
float *  skp,
float *  v,
float *  r,
float *  p 
)

Mergels multiple operations into one kernel:.

p = beta*p p = p-omega*beta*v p = p+r

-> p = r + beta * ( p - omega * v )

Parameters:
n int dimension n
skp float* set of scalar parameters
v float* input v
r float* input r
p float* input/output p
int magma_sbicgmerge2 ( int  n,
float *  skp,
float *  r,
float *  v,
float *  s 
)

Mergels multiple operations into one kernel:.

s=r s=s-alpha*v

-> s = r - alpha * v

Parameters:
n int dimension n
skp float* set of scalar parameters
r float* input r
v float* input v
s float* input/output s
int magma_sbicgmerge3 ( int  n,
float *  skp,
float *  p,
float *  s,
float *  t,
float *  x,
float *  r 
)

Mergels multiple operations into one kernel:.

x=x+alpha*p x=x+omega*s r=s r=r-omega*t

-> x = x + alpha * p + omega * s -> r = s - omega * t

Parameters:
n int dimension n
skp float* set of scalar parameters
p float* input p
s float* input s
t float* input t
x float* input/output x
r float* input/output r
int magma_sbicgmerge4 ( int  type,
float *  skp 
)

Performs some parameter operations for the BiCGSTAB with scalars on GPU.

Parameters:
type int kernel type
skp float* vector with parameters
magma_int_t magma_sbicgmerge_spmv1 ( magma_s_sparse_matrix  A,
float *  d1,
float *  d2,
float *  d_p,
float *  d_r,
float *  d_v,
float *  skp 
)

Merges the first SpmV using CSR with the dot product and the computation of alpha.

Parameters:
A magma_s_sparse_matrix system matrix
d1 float* temporary vector
d2 float* temporary vector
d_p float* input vector p
d_r float* input vector r
d_v float* output vector v
skp float* array for parameters ( skp[0]=alpha )
magma_int_t magma_sbicgmerge_spmv2 ( magma_s_sparse_matrix  A,
float *  d1,
float *  d2,
float *  d_s,
float *  d_t,
float *  skp 
)

Merges the second SpmV using CSR with the dot product and the computation of omega.

Parameters:
A magma_s_sparse_matrix input matrix
d1 float* temporary vector
d2 float* temporary vector
d_s float* input vector s
d_t float* output vector t
skp float* array for parameters
magma_int_t magma_sbicgmerge_xrbeta ( int  n,
float *  d1,
float *  d2,
float *  rr,
float *  r,
float *  p,
float *  s,
float *  t,
float *  x,
float *  skp 
)

Merges the second SpmV using CSR with the dot product and the computation of omega.

Parameters:
n int dimension n
d1 float* temporary vector
d2 float* temporary vector
rr float* input vector rr
r float* input/output vector r
p float* input vector p
s float* input vector s
t float* input vector t
x float* output vector x
skp float* array for parameters
magma_int_t magma_scgmerge_spmv1 ( magma_s_sparse_matrix  A,
float *  d1,
float *  d2,
float *  d_d,
float *  d_z,
float *  skp 
)

Merges the first SpmV using different formats with the dot product and the computation of rho.

Parameters:
A magma_s_sparse_matrix input matrix
d1 float* temporary vector
d2 float* temporary vector
d_d float* input vector d
d_z float* input vector z
skp float* array for parameters ( skp[3]=rho )
void magma_scompact ( magma_int_t  m,
magma_int_t  n,
float *  dA,
magma_int_t  ldda,
float *  dnorms,
float  tol,
magma_index_t *  active,
magma_index_t *  cBlock 
)

ZCOMPACT takes a set of n vectors of size m (in dA) and their norms and compacts them into the cBlock size<=n vectors that have norms > tol.

The active mask array has 1 or 0, showing if a vector remained or not in the compacted resulting set of vectors.

Parameters:
[in] m INTEGER The number of rows of the matrix dA. M >= 0.
[in] n INTEGER The number of columns of the matrix dA. N >= 0.
[in,out] dA COMPLEX REAL array, dimension (LDDA,N) The m by n matrix dA.
[in] ldda INTEGER The leading dimension of the array dA. LDDA >= max(1,M).
[in] dnorms REAL array, dimension N The norms of the N vectors in dA
[in] tol DOUBLE PRECISON The tolerance value used in the criteria to compact or not.
[out] active INTEGER array, dimension N A mask of 1s and 0s showing if a vector remains or has been removed
[out] cBlock magma_index_t* The number of vectors that remain in dA (i.e., with norms > tol).
magma_int_t magma_sjacobisetup_vector_gpu ( int  num_rows,
float *  b,
float *  d,
float *  c,
float *  x 
)

Prepares the Jacobi Iteration according to x^(k+1) = D^(-1) * b - D^(-1) * (L+U) * x^k x^(k+1) = c - M * x^k.

Returns the vector c. It calls a GPU kernel

Parameters:
num_rows magma_int_t number of rows
b magma_s_vector RHS b
d magma_s_vector vector with diagonal entries
c magma_s_vector* c = D^(-1) * b
x magma_s_vector* iteration vector
magma_int_t magma_slobpcg_maxpy ( magma_int_t  num_rows,
magma_int_t  num_vecs,
float *  X,
float *  Y 
)

This routine computes a axpy for a mxn matrix:.

Y = X + Y

It replaces: magma_saxpy(m*n, c_one, Y, 1, X, 1);

/ x1[0] x2[0] x3[0] \ | x1[1] x2[1] x3[1] | X = | x1[2] x2[2] x3[2] | = x1[0] x1[1] x1[2] x1[3] x1[4] x2[0] x2[1] . | x1[3] x2[3] x3[3] | \ x1[4] x2[4] x3[4] /

Parameters:
num_rows magma_int_t number of rows
num_vecs magma_int_t number of vectors
X float* input vector X
Y float* input/output vector Y

Generated on 17 Sep 2014 for MAGMA by  doxygen 1.6.1