psblas3-mcbind:
cbind/base/psb_base_cbind.h cbind/base/psb_c_cbase.h cbind/base/psb_c_dcomm.c cbind/base/psb_c_dcomm.h cbind/base/psb_c_sbase.h cbind/base/psb_c_zbase.h Fix C prototypes. Start writing COMM interfaces.psblas3-mcbind
parent
e30cafaf11
commit
55bc44368b
@ -0,0 +1,39 @@
|
||||
#include <stdlib.h>
|
||||
#include "psb_c_dbase.h"
|
||||
|
||||
psb_c_dvector* psb_c_new_dvector()
|
||||
{
|
||||
psb_c_dvector* temp;
|
||||
|
||||
temp=(psb_c_dvector *) malloc(sizeof(psb_c_dvector));
|
||||
temp->dvector=NULL;
|
||||
return(temp);
|
||||
}
|
||||
|
||||
psb_d_t* psb_c_dvect_get_cpy(psb_c_dvector *xh)
|
||||
{
|
||||
psb_d_t *temp=NULL;
|
||||
psb_i_t vsize=0;
|
||||
|
||||
if ((vsize=psb_c_dvect_get_nrows(xh))<0)
|
||||
return(temp);
|
||||
|
||||
if (vsize==0)
|
||||
vsize=1;
|
||||
|
||||
if ((temp=(psb_d_t *)malloc(vsize*sizeof(psb_d_t)))!=NULL)
|
||||
psb_c_dvect_f_get_cpy(temp,xh);
|
||||
|
||||
return(temp);
|
||||
|
||||
}
|
||||
|
||||
|
||||
psb_c_dspmat* psb_c_new_dspmat()
|
||||
{
|
||||
psb_c_dspmat* temp;
|
||||
|
||||
temp=(psb_c_dspmat *) malloc(sizeof(psb_c_dspmat));
|
||||
temp->dspmat=NULL;
|
||||
return(temp);
|
||||
}
|
@ -0,0 +1,18 @@
|
||||
#ifndef PSB_C_DCOMM_
|
||||
#define PSB_C_DCOMM_
|
||||
#include "psb_c_dbase.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
psb_i_t psb_c_dvscatter(psb_c_dvector *xh, psb_c_descriptor *cdh);
|
||||
psb_d_t* psb_c_dvgather(psb_c_dvector *xh, psb_c_descriptor *cdh);
|
||||
psb_c_dspmat* psb_c_dspgather(psb_c_dspmat *ah, psb_c_descriptor *cdh);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#endif
|
Loading…
Reference in New Issue