ScaLAPACK 2.1  2.1
ScaLAPACK: Scalable Linear Algebra PACKage
Bdef.h File Reference
#include "Bconfig.h"
Include dependency graph for Bdef.h:

Go to the source code of this file.

Data Structures

struct  bLaCsScOpE
 
struct  bLaCsCoNtExT
 
struct  DCOMPLEX
 
struct  SCOMPLEX
 
struct  bLaCbUfF
 

Macros

#define BI_DistType   unsigned short
 
#define BI_MpiDistType   MPI_UNSIGNED_SHORT
 
#define BUFFALIGN   8 /* force all buffers to 8 byte alignment */
 
#define BANYNODE   MPI_ANY_SOURCE
 
#define PT2PTID   9976 /* TAG used for point to point */
 
#define NOTINCONTEXT   -1 /* Indicates node called gridmap, but not in grid */
 
#define MAXNCTXT   10 /* initial guess at max # of contexts */
 
#define MAXNSYSCTXT   10 /* initial guess at max # of system context */
 
#define AOPDONE   MPI_REQUEST_NULL
 
#define BUFWAIT   120 /* Length of time to wait for emergency buff */
 
#define NORV   1 /* No receiver (only 1 proc in scoped op) */
 
#define NPOW2   2 /* Number of procs is not a power of 2 */
 
#define BADSCP   3 /* Scope not row, column or all */
 
#define INTEGER   3
 
#define SINGLE   4
 
#define DOUBLE   6
 
#define COMPLEX8   5
 
#define COMPLEX16   7
 
#define FULLCON   0 /* top is fully connected */
 
#define RT_SD   1
 
#define RT_RV   2
 
#define RT_BS   3
 
#define RT_BR   4
 
#define RT_COMB   5
 
#define SGET_SYSCONTXT   0
 
#define SGET_MSGIDS   1
 
#define SGET_DEBUGLVL   2
 
#define SGET_BLACSCONTXT   10
 
#define SGET_NR_BS   11
 
#define SGET_NB_BS   12
 
#define SGET_NR_CO   13
 
#define SGET_NB_CO   14
 
#define SGET_TOPSREPEAT   15
 
#define SGET_TOPSCOHRNT   16
 
#define BVOID   void
 
#define Mlowcase(C)   ( ((C) > 64 && (C) < 91) ? (C) | 32 : (C) )
 
#define Mgridinfo(ctxt, Ng0, nprow0, npcol0, myrow0, mycol0)
 
#define Mpcoord(ctxt, node, prow, pcol)
 
#define Mvpcoord(ctxt, node, prow, pcol)   Mpcoord((ctxt), (node), (prow), (pcol));
 
#define Mkpnum(ctxt, prow, pcol)   ( (prow)*(ctxt)->rscp.Np+(pcol) )
 
#define Mvkpnum(ctxt, prow, pcol)   ( (prow)*(ctxt)->rscp.Np+(pcol) )
 
#define Mscopeid(ctxt)
 
#define MGetConTxt(Context, ctxtptr)
 
#define Mmpierror(ierr, rout, ctxt, line, file)
 
#define ErrPrint
 
#define F_VOID_FUNC   void
 
#define F_INT_FUNC   int
 
#define F_DOUBLE_FUNC   double
 
#define F2C_CharTrans(c)   *(c)
 
#define F_CHAR   char *
 
#define Mpval(para)   (*(para))
 
#define Mpaddress(para)   (para)
 
#define Mwalltime   dwalltime00_
 
#define Rabs(x)   ( (x) < 0 ? (x) * -1 : (x) )
 
#define Cabs(z)   ( (((z).i) < 0 ? ((z).i) * -1 : ((z).i)) + (((z).r) < 0 ? ((z).r) * -1 : ((z).r)) )
 
#define trsize(diag, m, n, bytes, length)
 
#define BI_cmvcopy(m, n, A, lda, buff)   BI_smvcopy(2*(m), (n), (float *) (A), 2*(lda), (float *) (buff))
 
#define BI_cvmcopy(m, n, A, lda, buff)   BI_svmcopy(2*(m), (n), (float *) (A), 2*(lda), (float *) (buff))
 
#define BI_zmvcopy(m, n, A, lda, buff)   BI_dmvcopy(2*(m), (n), (double *) (A), 2*(lda), (double *) (buff))
 
