aboutsummaryrefslogtreecommitdiff
path: root/src/Misc.c
blob: 9c77b8c2d28b9181ebd4e22222e4cd6f59bab098 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#include "CactusPUGH/PUGH/src/include/pugh.h"


int CCTKtoMPItype(int cctktype)
{
  int mpitype;
  switch (cctktype) {

  case CCTK_VARIABLE_CHAR:
      mpitype  = PUGH_MPI_CHAR;
      break;

  case CCTK_VARIABLE_INT:
    mpitype = PUGH_MPI_INT;
    break;

  case CCTK_VARIABLE_REAL:
    mpitype = PUGH_MPI_REAL;
    break;

  default:
    printf("Unsupported MPI variable type in Hyperslab\n");
    mpitype = -1;
  }
  
  return(mpitype);
}