File: BI_Unpack.c

package info (click to toggle)
blacs-mpi 1.1-28.2
  • links: PTS
  • area: main
  • in suites: squeeze
  • size: 2,320 kB
  • ctags: 2,031
  • sloc: fortran: 14,968; ansic: 12,353; makefile: 531; sh: 1
file content (16 lines) | stat: -rw-r--r-- 454 bytes parent folder | download | duplicates (9)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#include "Bdef.h"

void BI_Unpack(BLACSCONTEXT *ctxt, BVOID *A, BLACBUFF *bp, BI_MPI_Datatype Dtype)
{
   int i=0, info, one=1;

/*
 * Some versions of mpich and its derivitives cannot handle 0 byte typedefs,
 * so we have set MPI_BYTE as a flag for a 0 byte message
 */
#ifdef ZeroByteTypeBug
   if (Dtype == BI_MPI_BYTE) return;
#endif
   BI_MPI_Unpack(bp->Buff, bp->Len, &i, A, one, Dtype, ctxt->scp->comm, info);
   BI_MPI_Type_free(&Dtype, info);
}