#define BI_zvmcopy(m, n, A, lda, buff)   BI_dvmcopy(2*(m), (n), (double *) (A), 2*(lda), (double *) (buff))
 
#define BI_MPI_TYPE_FREE(t)   MPI_Type_free(t)
 

Typedefs

typedef struct bLaCsScOpE BLACSSCOPE
 
typedef struct bLaCsCoNtExT BLACSCONTEXT
 
typedef struct bLaCbUfF BLACBUFF
 
typedef void(* VVFUNPTR) (int, char *, char *)
 
typedef void(* SDRVPTR) (BLACSCONTEXT *, int, int, BLACBUFF *)
 

Functions

void BI_BlacsWarn (int ConTxt, int line, char *file, char *form,...)
 
void BI_BlacsErr (int ConTxt, int line, char *file, char *form,...)
 
int BI_ContxtNum (BLACSCONTEXT *ctxt)
 

Variables

int * BI_COMM_WORLD
 

Macro Definition Documentation

◆ AOPDONE

#define AOPDONE   MPI_REQUEST_NULL

Definition at line 81 of file Bdef.h.

◆ BADSCP

#define BADSCP   3 /* Scope not row, column or all */

Definition at line 89 of file Bdef.h.

◆ BANYNODE

#define BANYNODE   MPI_ANY_SOURCE

Definition at line 76 of file Bdef.h.

◆ BI_cmvcopy

#define BI_cmvcopy (   m,
  n,
  A,
  lda,
  buff 
)    BI_smvcopy(2*(m), (n), (float *) (A), 2*(lda), (float *) (buff))

Definition at line 290 of file Bdef.h.

◆ BI_cvmcopy

#define BI_cvmcopy (   m,
  n,
  A,
  lda,
  buff 
)    BI_svmcopy(2*(m), (n), (float *) (A), 2*(lda), (float *) (buff))

Definition at line 292 of file Bdef.h.

◆ BI_DistType

#define BI_DistType   unsigned short

Definition at line 72 of file Bdef.h.

◆ BI_MPI_TYPE_FREE

#define BI_MPI_TYPE_FREE (   t)    MPI_Type_free(t)

Definition at line 305 of file Bdef.h.

◆ BI_MpiDistType

#define BI_MpiDistType   MPI_UNSIGNED_SHORT

Definition at line 73 of file Bdef.h.

◆ BI_zmvcopy

#define BI_zmvcopy (   m,
  n,
  A,
  lda,
  buff 
)    BI_dmvcopy(2*(m), (n), (double *) (A), 2*(lda), (double *) (buff))

Definition at line 294 of file Bdef.h.

◆ BI_zvmcopy

#define BI_zvmcopy (   m,
  n,
  A,
  lda,
  buff 
)    BI_dvmcopy(2*(m), (n), (double *) (A), 2*(lda), (double *) (buff))

Definition at line 296 of file Bdef.h.

◆ BUFFALIGN

#define BUFFALIGN   8 /* force all buffers to 8 byte alignment */

Definition at line 75 of file Bdef.h.

◆ BUFWAIT

#define BUFWAIT   120 /* Length of time to wait for emergency buff */

Definition at line 82 of file Bdef.h.

◆ BVOID

#define BVOID   void

Definition at line 136 of file Bdef.h.

◆ Cabs

#define Cabs (   z)    ( (((z).i) < 0 ? ((z).i) * -1 : ((z).i)) + (((z).r) < 0 ? ((z).r) * -1 : ((z).r)) )

Definition at line 270 of file Bdef.h.

◆ COMPLEX16

#define COMPLEX16   7

Definition at line 98 of file Bdef.h.

◆ COMPLEX8

#define COMPLEX8   5

Definition at line 97 of file Bdef.h.

◆ DOUBLE

#define DOUBLE   6

Definition at line 96 of file Bdef.h.

◆ ErrPrint

#define ErrPrint
Value:
{ \
extern int BI_Iam; \
fprintf(stderr, "%d: line %d of file %s\n", BI_Iam, __LINE__, __FILE__); \
}

Definition at line 222 of file Bdef.h.

◆ F2C_CharTrans

#define F2C_CharTrans (   c)    *(c)

Definition at line 246 of file Bdef.h.

◆ F_CHAR

#define F_CHAR   char *

