|
ScaLAPACK
2.0.2
ScaLAPACK: Scalable Linear Algebra PACKage
|
#include "Bdef.h"Go to the source code of this file.
Functions/Subroutines | |
| void | Cblacs_pinfo (int *mypnum, int *nprocs) |
| void Cblacs_pinfo | ( | int * | mypnum, |
| int * | nprocs | ||
| ) |
Definition at line 4 of file blacs_pinfo_.c.
{
int ierr;
extern int BI_Iam, BI_Np;
int argc=0;
char **argv=NULL;
if (BI_COMM_WORLD == NULL)
{
MPI_Initialized(nprocs);
if (!(*nprocs))
ierr = MPI_Init(&argc,&argv); // call Init and ignore argc and argv
BI_COMM_WORLD = (int *) malloc(sizeof(int));
*BI_COMM_WORLD = MPI_Comm_c2f(MPI_COMM_WORLD);
MPI_Comm_size(MPI_COMM_WORLD, &BI_Np);
MPI_Comm_rank(MPI_COMM_WORLD, &BI_Iam);
}
*mypnum = BI_Iam;
*nprocs = BI_Np;
}