diff options
-rw-r--r-- | schedule.ccl | 10 | ||||
-rw-r--r-- | src/DumpGH.c | 32 |
2 files changed, 20 insertions, 22 deletions
diff --git a/schedule.ccl b/schedule.ccl index ae76b4a..3d432c5 100644 --- a/schedule.ccl +++ b/schedule.ccl @@ -8,7 +8,7 @@ schedule IOFlexIO_Startup at STARTUP after ( IOUtil_Startup Driver_Startup ) LANG:C } "Startup routine" -schedule IOFlexIO_TerminateGH at CCTK_TERMINATE +schedule IOFlexIO_TerminateGH at CCTK_TERMINATE after IOFlexIO_TerminationDumpGH { LANG:C } "Closing open IEEEIO files" @@ -36,10 +36,10 @@ schedule IOFlexIO_ConditionallyDumpGH at CCTK_CHECKPOINT LANG:C } "Regular checkpoint routine" -#schedule IOFlexIO_TerminationDumpGH at CCTK_TERMINATE BEFORE Driver_Terminate -#{ -# LANG:C -#} "Termination checkpoint routine" +schedule IOFlexIO_TerminationDumpGH at CCTK_TERMINATE BEFORE Driver_Terminate +{ + LANG:C +} "Termination checkpoint routine" if (! CCTK_Equals (recover, "no") && *recover_file) { diff --git a/src/DumpGH.c b/src/DumpGH.c index 464515e..4c8c40a 100644 --- a/src/DumpGH.c +++ b/src/DumpGH.c @@ -73,31 +73,29 @@ void IOFlexIO_ConditionallyDumpGH (cGH *GH) @date Fri Aug 21 14:40:21 1998 @author Gabrielle Allen @desc - This routine is registered as CCTK_TERMINATE, it checks if a - termination signal is raised (that is: global var cactus_terminate - set to TERMINATION_RAISED_BRDCAST by ./steppers/TerminationStepper.c) - and checkpoints all available grid hierarchies. + This routine is registered as CCTK_TERMINATE + and does a checkpoint if the parameter + 'IO::checkpoint_on_terminate' was set. @enddesc - @calls IOFlexIO_DumpGH - @history - - @endhistory - + @calls IOFlexIO_DumpGH + @var GH + @vdesc Pointer to CCTK grid hierarchy + @vtype cGH + @vio in + @endvar @@*/ - void IOFlexIO_TerminationDumpGH (cGH *GH) { -/*** FIXME: no cactus_terminate flag anymore ? ***/ -#if 0 - if (cactus_terminate == TERMINATION_RAISED_BRDCAST) + DECLARE_CCTK_PARAMETERS + + + if (checkpoint && checkpoint_on_terminate) { - IOFlexIO_DumpGH (GH, CP_EVOLUTION_DATA); + IOFlexIO_DumpGH (GH, CP_EVOLUTION_DATA); } -#else - CCTK_WARN (1, "TerminationDumpGH() not yet implemented !"); -#endif } + /*@@ @routine IOFlexIO_InitialDataDumpGH @date Fri Aug 21 14:46:28 1998 |