Definition at line 247 of file Bdef.h.

◆ F_DOUBLE_FUNC

#define F_DOUBLE_FUNC   double

Definition at line 234 of file Bdef.h.

◆ F_INT_FUNC

#define F_INT_FUNC   int

Definition at line 233 of file Bdef.h.

◆ F_VOID_FUNC

#define F_VOID_FUNC   void

Definition at line 232 of file Bdef.h.

◆ FULLCON

#define FULLCON   0 /* top is fully connected */

Definition at line 100 of file Bdef.h.

◆ INTEGER

#define INTEGER   3

Definition at line 94 of file Bdef.h.

◆ MAXNCTXT

#define MAXNCTXT   10 /* initial guess at max # of contexts */

Definition at line 79 of file Bdef.h.

◆ MAXNSYSCTXT

#define MAXNSYSCTXT   10 /* initial guess at max # of system context */

Definition at line 80 of file Bdef.h.

◆ MGetConTxt

#define MGetConTxt (   Context,
  ctxtptr 
)
Value:
{\
(ctxtptr) = BI_MyContxts[(Context)];\
}

Definition at line 200 of file Bdef.h.

◆ Mgridinfo

#define Mgridinfo (   ctxt,
  Ng0,
  nprow0,
  npcol0,
  myrow0,
  mycol0 
)
Value:
{\
(Ng0) = (ctxt)->ascp.Np;\
(nprow0) = (ctxt)->cscp.Np;\
(npcol0) = (ctxt)->rscp.Np;\
(myrow0) = (ctxt)->cscp.Iam;\
(mycol0) = (ctxt)->rscp.Iam;\
}

Definition at line 150 of file Bdef.h.

◆ Mkpnum

#define Mkpnum (   ctxt,
  prow,
  pcol 
)    ( (prow)*(ctxt)->rscp.Np+(pcol) )

Definition at line 173 of file Bdef.h.

◆ Mlowcase

#define Mlowcase (   C)    ( ((C) > 64 && (C) < 91) ? (C) | 32 : (C) )

Definition at line 145 of file Bdef.h.

◆ Mmpierror

#define Mmpierror (   ierr,
  rout,
  ctxt,
  line,
  file 
)

Definition at line 217 of file Bdef.h.

◆ Mpaddress

#define Mpaddress (   para)    (para)

Definition at line 262 of file Bdef.h.

◆ Mpcoord

#define Mpcoord (   ctxt,
  node,
  prow,
  pcol 
)
Value:
{\
(prow) = (node) / (ctxt)->rscp.Np;\
(pcol) = (node) % (ctxt)->rscp.Np;\
}

Definition at line 165 of file Bdef.h.

◆ Mpval

#define Mpval (   para)    (*(para))

Definition at line 261 of file Bdef.h.

◆ Mscopeid

#define Mscopeid (   ctxt)
Value:
(ctxt)->scp->ScpId; \
if (++(ctxt)->scp->ScpId == (ctxt)->scp->MaxId) \
(ctxt)->scp->ScpId = (ctxt)->scp->MinId;

Definition at line 179 of file Bdef.h.

◆ Mvkpnum

#define Mvkpnum (   ctxt,
  prow,
  pcol 
)    ( (prow)*(ctxt)->rscp.Np+(pcol) )

Definition at line 174 of file Bdef.h.

◆ Mvpcoord

#define Mvpcoord (   ctxt,
  node,
  prow,
  pcol 
)    Mpcoord((ctxt), (node), (prow), (pcol));

Definition at line 170 of file Bdef.h.

◆ Mwalltime

#define Mwalltime   dwalltime00_

Definition at line 263 of file Bdef.h.

◆ NORV

#define NORV   1 /* No receiver (only 1 proc in scoped op) */

Definition at line 87 of file Bdef.h.

◆ NOTINCONTEXT

#define NOTINCONTEXT   -1 /* Indicates node called gridmap, but not in grid */

Definition at line 78 of file Bdef.h.

◆ NPOW2

#define NPOW2   2 /* Number of procs is not a power of 2 */

Definition at line 88 of file Bdef.h.

◆ PT2PTID

#define PT2PTID   9976 /* TAG used for point to point */

Definition at line 77 of file Bdef.h.

◆ Rabs

#define Rabs (   x)    ( (x) < 0 ? (x) * -1 : (x) )

