BeBOP: pOSKI  v1.0.0
parallel Optimized Sparse Kernel Interface library
 All Files Functions Variables
Functions
poski_Partition_common.c File Reference

Commonly used routines in poski_PartitionHandler's routines. More...

#include <stdio.h>
#include <stdlib.h>
#include <poski/poski_common.h>
#include <poski/poski_partitioncommon.h>
#include <poski/poski_threadcommon.h>
#include <poski/poski_kernelcommon.h>
#include <poski/poski_matrixcommon.h>
#include <poski/poski_vectorcommon.h>
#include <poski/poski_malloc.h>
#include <poski/poski_print.h>
#include <poski/poski_permute.h>

Functions

int poski_Init_partitionargs (poski_partitionarg_t *dst, poski_partitionarg_t *src, poski_int_t nthreads)
 [library's internal use] Initialize or copy a partition object.
int poski_Initpartitionmat (poski_partitionmat_t *partitionmat)
 [library's internal use] Initialize a partition-matrix object.
static poski_int_t poski_adjust_npartition (poski_int_t npartitions, poski_index_t nrows)
 [library's internal use] Adjust the number of partitions.
int poski_Adjust_args (poski_partitiontype_t ptype, poski_int_t *npartitions, poski_int_t *nthreads, poski_index_t nrows, poski_index_t ncols, poski_index_t nnz)
 [library's internal use] Adjust the number of threads and partitions.
poski_subvec_t * poski_PartitionVec (poski_value_t *vec, poski_index_t length, poski_int_t inc, poski_partitionvec_t *partitionvec)
 [library's internal use] Create a partition-subvector object.
poski_partitionmat_funcpt poski_find_partitionmat_funcpt (poski_threadtype_t ttype, poski_partitiontype_t ptype)
 [library's internal use] Find the appropriate function pointer for partitioning a matrix.
poski_partitionvec_funcpt poski_find_partitionvec_funcpt (poski_threadtype_t ttype, poski_partitiontype_t ptype, poski_kernel_t kernel, poski_operation_t op, poski_vecprop_t vecprop)
 [library's internal use] Find the appropriate function pointer for partitioning a vector.
char * poski_findpartitiontype (poski_partitiontype_t ptype)
 [library's internal use] Find the partitioning model type for reporing.
int poski_Check_partitionargs (poski_partitionarg_t *partitionargs)
 [library's internal use] Error-checking for partition object.
int poski_Check_numpartitions (poski_int_t npartitions)
 [library's internal use] Error-checking for the number of partitions.
int poski_Check_partitioningmodeltype (poski_partitiontype_t ptype)
 [library's internal use] Error-checking for a partitioning model type.
int poski_Check_partitionvec (poski_partitionvec_t *partitionvec)
 [library's internal use] Error-checking for a partition-vector object.
int poski_Check_partitionedVec (poski_mat_t A, poski_vec_t vec, poski_kernel_t kernel, poski_operation_t op, poski_vecprop_t vecprop)
 [library's internal use] Error-checking input parameters for creating a partition-vector object.
int poski_report_partitionmodel (poski_partitionarg_t *partitionargs, poski_mat_t A)
 Report information of partitioning model.
void poski_report_partitioned (poski_partitionmat_t *partitionmat)
 Report information of a single partition-matrix object.
void poski_report_allpartitioned (poski_partitionmat_t *partitionmat)
 Report information of all partition-matrix object.
void poski_report_partitionvec (poski_partitionvec_t *partitionvec)
 Report information of a partition-vector object.
int poski_report_partitionmat_va (poski_partitionmat_t *partitionmat, poski_int_t pid)
 Report information of a partition-matrix object.
int poski_report_partitionmat (poski_submat_t *submat, poski_int_t npartitions)
 Report information of a partition-matrix object.

Detailed Description

Commonly used routines in poski_PartitionHandler's routines.

Attention:
These routines are usually for the library's internal use and should not normally be called directly by users.
Called by poski_PartitionHandler.c

Also, refer poski_Partition_OneD.c, poski_Partition_SemiOneD.c


Function Documentation

int poski_report_partitionmodel ( poski_partitionarg_t *  partitionargs,
poski_mat_t  A 
)

Report information of partitioning model.

Parameters:
[in]partitionargsPartition object.
[in]ATunable matrix object.
Returns:
1 if success, or an error message otherwise.
void poski_report_partitioned ( poski_partitionmat_t *  partitionmat)

Report information of a single partition-matrix object.

Parameters:
[in]partitionmatPartition-matrix object.
void poski_report_allpartitioned ( poski_partitionmat_t *  partitionmat)

Report information of all partition-matrix object.

Parameters:
[in]partitionmatPartition-matrix object.
void poski_report_partitionvec ( poski_partitionvec_t *  partitionvec)

Report information of a partition-vector object.

Parameters:
[in]partitionvecPartition-vector object.
int poski_report_partitionmat_va ( poski_partitionmat_t *  partitionmat,
poski_int_t  pid 
)

Report information of a partition-matrix object.

Parameters:
[in]partitionmatA single partition-matrix object.
[in]pidSpecified partitions.
Returns:
0 if success, or an error message otherwise.
int poski_report_partitionmat ( poski_submat_t *  submat,
poski_int_t  npartitions 
)

Report information of a partition-matrix object.

Parameters:
[in]submatA submatrix object.
[in]npartitionsNumber of partitions.
Returns:
0 if success, or an error message otherwise.