diff options
Diffstat (limited to 'src/RecoverVar.c')
-rw-r--r-- | src/RecoverVar.c | 318 |
1 files changed, 148 insertions, 170 deletions
diff --git a/src/RecoverVar.c b/src/RecoverVar.c index 852a78e..95d9835 100644 --- a/src/RecoverVar.c +++ b/src/RecoverVar.c @@ -20,15 +20,21 @@ #include "CactusPUGH/PUGH/src/include/pugh.h" #include "ioHDF5UtilGH.h" - /* the rcs ID and its dummy function to use it */ static const char *rcsid = "$Id$"; CCTK_FILEVERSION(BetaThorns_IOHDF5Util_RecoverVar_c) -/* MPI tag base */ -#define STARTUPBASE 1001 + +/******************************************************************** + ******************** Macro Definitions ************************ + ********************************************************************/ +/* tag base for MPI messages */ +#define MPITAGBASE 1001 +/******************************************************************** + ******************** Internal Typedefs ************************ + ********************************************************************/ typedef struct { cGH *GH; @@ -42,47 +48,53 @@ typedef struct { iterate_info_t *it_info; int element_size; - int iohdf5_type; + int hdf5type; #ifdef CCTK_MPI MPI_Datatype mpi_type; #endif } recover_info_t; -/* local function prototypes */ -static herr_t processDataset (hid_t group, - const char *datasetname, - void *arg); +/******************************************************************** + ******************** Internal Routines ************************ + ********************************************************************/ +static herr_t processDataset (hid_t group, const char *datasetname, void *arg); /*@@ - @routine IOHDF5Util_RecoverVariables - @date Fri Jun 19 09:19:48 1998 - @author Tom Goodale - @desc - Reads in data from an open HDF5 file. - @enddesc - @var GH - @vdesc Pointer to CCTK grid hierarchy - @vtype cGH * - @vio in - @endvar - @var fileinfo - @vdesc pointer to info structure describing the HDF5 file - @vtype const fileinfo_t * - @vio in - @endvar + @routine IOHDF5Util_RecoverVariables + @date Fri Jun 19 09:19:48 1998 + @author Tom Goodale + @desc + Reads in data from an open HDF5 file. + @enddesc + @var GH + @vdesc Pointer to CCTK grid hierarchy + @vtype cGH * + @vio in + @endvar + @var fileinfo + @vdesc pointer to info structure describing the HDF5 file + @vtype const fileinfo_t * + @vio in + @endvar + + @returntype int + @returndesc + 0 for success + @endreturndesc @@*/ -int IOHDF5Util_RecoverVariables (cGH *GH, - const fileinfo_t *fileinfo) +int IOHDF5Util_RecoverVariables (cGH *GH, const fileinfo_t *fileinfo) { - DECLARE_CCTK_PARAMETERS + iterate_info_t info; #ifdef CCTK_MPI - pGH *pughGH; /* PUGH extension handle */ - int proc; /* looper */ - CCTK_INT var_info[3]; /* communication buffer for MPI */ + pGH *pughGH; + CCTK_INT var_info[3]; + MPI_Status ms; + MPI_Datatype mpi_type; + int vindex, timelevel, proc, npoints; #endif - iterate_info_t info; /* info to pass down to the iterator routine */ + DECLARE_CCTK_PARAMETERS info.GH = GH; @@ -92,12 +104,11 @@ int IOHDF5Util_RecoverVariables (cGH *GH, info.has_version = fileinfo->has_version; #ifdef CCTK_MPI - /* Get the handle for PUGH extensions */ pughGH = PUGH_pGH (GH); - /* Now process the datasets. + /* now process the datasets: All IO processors read the datasets from their checkpoint file, - verify their contents and communicate them to the non-IO processors. */ + verify their contents and communicate them to the non-I/O processors. */ /* At first the code for the IO processors. This holds also for the single processor case. */ @@ -106,7 +117,7 @@ int IOHDF5Util_RecoverVariables (cGH *GH, #endif /* CCTK_MPI */ /* iterate over all datasets starting from "/" in the HDF5 file */ - IOHDF5_ERROR (H5Giterate (fileinfo->file, "/", NULL, processDataset,&info)); + HDF5_ERROR (H5Giterate (fileinfo->file, "/", NULL, processDataset, &info)); #ifdef CCTK_MPI /* To signal completion to the non-IO processors @@ -119,28 +130,23 @@ int IOHDF5Util_RecoverVariables (cGH *GH, proc++) { CACTUS_MPI_ERROR (MPI_Send (var_info, 3, PUGH_MPI_INT, proc, - STARTUPBASE, pughGH->PUGH_COMM_WORLD)); + MPITAGBASE, pughGH->PUGH_COMM_WORLD)); } } else { - - /* And here the code for non-IO processors: */ - MPI_Datatype mpi_type; - MPI_Status ms; - int vindex, timelevel, npoints; - - /* They don't know how many datasets there are, because the IO processors + /* And here the code for non-I/O processors: */ + /* They don't know how many datasets there are, because the I/O processors could skip some on the fly during their consistency checks. - The IO Processor sends the index of the variable to be processed next. - So, all non-IO processors execute a loop where the termination condition + The I/O Processor sends the index of the variable to be processed next. + So, all non-I/O processors execute a loop where the termination condition is when an invalid index was received. */ while (1) { /* receive the next variable index from my IO processor */ CACTUS_MPI_ERROR (MPI_Recv (var_info, 3, PUGH_MPI_INT, fileinfo->ioproc, - STARTUPBASE, pughGH->PUGH_COMM_WORLD, &ms)); + MPITAGBASE, pughGH->PUGH_COMM_WORLD, &ms)); vindex = var_info[0]; timelevel = var_info[1]; npoints = var_info[2]; /* check for termination condition */ @@ -159,7 +165,7 @@ int IOHDF5Util_RecoverVariables (cGH *GH, /* receive following data from my IO processor */ CACTUS_MPI_ERROR (MPI_Recv (GH->data[vindex][timelevel], npoints, - mpi_type, fileinfo->ioproc, STARTUPBASE, + mpi_type, fileinfo->ioproc, MPITAGBASE, pughGH->PUGH_COMM_WORLD, &ms)); } } @@ -172,10 +178,9 @@ int IOHDF5Util_RecoverVariables (cGH *GH, /* NOTE: Although we could read the GH extensions from multiple recovery files in parallel, this is done only on by processor 0 here. Broadcasting the GH extensions is found faster than - sending it in a loop from each IO processor to all the non IOs + sending it in a loop from each I/O processor to all the non I/Os (don't have subcommunicators yet) */ -int IOHDF5Util_RecoverGHextensions (cGH *GH, - const fileinfo_t *fileinfo) +int IOHDF5Util_RecoverGHextensions (cGH *GH, const fileinfo_t *fileinfo) { hid_t group; CCTK_REAL4 real4Buffer; @@ -191,13 +196,11 @@ int IOHDF5Util_RecoverGHextensions (cGH *GH, if (int4Buffer[0]) { + READ_ATTRIBUTE (group, "cctk_iteration", HDF5_INT4, &int4Buffer[1]); + READ_ATTRIBUTE (group, "main_loop_index", HDF5_INT4, &int4Buffer[2]); + READ_ATTRIBUTE (group, "cctk_time", HDF5_REAL4, &real4Buffer); - READ_ATTRIBUTE (group, "cctk_iteration", IOHDF5_INT4, &int4Buffer[1]); - READ_ATTRIBUTE (group, "main_loop_index", IOHDF5_INT4, &int4Buffer[2]); - READ_ATTRIBUTE (group, "cctk_time", IOHDF5_REAL4, &real4Buffer); - - IOHDF5_ERROR (H5Gclose (group)); - + HDF5_ERROR (H5Gclose (group)); } else { @@ -226,7 +229,7 @@ int IOHDF5Util_RecoverGHextensions (cGH *GH, CCTK_SetMainLoopIndex ((int) int4Buffer[2]); } - /* Return 0 for success otherwise negative */ + /* return 0 for success otherwise negative */ return (int4Buffer[0] ? 0 : -1); } @@ -238,19 +241,18 @@ int IOHDF5Util_RecoverGHextensions (cGH *GH, (don't have subcommunicators yet) */ int IOHDF5Util_RecoverParameters (const fileinfo_t *fileinfo) { - DECLARE_CCTK_PARAMETERS hid_t group, attr, atype; char *parameters; CCTK_INT4 parameterSize; - cGH *GH = NULL; /* There's no cGH set up yet so we pass - a NULL pointer to CCTK_MyProc() */ + DECLARE_CCTK_PARAMETERS + /* To make the compiler happy */ group = attr = 0; parameters = NULL; parameterSize = 0; - if (CCTK_MyProc (GH) == 0) + if (CCTK_MyProc (NULL) == 0) { if (verbose) { @@ -268,12 +270,12 @@ int IOHDF5Util_RecoverParameters (const fileinfo_t *fileinfo) if (group > 0 && attr > 0) { - IOHDF5_ERROR (atype = H5Aget_type (attr)); + HDF5_ERROR (atype = H5Aget_type (attr)); parameterSize = H5Tget_size (atype); parameters = (char *) malloc (parameterSize + 1); - IOHDF5_ERROR (H5Aread (attr, atype, parameters)); + HDF5_ERROR (H5Aread (attr, atype, parameters)); parameters[parameterSize] = 0; - IOHDF5_ERROR (H5Tclose (atype)); + HDF5_ERROR (H5Tclose (atype)); } else { @@ -283,11 +285,11 @@ int IOHDF5Util_RecoverParameters (const fileinfo_t *fileinfo) if (attr > 0) { - IOHDF5_ERROR (H5Aclose (attr)); + HDF5_ERROR (H5Aclose (attr)); } if (group > 0) { - IOHDF5_ERROR (H5Gclose (group)); + HDF5_ERROR (H5Gclose (group)); } } @@ -303,7 +305,7 @@ int IOHDF5Util_RecoverParameters (const fileinfo_t *fileinfo) if (parameterSize > 0) { #ifdef CCTK_MPI - if (CCTK_MyProc (GH) != 0) + if (CCTK_MyProc (NULL) != 0) { parameters = (char *) malloc (parameterSize + 1); } @@ -317,14 +319,14 @@ int IOHDF5Util_RecoverParameters (const fileinfo_t *fileinfo) free (parameters); } - /* Return positive value for success otherwise negative */ + /* return positive value for success otherwise negative */ return (parameterSize > 0 ? 1 : -1); } -/************************************************************************/ -/* local routines */ -/************************************************************************/ +/******************************************************************** + ******************** Internal Routines ************************ + ********************************************************************/ /* local routine GetCommonAttributes() reads in the next dataset's attributes and verifies them: @@ -341,7 +343,6 @@ int IOHDF5Util_RecoverParameters (const fileinfo_t *fileinfo) If successful, the global variable index, the group type and the timelevel to restore are stored in {*vindex, *gtype, *timelevel}, and 0 is returned. */ - static int GetCommonAttributes (cGH *GH, hid_t dataset, const char *datasetname, @@ -426,9 +427,9 @@ static int GetCommonAttributes (cGH *GH, if the dataset is a chunk group */ if (is_group) { - IOHDF5_ERROR (dataset = H5Dopen (dataset, "chunk0")); + HDF5_ERROR (dataset = H5Dopen (dataset, "chunk0")); } - IOHDF5_ERROR (datatype = H5Dget_type (dataset)); + HDF5_ERROR (datatype = H5Dget_type (dataset)); /* The CCTK variable type defines do not correlate with the HDF5 defines so compare them explicitely here. */ @@ -444,7 +445,7 @@ static int GetCommonAttributes (cGH *GH, strncmp (CCTK_VarTypeName (group_static_data.vartype), "CCTK_VARIABLE_COMPLEX", 21) == 0); - IOHDF5_ERROR (H5Tclose (datatype)); + HDF5_ERROR (H5Tclose (datatype)); if (! flag) { CCTK_VWarn (2, __LINE__, __FILE__, CCTK_THORNSTRING, @@ -453,44 +454,36 @@ static int GetCommonAttributes (cGH *GH, } /* verify the dims and sizes */ - IOHDF5_ERROR (dataspace = H5Dget_space (dataset)); - IOHDF5_ERROR (ndims_stored = H5Sget_simple_extent_ndims (dataspace)); + HDF5_ERROR (dataspace = H5Dget_space (dataset)); + HDF5_ERROR (ndims_stored = H5Sget_simple_extent_ndims (dataspace)); dims_stored = (hsize_t *) malloc (ndims_stored * sizeof (hsize_t)); - IOHDF5_ERROR (rank_stored = H5Sget_simple_extent_dims (dataspace, + HDF5_ERROR (rank_stored = H5Sget_simple_extent_dims (dataspace, dims_stored, NULL)); /* scalars are stored as rank 0 in HDF5 but have rank 1 in Cactus */ if (rank_stored == 0) { rank_stored = 1; } - IOHDF5_ERROR (H5Sclose (dataspace)); + HDF5_ERROR (H5Sclose (dataspace)); - flag = 0; - if (group_static_data.dim != (int) rank_stored) - { - flag = 1; - } - switch (group_static_data.grouptype) + flag = group_static_data.dim != (int) rank_stored; + if (group_static_data.grouptype == CCTK_ARRAY || + group_static_data.grouptype == CCTK_GF) { - case CCTK_SCALAR: - break; - case CCTK_ARRAY: - case CCTK_GF: - if (CCTK_GroupDynamicData (GH, groupindex, &group_dynamic_data) != 0) - { - CCTK_VWarn (2, __LINE__, __FILE__, CCTK_THORNSTRING, - "Cannot get dynamic group data for '%s'", fullvarname); - return (-1); - } - dims = unchunked ? group_dynamic_data.gsh : group_dynamic_data.lsh; - for (i = 0; i < group_static_data.dim; i++) + if (CCTK_GroupDynamicData (GH, groupindex, &group_dynamic_data) != 0) + { + CCTK_VWarn (2, __LINE__, __FILE__, CCTK_THORNSTRING, + "Cannot get dynamic group data for '%s'", fullvarname); + return (-1); + } + dims = unchunked ? group_dynamic_data.gsh : group_dynamic_data.lsh; + for (i = 0; i < group_static_data.dim; i++) + { + if (dims[group_static_data.dim - i - 1] != (int) dims_stored[i]) { - if (dims[group_static_data.dim - i - 1] != (int) dims_stored[i]) - { - flag = 1; - } + flag = 1; } - break; + } } free (dims_stored); @@ -511,7 +504,7 @@ static int GetCommonAttributes (cGH *GH, /* close the first chunk if the dataset is a chunk group */ if (is_group) { - IOHDF5_ERROR (H5Dclose (dataset)); + HDF5_ERROR (H5Dclose (dataset)); } *grouptype = group_static_data.grouptype; @@ -520,30 +513,27 @@ static int GetCommonAttributes (cGH *GH, } -static int IOHDF5Util_RestoreGS (hid_t dataset, - int vindex, - int timelevel, +static int IOHDF5Util_RestoreGS (hid_t dataset, int vindex, int timelevel, recover_info_t *rec_info) { void *data; #ifdef CCTK_MPI int proc; CCTK_INT var_info[3]; - pGH *pughGH; + MPI_Comm comm; #endif data = CCTK_VarDataPtrI (rec_info->it_info->GH, timelevel, vindex); /* read the data into the local variable ... */ - IOHDF5_ERROR (H5Dread (dataset, rec_info->iohdf5_type, H5S_ALL, H5S_ALL, - H5P_DEFAULT, data)); + HDF5_ERROR (H5Dread (dataset, rec_info->hdf5type, H5S_ALL, H5S_ALL, + H5P_DEFAULT, data)); #ifdef CCTK_MPI /* ... and communicate it for the MPI case */ - /* Get the handle for PUGH extensions */ - pughGH = PUGH_pGH (rec_info->it_info->GH); + comm = PUGH_pGH (rec_info->it_info->GH)->PUGH_COMM_WORLD; /* set the variable's index and the timelevel */ var_info[0] = vindex; var_info[1] = timelevel; var_info[2] = 1; @@ -554,10 +544,10 @@ static int IOHDF5Util_RestoreGS (hid_t dataset, proc < CCTK_nProcs (rec_info->it_info->GH); proc++) { - CACTUS_MPI_ERROR (MPI_Send (var_info, 3, PUGH_MPI_INT, proc, - STARTUPBASE, pughGH->PUGH_COMM_WORLD)); - CACTUS_MPI_ERROR (MPI_Send (data, 1, rec_info->mpi_type, proc, - STARTUPBASE, pughGH->PUGH_COMM_WORLD)); + CACTUS_MPI_ERROR (MPI_Send (var_info, 3, PUGH_MPI_INT, proc, MPITAGBASE, + comm)); + CACTUS_MPI_ERROR (MPI_Send (data, 1, rec_info->mpi_type, proc, MPITAGBASE, + comm)); } #endif /* CCTK_MPI */ @@ -565,26 +555,28 @@ static int IOHDF5Util_RestoreGS (hid_t dataset, } -static int IOHDF5Util_RestoreGA (hid_t dataset, - int vindex, - int timelevel, +static int IOHDF5Util_RestoreGA (hid_t dataset, int vindex, int timelevel, recover_info_t *rec_info) { #ifdef CCTK_MPI - int proc, npoints; + int i, dim, proc, npoints; CCTK_INT var_info[3]; pGH *pughGH; void *buffer, *data; - hid_t filespace, memspace; + hid_t filespace, memspace, chunk; pGExtras *extras; + char chunkname[32]; + hssize_t *chunk_origin; + hsize_t *chunk_dims; #endif /* single processor case is easy: just read the whole dataset */ if (CCTK_nProcs (rec_info->it_info->GH) == 1) { - IOHDF5_ERROR (H5Dread (dataset, rec_info->iohdf5_type, H5S_ALL, - H5S_ALL, H5P_DEFAULT, rec_info->it_info->GH->data[vindex][timelevel])); + HDF5_ERROR (H5Dread (dataset, rec_info->hdf5type, H5S_ALL, H5S_ALL, + H5P_DEFAULT, + rec_info->it_info->GH->data[vindex][timelevel])); return (0); } @@ -628,24 +620,17 @@ static int IOHDF5Util_RestoreGA (hid_t dataset, if (! rec_info->it_info->unchunked) { - hid_t chunk; - char chunkname[32]; - /* Chunked data is stored as separate chunk datasets within a group. So open, read and close the separate chunks here. */ sprintf (chunkname, "chunk%d", proc - rec_info->it_info->ioproc); - IOHDF5_ERROR (chunk = H5Dopen (dataset, chunkname)); - IOHDF5_ERROR (H5Dread (chunk, rec_info->iohdf5_type, H5S_ALL, - H5S_ALL, H5P_DEFAULT, data)); - IOHDF5_ERROR (H5Dclose (chunk)); + HDF5_ERROR (chunk = H5Dopen (dataset, chunkname)); + HDF5_ERROR (H5Dread (chunk, rec_info->hdf5type, H5S_ALL, H5S_ALL, + H5P_DEFAULT, data)); + HDF5_ERROR (H5Dclose (chunk)); } else { - int i, dim; - hssize_t *chunk_origin; - hsize_t *chunk_dims; - /* get the dimension of the variable */ dim = CCTK_GroupDimI (CCTK_GroupIndexFromVarI (vindex)); chunk_origin = (hssize_t *) malloc (dim * sizeof (hssize_t)); @@ -659,16 +644,16 @@ static int IOHDF5Util_RestoreGA (hid_t dataset, chunk_origin[dim - 1 - i] = extras->lb[proc][i]; } - IOHDF5_ERROR (filespace = H5Dget_space (dataset)); - IOHDF5_ERROR (memspace = H5Screate_simple (dim, chunk_dims, NULL)); - IOHDF5_ERROR (H5Sselect_hyperslab (filespace, H5S_SELECT_SET, + HDF5_ERROR (filespace = H5Dget_space (dataset)); + HDF5_ERROR (memspace = H5Screate_simple (dim, chunk_dims, NULL)); + HDF5_ERROR (H5Sselect_hyperslab (filespace, H5S_SELECT_SET, chunk_origin, NULL, chunk_dims, NULL)); - IOHDF5_ERROR (H5Dread (dataset, rec_info->iohdf5_type, memspace, - filespace, H5P_DEFAULT, data)); + HDF5_ERROR (H5Dread (dataset, rec_info->hdf5type, memspace, filespace, + H5P_DEFAULT, data)); - IOHDF5_ERROR (H5Sclose (memspace)); - IOHDF5_ERROR (H5Sclose (filespace)); + HDF5_ERROR (H5Sclose (memspace)); + HDF5_ERROR (H5Sclose (filespace)); free (chunk_dims); free (chunk_origin); @@ -679,9 +664,9 @@ static int IOHDF5Util_RestoreGA (hid_t dataset, { var_info[2] = extras->rnpoints[proc]; CACTUS_MPI_ERROR (MPI_Send (var_info, 3, PUGH_MPI_INT, proc, - STARTUPBASE, pughGH->PUGH_COMM_WORLD)); + MPITAGBASE, pughGH->PUGH_COMM_WORLD)); CACTUS_MPI_ERROR (MPI_Send (data, extras->rnpoints[proc], - rec_info->mpi_type, proc, STARTUPBASE, + rec_info->mpi_type, proc, MPITAGBASE, pughGH->PUGH_COMM_WORLD)); } } @@ -693,20 +678,17 @@ static int IOHDF5Util_RestoreGA (hid_t dataset, } -static herr_t processDataset (hid_t group, - const char *datasetname, - void *arg) +static herr_t processDataset (hid_t group, const char *datasetname, void *arg) { - DECLARE_CCTK_PARAMETERS - pGH *pughGH; ioGH *ioUtilGH; ioHDF5UtilGH *myGH; - int vindex, vtype, gtype, timelevel; + int vindex, vtype, gtype, timelevel, is_group; iterate_info_t *it_info = (iterate_info_t *) arg; recover_info_t rec_info; hid_t dataset; H5G_stat_t object_info; - int is_group; + char *fullname; + DECLARE_CCTK_PARAMETERS /* skip the global attributes and GH extensions groups */ @@ -716,20 +698,15 @@ static herr_t processDataset (hid_t group, return (0); } - /* Get the handle for PUGH, IOUtil, and IOHDF5Util extensions */ - pughGH = PUGH_pGH (it_info->GH); - ioUtilGH = (ioGH *) CCTK_GHExtension (it_info->GH, "IO"); - myGH = (ioHDF5UtilGH *) CCTK_GHExtension (it_info->GH, "IOHDF5Util"); - - IOHDF5_ERROR (H5Gget_objinfo (group, datasetname, 0, &object_info)); + HDF5_ERROR (H5Gget_objinfo (group, datasetname, 0, &object_info)); is_group = object_info.type == H5G_GROUP; if (is_group) { - IOHDF5_ERROR (dataset = H5Gopen (group, datasetname)); + HDF5_ERROR (dataset = H5Gopen (group, datasetname)); } else { - IOHDF5_ERROR (dataset = H5Dopen (group, datasetname)); + HDF5_ERROR (dataset = H5Dopen (group, datasetname)); } /* read in the dataset's attributes and verify them */ @@ -742,42 +719,43 @@ static herr_t processDataset (hid_t group, return (0); } + ioUtilGH = (ioGH *) CCTK_GHExtension (it_info->GH, "IO"); + myGH = (ioHDF5UtilGH *) CCTK_GHExtension (it_info->GH, "IOHDF5Util"); + /* if we read in initial data via the file reader interface check whether the user wants to have this variable restored */ if (ioUtilGH->do_inVars && ! ioUtilGH->do_inVars[vindex]) { if (verbose) { - char *varname = CCTK_FullName (vindex); - + fullname = CCTK_FullName (vindex); CCTK_VInfo (CCTK_THORNSTRING, "Ignoring variable '%s' for file reader " - "recovery", varname); - free (varname); + "recovery", fullname); + free (fullname); } return (0); } if (verbose) { - char *varname = CCTK_FullName (vindex); - + fullname = CCTK_FullName (vindex); CCTK_VInfo (CCTK_THORNSTRING, "Restoring variable '%s' (timelevel %d)", - varname, timelevel); - free (varname); + fullname, timelevel); + free (fullname); } vtype = CCTK_VarTypeI (vindex); rec_info.it_info = it_info; rec_info.element_size = CCTK_VarTypeSize (vtype); #ifdef CCTK_MPI - rec_info.mpi_type = PUGH_MPIDataType (pughGH, vtype); + rec_info.mpi_type = PUGH_MPIDataType (PUGH_pGH (it_info->GH), vtype); #endif - rec_info.iohdf5_type = IOHDF5Util_DataType (myGH, vtype); + rec_info.hdf5type = IOHDF5Util_DataType (myGH, vtype); if (rec_info.element_size <= 0 || #ifdef CCTK_MPI rec_info.mpi_type == MPI_DATATYPE_NULL || #endif - rec_info.iohdf5_type < 0) + rec_info.hdf5type < 0) { CCTK_VWarn (1, __LINE__, __FILE__, CCTK_THORNSTRING, "Unsupported variable datatype %d", vtype); @@ -802,11 +780,11 @@ static herr_t processDataset (hid_t group, if (is_group) { - IOHDF5_ERROR (H5Gclose (dataset)); + HDF5_ERROR (H5Gclose (dataset)); } else { - IOHDF5_ERROR (H5Dclose (dataset)); + HDF5_ERROR (H5Dclose (dataset)); } return (0); |