diff options
Diffstat (limited to 'src/Output.c')
-rw-r--r-- | src/Output.c | 38 |
1 files changed, 20 insertions, 18 deletions
diff --git a/src/Output.c b/src/Output.c index 05b6789..4d192bd 100644 --- a/src/Output.c +++ b/src/Output.c @@ -38,7 +38,6 @@ typedef struct /******************************************************************** ******************** Internal Routines ************************ ********************************************************************/ -static void CheckSteerableParameters (const cGH *GH); static void OutputVarAs (int vindex, const char *optstring, void *arg); @@ -149,7 +148,7 @@ int IOHDF5_OutputVarAs (const cGH *GH, const char *fullname, const char *alias) using the IOHDF5 I/O method. @enddesc - @calls CheckSteerableParameters + @calls IOHDF5_CheckSteerableParameters @var GH @vdesc pointer to CCTK GH @@ -172,13 +171,13 @@ int IOHDF5_TimeFor (const cGH *GH, int vindex) { int retval; char *fullname; - const ioHDF5GH *myGH; + ioHDF5GH *myGH; - CheckSteerableParameters (GH); + myGH = CCTK_GHExtension (GH, "IOHDF5"); + IOHDF5_CheckSteerableParameters (GH, myGH); /* check if this variable should be output */ - myGH = CCTK_GHExtension (GH, "IOHDF5"); retval = myGH->requests[vindex] && myGH->requests[vindex]->out_every > 0 && GH->cctk_iteration % myGH->requests[vindex]->out_every == 0; if (retval) @@ -260,11 +259,8 @@ int IOHDF5_TriggerOutput (const cGH *GH, int vindex) } -/******************************************************************** - ******************** Internal Routines ************************ - ********************************************************************/ /*@@ - @routine CheckSteerableParameters + @routine IOHDF5_CheckSteerableParameters @date Mon Oct 10 2000 @author Thomas Radke @desc @@ -279,17 +275,20 @@ int IOHDF5_TriggerOutput (const cGH *GH, int vindex) @vtype const cGH * @vio in @endvar + @var myGH + @vdesc pointer to IOHDF5 grid hierarchy + @vtype ioHDF5GH * + @vio inout + @endvar @@*/ -static void CheckSteerableParameters (const cGH *GH) +void IOHDF5_CheckSteerableParameters (const cGH *GH, ioHDF5GH *myGH) { int i; - ioHDF5GH *myGH; char *fullname, *msg; DECLARE_CCTK_PARAMETERS /* how often to output */ - myGH = CCTK_GHExtension (GH, "IOHDF5"); i = myGH->out_every_default; myGH->out_every_default = out_every >= 0 ? out_every : io_out_every; @@ -298,12 +297,12 @@ static void CheckSteerableParameters (const cGH *GH) { if (myGH->out_every_default > 0) { - CCTK_VInfo (CCTK_THORNSTRING, "IOHDF5: Periodic output every %d " + CCTK_VInfo (CCTK_THORNSTRING, "Periodic HDF5 output every %d " "iterations", myGH->out_every_default); } else { - CCTK_INFO ("IOHDF5: Periodic output turned off"); + CCTK_INFO ("Periodic HDF5 output turned off"); } } @@ -311,8 +310,8 @@ static void CheckSteerableParameters (const cGH *GH) if (strcmp (out_vars, myGH->out_vars) || myGH->out_every_default != i) { IOUtil_ParseVarsForOutput (GH, CCTK_THORNSTRING, "IOHDF5::out_vars", - out_vars, myGH->out_every_default, - myGH->requests); + myGH->stop_on_parse_errors, out_vars, + myGH->out_every_default, myGH->requests); if (myGH->out_every_default == i || ! CCTK_Equals (verbose, "none")) { @@ -324,7 +323,7 @@ static void CheckSteerableParameters (const cGH *GH) fullname = CCTK_FullName (i); if (! msg) { - Util_asprintf (&msg, "IOHDF5: Periodic output requested for '%s'", + Util_asprintf (&msg, "Periodic HDF5 output requested for '%s'", fullname); } else @@ -348,6 +347,9 @@ static void CheckSteerableParameters (const cGH *GH) } +/******************************************************************** + ******************** Internal Routines ************************ + ********************************************************************/ /*@@ @routine OutputVarAs @date Fri 6 June 2003 @@ -400,7 +402,7 @@ static void OutputVarAs (int vindex, const char *optstring, void *arg) if (oneshot) { IOUtil_ParseVarsForOutput (info->GH, CCTK_THORNSTRING, "IOHDF5::out_vars", - info->fullname, 1, myGH->requests); + 0, info->fullname, 1, myGH->requests); } /* do the output */ |