Definition at line 269 of file Bdef.h.

◆ RT_BR

#define RT_BR   4

Definition at line 108 of file Bdef.h.

◆ RT_BS

#define RT_BS   3

Definition at line 107 of file Bdef.h.

◆ RT_COMB

#define RT_COMB   5

Definition at line 109 of file Bdef.h.

◆ RT_RV

#define RT_RV   2

Definition at line 106 of file Bdef.h.

◆ RT_SD

#define RT_SD   1

Definition at line 105 of file Bdef.h.

◆ SGET_BLACSCONTXT

#define SGET_BLACSCONTXT   10

Definition at line 117 of file Bdef.h.

◆ SGET_DEBUGLVL

#define SGET_DEBUGLVL   2

Definition at line 116 of file Bdef.h.

◆ SGET_MSGIDS

#define SGET_MSGIDS   1

Definition at line 115 of file Bdef.h.

◆ SGET_NB_BS

#define SGET_NB_BS   12

Definition at line 119 of file Bdef.h.

◆ SGET_NB_CO

#define SGET_NB_CO   14

Definition at line 121 of file Bdef.h.

◆ SGET_NR_BS

#define SGET_NR_BS   11

Definition at line 118 of file Bdef.h.

◆ SGET_NR_CO

#define SGET_NR_CO   13

Definition at line 120 of file Bdef.h.

◆ SGET_SYSCONTXT

#define SGET_SYSCONTXT   0

Definition at line 114 of file Bdef.h.

◆ SGET_TOPSCOHRNT

#define SGET_TOPSCOHRNT   16

Definition at line 123 of file Bdef.h.

◆ SGET_TOPSREPEAT

#define SGET_TOPSREPEAT   15

Definition at line 122 of file Bdef.h.

◆ SINGLE

#define SINGLE   4

Definition at line 95 of file Bdef.h.

◆ trsize

#define trsize (   diag,
  m,
  n,
  bytes,
  length 
)
Value:
{\
if ( (diag) == 'u' ) (length) = 1;\
else (length) = 0;\
if ( (m) > (n) )\
(length) = ( (n) * ( (m) - (n) ) + ( (n)*(n) ) - ( (n)*(n) )/2 +\
(n)/2 - (n) * (length) ) * (bytes);\
else\
(length) = ( (m) * ( (n) - (m) ) + ( (m)*(m) ) - ( (m)*(m) )/2 +\
(m)/2 - (m) * (length) ) * (bytes);\
}

Definition at line 275 of file Bdef.h.

Typedef Documentation

◆ BLACBUFF

typedef struct bLaCbUfF BLACBUFF

Definition at line 53 of file Bdef.h.

◆ BLACSCONTEXT

typedef struct bLaCsCoNtExT BLACSCONTEXT

Definition at line 22 of file Bdef.h.

◆ BLACSSCOPE

typedef struct bLaCsScOpE BLACSSCOPE

Definition at line 12 of file Bdef.h.

◆ SDRVPTR

typedef void(* SDRVPTR) (BLACSCONTEXT *, int, int, BLACBUFF *)

Definition at line 69 of file Bdef.h.

◆ VVFUNPTR

typedef void(* VVFUNPTR) (int, char *, char *)

Definition at line 68 of file Bdef.h.

Function Documentation

◆ BI_BlacsErr()

void BI_BlacsErr ( int  ConTxt,
int  line,
char *  file,
char *  form,
  ... 
)

Definition at line 3 of file BI_BlacsErr.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ BI_BlacsWarn()

void BI_BlacsWarn ( int  ConTxt,
int  line,
char *  file,
char *  form,
  ... 
)

Definition at line 3 of file BI_BlacsWarn.c.

Here is the caller graph for this function:

◆ BI_ContxtNum()

int BI_ContxtNum ( BLACSCONTEXT ctxt)

Definition at line 3 of file BI_ContxtNum.c.

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ BI_COMM_WORLD

int* BI_COMM_WORLD

Definition at line 13 of file BI_GlobalVars.c.

BI_Iam
int BI_Iam
Definition: BI_GlobalVars.c:7
bLaCsCoNtExT
Definition: Bdef.h:23
BI_MyContxts
BLACSCONTEXT ** BI_MyContxts
Definition: BI_GlobalVars.c:11