Sei sulla pagina 1di 2

C Interface

Initialization Informational and Miscellaneous


void Cblacs_pinfo ( int *mypnum, int *nprocs ) void Cblacs gridinfo( int icontxt, int *nprow, int *npcol, int *myprow, int *mypcol )
void Cblacs_setup ( int *mypnum, int *nprocs ) int Cblacs pnum ( int icontxt, int prow, int pcol )
void Cblacs_get ( int icontxt, int what, int *val ) void Cblacs pcoord ( int icontxt, int pnum, int *prow, int *pcol )
void Cblacs_set ( int icontxt, int what, int *val ) void Cblacs barrier( int icontxt, char *scope )
void Cblacs_gridinit( int *icontxt, char *order, int nprow, int npcol )
void Cblacs_gridmap ( int *icontxt, int *pmap, int ldpmap, int nprow, int npcol ) Non-standard
Destruction void
double
Csetpvmtids (
Cdcputime00 (
int
)
ntasks, int *tids )

void Cblacs_freebuff( int icontxt, int wait ) double Cdwalltime00( )


void Cblacs_gridexit( int icontxt ) int Cksendid ( int icontxt, int rdest, int cdest )
void Cblacs_abort ( int icontxt, int errornum ) int Ckrecvid ( int icontxt, int rsrc, int csrc )
void Cblacs_exit ( int doneflag ) int Ckbsid ( int icontxt, char *scope )
int Ckbrid ( int icontxt, char *scope, int rsrc, int csrc )

Sending
2
void C gesd2d( int icontxt, int m, int n, TYPE *A, int lda, int rdest, int cdest )

2
void C gebs2d( int icontxt, char *scope, char *top, int m, int n, TYPE *A, int lda )

2
void C trsd2d( int icontxt, char *uplo, char *diag, int m, int n, TYPE *A, int lda, int rdest, int cdest )

2
void C trbs2d( int icontxt, char *scope, char *top, char *uplo, char *diag, int m, int n, TYPE *A, int lda)

Receiving
2
void C gerv2d( int icontxt, int m, int n, TYPE *A, int lda, int rsrc, int csrc )

2
void C gebr2d( int icontxt, char *scope, char *top, int m, int n, TYPE *A, int lda, int rsrc, int csrc )

2
void C trrv2d( int icontxt, char *uplo, char *diag, int m, int n, TYPE *A, int lda, int rsrc, int csrc )

2
void C trbr2d( int icontxt, char *scope, char *top, char *uplo, char *diag, int m, int n, TYPE *A, int lda, int rsrc, int csrc )

Combine Operations
2
void C gamx2d( int icontxt, char *scope, char *top, int m, int n, TYPE *A, int lda, int *RA, int *CA, int RCflag, int rdest, int cdest )

2
void C gamn2d( int icontxt, char *scope, char *top, int m, int n, TYPE *A, int lda, int *RA, int *CA, int RCflag, int rdest, int cdest )

2
void C gsum2d( int icontxt, char *scope, char *top, int m, int n, TYPE *A, int lda, int rdest, int cdest )

De nition of 2 Options
2is Data operated on is TYPE is
s single precision real float
UPLO = "Upper triangular", "Lower triangular";
d double precision real double
DIAG
SCOPE
=
=
"Non-unit triangular", "Unit triangular";
"All", "row", "column";
c single precision complex float
TOP = (SEE DESCRIPTION BELOW).
z double precision complex double
i integer int
Broadcast Topologies Key Ideas:
TOP =
=
=
" "
"I"
"D"
:
System dependent default topology;
:
increasing ring;
:
decreasing ring;
A BLACS context is created via a call to either
Cblacs gridinit or Cblacs gridmap. No routine requir-
ing a context may be used until one of these routines
Basic
Linear
= "H" :
hypercube (minimum spanning tree); has been called. Multiple calls to Cblacs gridinit or
= "S" :
split-ring; Cblacs gridmap result in the creation of new contexts. To
= "F" :
fully connected; preserve resources, the user should free unused contexts by
= "M" :
nodes divided into I increasing calling Cblacs gridexit. When all BLACS operations are
done, a call to Cblacs exit frees any remaining contexts,

Algebra
rings, where I is set with call
to Cblacs_set; and shuts down all BLACS operations.
= "T" : tree broadcast with NBRANCHES = I, Please note that Cblacs gridinit and Cblacs gridmap ac-
where I is set with call to cept system contexts as input. A default system context
Cblacs_set; encompassing all available processes may be obtained by a
call to Cblacs get.

Communication
= "1" : tree broadcast with NBRANCHES = 1;
= "2" : tree broadcast with NBRANCHES = 2;
. Cblacs set can only be used to set the BLACS' message ID
.
. range before the creation of the rst context. Subsequent
= "9" : tree broadcast with NBRANCHES = 9. calls will be ignored.

Global Topologies
TOP = " " : System dependent default topology;
Topology Hints
Topologies allow the user to optimize communication pat-
terns for a particular operation. If the user does not have
Subprograms
= "1" : tree gather with NBRANCHES = 1; a communication pipe to maintain, the default TOP = "
= "2" : tree gather with NBRANCHES = 2; " is recommended. For more details, examine the mosaic Quick Reference Guide,
.
. page or the papers referenced below. C Interface
.
= "9"
= "T"
: tree gather with NBRANCHES = 9;
: tree gather with NBRANCHES = I,
References
Release 1.0
where I is set with call to
R. Clint Whaley, LAPACK, Working Note 73, Basic Linear
Cblacs_set;
Algebra Communication Subprograms: Analysis and Im-
= "F" : Fully connected;
plementation Across Multiple Parallel Architectures, Com- February 14, 1995
= "H" : if rdest = -1, a specialized
puter Science Dept. Technical Report CS-94-234, Uni-
"leave on all" hypercube topology
versity of Tennessee, Knoxville, May, 1994. To receive a
called bidirectional exchange is used.
postscript copy, send email to netlib@ornl.gov and in the
Otherwise, TOP = "1" is substituted.
mail message type: send lawn73.ps from lapack/lawns. University of Tennessee

To get the user's guide to the BLACS, send email to


Notation netlib@ornl.gov and in the mail message type: send
blacs ug.ps from blacs. (Can also be downloaded via
Underlined parameters are output arguments. If a mosaic). Obtaining the BLACS
routine is underlined it is a function that returns a
value. The pre x p usually stands for process. Other Reference, examples, troubleshooting, downloading options mosaic: 
http://www.cs.utk.edu/ rwhaley/Blacs.html
standard notations are: and installation instructions are available on mosaic. The ftp: netlib2.cs.utk.edu , directory blacs/
GE - GENERAL TR - TRAPEZOIDAL URL is http://www.cs.utk.edu/~rwhaley/Blacs.html
SD - SEND BS - BROADCAST/SEND email: netlib@ornl.gov with the message send index
RV - RECEIVE BR - BROADCAST/RECEIVE from blacs
GAMX - General element-wise Absolute value MAXIMUM Send comments and questions to blacs@cs.utk.edu .
GAMN - General element-wise Absolute value MINIMUM
GSUM - General element-wise SUMMATION

Potrebbero piacerti anche