Actual source code: f90_rs6000.h

  2: #if !defined (__F90_RS6000_H)

  5: typedef struct {
  6:   long lower;   /* starting index of the fortran array */
  7:   long extent;  /* length of the array */
  8:   long mult;    /* in bytes */
  9: } tripple;

 11: /*
 12:   The following constants are just
 13:   guesses. The program behavies strangly
 14:   if these constants are not set in
 15:   the f90 pointer
 16: */
 17: #define F90_CHAR_ID    770
 18: #define F90_INT_ID     781
 19: #define F90_DOUBLE_ID  782
 20: #define F90_COMPLEX_ID 783
 21: #define F90_COOKIE     20481

 23: #if !defined (PETSC_COMPLEX)
 24: #define F90_SCALAR_ID F90_DOUBLE_ID
 25: #else
 26: #define F90_SCALAR_ID F90_COMPLEX_ID
 27: #endif

 29: #define f90_header() \
 30: void* addr;    /* Pointer to the data/array */ \
 31: short id;      /* integer id representing the datatype */ \
 32: short cookie;  /* a wiered f90 cookie */ \
 33: int   sd;      /* sizeof(DataType) */          \
 34: int   ndim;    /* No of dimentions */          \
 35: int   sum_d;   /* -sumof(lower*mult) */

 37: typedef struct {
 38:   f90_header()
 39:   tripple dim[1];
 40: }F90Array1d;

 42: typedef struct {
 43:   f90_header()
 44:   tripple dim[2];   /* dim2,dim1 */
 45: }F90Array2d;

 47: typedef struct {
 48:   f90_header()
 49:   tripple dim[3];   /* dim3,dim2,dim1 */
 50: }F90Array3d;

 52: typedef struct {
 53:   f90_header()
 54:   tripple dim[4];   /* dim4,dim3,dim2,dim1 */
 55: }F90Array4d;

 57: #endif