aboutsummaryrefslogtreecommitdiff
path: root/src/Startup.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/Startup.c')
-rw-r--r--src/Startup.c359
1 files changed, 0 insertions, 359 deletions
diff --git a/src/Startup.c b/src/Startup.c
index 3e29dcc..2dc7d1c 100644
--- a/src/Startup.c
+++ b/src/Startup.c
@@ -40,8 +40,6 @@ CCTK_FILEVERSION(CactusBase_IOUtil_Startup_c)
********************************************************************/
void IOUtil_Startup (void);
int IOUtil_UpdateParFile (const cGH *GH);
-int IOUtil_FixParameters (void);
-int IOUtil_FixRecoveryParameters (void);
/********************************************************************
@@ -141,363 +139,6 @@ int IOUtil_UpdateParFile (const cGH *GH)
}
-int IOUtil_FixRecoveryParameters (void)
-{
- static int already_called = 0;
- DECLARE_CCTK_PARAMETERS
-
-
- if (! already_called)
- {
- if (CCTK_ParameterQueryTimesSet ("recovery_dir", CCTK_THORNSTRING) >
- CCTK_ParameterQueryTimesSet ("recover_dir", CCTK_THORNSTRING))
- {
- CCTK_WARN (1, "Parameter 'IO::recovery_dir' is deprecated in BETA12, please use "
- "'IO::recover_dir' instead");
- CCTK_ParameterSet ("recover_dir", CCTK_THORNSTRING, recovery_dir);
- }
-
- /* call IOUtil_FixParameters() now if no recovery was requested */
- if (CCTK_Equals (recover, "no") || *recover_file == 0 ||
- ! (CCTK_IsThornActive ("IOHDF5") || CCTK_IsThornActive ("IOFlexIO")))
- {
- IOUtil_FixParameters ();
- }
-
- already_called = 1;
- }
-
- return (0);
-}
-
-
-int IOUtil_FixParameters (void)
-{
- char buffer[20];
- DECLARE_CCTK_PARAMETERS
-
-
- if (CCTK_ParameterQueryTimesSet ("outdir", CCTK_THORNSTRING) >
- CCTK_ParameterQueryTimesSet ("out_dir", CCTK_THORNSTRING))
- {
- CCTK_WARN (1, "Parameter 'IO::outdir' is deprecated in BETA12, please use "
- "'IO::out_dir' instead");
- CCTK_ParameterSet ("out_dir", CCTK_THORNSTRING, outdir);
- }
- if (CCTK_ParameterQueryTimesSet ("out3D_mode", CCTK_THORNSTRING) >
- CCTK_ParameterQueryTimesSet ("out_mode", CCTK_THORNSTRING))
- {
- CCTK_WARN (1, "Parameter 'IO::out3D_mode' is deprecated in BETA12, please use "
- "'IO::out_mode' instead");
- CCTK_ParameterSet ("out_mode", CCTK_THORNSTRING, out3D_mode);
- }
- if (CCTK_ParameterQueryTimesSet ("out3D_unchunked", CCTK_THORNSTRING) >
- CCTK_ParameterQueryTimesSet ("out_unchunked", CCTK_THORNSTRING))
- {
- CCTK_WARN (1, "Parameter 'IO::out3D_unchunked' is deprecated in BETA12, please use "
- "'IO::out_unchunked' instead");
- CCTK_ParameterSet ("out_unchunked", CCTK_THORNSTRING, out3D_unchunked ? "yes" : "no");
- }
- if (CCTK_ParameterQueryTimesSet ("out3D_downsample_x", CCTK_THORNSTRING) >
- CCTK_ParameterQueryTimesSet ("out_downsample_x", CCTK_THORNSTRING))
- {
- CCTK_WARN (1, "Parameter 'IO::out3D_downsample_x' is deprecated in BETA12, please use "
- "'IO::out_downsample_x' instead");
- sprintf (buffer, "%d", out3D_downsample_x);
- CCTK_ParameterSet ("out_downsample_x", CCTK_THORNSTRING, buffer);
- }
- if (CCTK_ParameterQueryTimesSet ("out3D_downsample_y", CCTK_THORNSTRING) >
- CCTK_ParameterQueryTimesSet ("out_downsample_y", CCTK_THORNSTRING))
- {
- CCTK_WARN (1, "Parameter 'IO::out3D_downsample_y' is deprecated in BETA12, please use "
- "'IO::out_downsample_y' instead");
- sprintf (buffer, "%d", out3D_downsample_y);
- CCTK_ParameterSet ("out_downsample_y", CCTK_THORNSTRING, buffer);
- }
- if (CCTK_ParameterQueryTimesSet ("out3D_downsample_z", CCTK_THORNSTRING) >
- CCTK_ParameterQueryTimesSet ("out_downsample_z", CCTK_THORNSTRING))
- {
- CCTK_WARN (1, "Parameter 'IO::out3D_downsample_z' is deprecated in BETA12, please use "
- "'IO::out_downsample_z' instead");
- sprintf (buffer, "%d", out3D_downsample_z);
- CCTK_ParameterSet ("out_downsample_z", CCTK_THORNSTRING, buffer);
- }
- if (CCTK_ParameterQueryTimesSet ("out3D_single", CCTK_THORNSTRING) >
- CCTK_ParameterQueryTimesSet ("out_single_precision", CCTK_THORNSTRING))
- {
- CCTK_WARN (1, "Parameter 'IO::out3D_single' is deprecated in BETA12, please use "
- "'IO::out_single_precision' instead");
- CCTK_ParameterSet ("out_single_precision", CCTK_THORNSTRING, out3D_single ? "yes" : "no");
- }
- if (CCTK_ParameterQueryTimesSet ("out3D_parameters", CCTK_THORNSTRING) >
- CCTK_ParameterQueryTimesSet ("out_save_parameters", CCTK_THORNSTRING))
- {
- CCTK_WARN (1, "Parameter 'IO::out3D_parameters' is deprecated in BETA12, please use "
- "'IO::out_save_parameters' instead");
- CCTK_ParameterSet ("out_save_parameters", CCTK_THORNSTRING, out3D_parameters);
- }
- if (CCTK_ParameterQueryTimesSet ("out3D_procs", CCTK_THORNSTRING) >
- CCTK_ParameterQueryTimesSet ("out_proc_every", CCTK_THORNSTRING))
- {
- CCTK_WARN (1, "Parameter 'IO::out3D_procs' is deprecated in BETA12, please use "
- "'IO::out_proc_every' instead");
- sprintf (buffer, "%d", out3D_procs);
- CCTK_ParameterSet ("out_proc_every", CCTK_THORNSTRING, buffer);
- }
- if (CCTK_ParameterQueryTimesSet ("out3D_septimefiles", CCTK_THORNSTRING) >
- CCTK_ParameterQueryTimesSet ("out_timesteps_per_file", CCTK_THORNSTRING))
- {
- CCTK_WARN (1, "Parameter 'IO::out3D_septimefiles' is deprecated in BETA12, please use "
- "'IO::out_timesteps_per_file' instead");
- CCTK_ParameterSet ("out_timesteps_per_file", CCTK_THORNSTRING, out3D_septimefiles ? "1" : "-1");
- }
- if (CCTK_ParameterQueryTimesSet ("recover_ID_files", CCTK_THORNSTRING) >
- CCTK_ParameterQueryTimesSet ("filereader_ID_files", CCTK_THORNSTRING))
- {
- CCTK_WARN (1, "Parameter 'IO::recover_ID_files' is deprecated in BETA12, please use "
- "'IO::filereader_ID_files' instead");
- CCTK_ParameterSet ("filereader_ID_files", CCTK_THORNSTRING, recover_ID_files);
- }
- if (CCTK_ParameterQueryTimesSet ("recover_ID_vars", CCTK_THORNSTRING) >
- CCTK_ParameterQueryTimesSet ("filereader_ID_vars", CCTK_THORNSTRING))
- {
- CCTK_WARN (1, "Parameter 'IO::recover_ID_vars' is deprecated in BETA12, please use "
- "'IO::filereader_ID_vars' instead");
- CCTK_ParameterSet ("filereader_ID_vars", CCTK_THORNSTRING, recover_ID_vars);
- }
-
- if (CCTK_Equals (verbose, "yes") || CCTK_Equals (verbose, "no"))
- {
- CCTK_VWarn (1, __LINE__, __FILE__, CCTK_THORNSTRING,
- "Setting '%s' for parameter 'IO::verbose' is deprecated in "
- "BETA12, please use 'none|standard|full' instead", verbose);
- if (CCTK_Equals (verbose, "yes"))
- {
- CCTK_ParameterSet ("verbose", CCTK_THORNSTRING, "standard");
- }
- else
- {
- CCTK_ParameterSet ("verbose", CCTK_THORNSTRING, "none");
- }
- }
-
- /* parameters of IOASCII */
- if (CCTK_IsThornActive ("IOASCII"))
- {
- if (CCTK_ParameterQueryTimesSet ("outdir1D", "IOASCII") >
- CCTK_ParameterQueryTimesSet ("out1D_dir", "IOASCII"))
- {
- CCTK_WARN (1, "Parameter 'IOASCII::outdir1D' is deprecated in BETA12, "
- "please use 'IOASCII::out1D_dir' instead");
- CCTK_ParameterSet ("out1D_dir", "IOASCII",
- *(const char **) CCTK_ParameterGet ("outdir1D", "IOASCII", NULL));
- }
- if (CCTK_ParameterQueryTimesSet ("outdir2D", "IOASCII") >
- CCTK_ParameterQueryTimesSet ("out2D_dir", "IOASCII"))
- {
- CCTK_WARN (1, "Parameter 'IOASCII::outdir2D' is deprecated in BETA12, "
- "please use 'IOASCII::out2D_dir' instead");
- CCTK_ParameterSet ("out2D_dir", "IOASCII",
- *(const char **) CCTK_ParameterGet ("outdir2D", "IOASCII", NULL));
- }
- if (CCTK_ParameterQueryTimesSet ("outdir3D", "IOASCII") >
- CCTK_ParameterQueryTimesSet ("out3D_dir", "IOASCII"))
- {
- CCTK_WARN (1, "Parameter 'IOASCII::outdir3D' is deprecated in BETA12, "
- "please use 'IOASCII::out3D_dir' instead");
- CCTK_ParameterSet ("out3D_dir", "IOASCII",
- *(const char **) CCTK_ParameterGet ("outdir3D", "IOASCII", NULL));
- }
-
- if (CCTK_ParameterQueryTimesSet ("out_style", "IOASCII") >
- CCTK_ParameterQueryTimesSet ("out1D_style", "IOASCII"))
- {
- CCTK_WARN (1, "Parameter 'IOASCII::out_style' is deprecated in BETA12, "
- "please use 'IOASCII::out1D_style' instead");
- CCTK_ParameterSet ("out1D_style", "IOASCII",
- *(const char **) CCTK_ParameterGet ("out_style", "IOASCII", NULL));
- }
- }
-
- /* IOBasic parameters */
- if (CCTK_IsThornActive ("IOBasic"))
- {
- if (CCTK_ParameterQueryTimesSet ("outdirScalar", "IOBasic") >
- CCTK_ParameterQueryTimesSet ("out_dir", "IOBasic"))
- {
- CCTK_WARN (1, "Parameter 'IOBasic::outdirScalar' is deprecated in BETA12, "
- "please use 'IOBasic::out_dir' instead");
- CCTK_ParameterSet ("out_dir", "IOBasic",
- *(const char **) CCTK_ParameterGet ("outdirScalar", "IOBasic", NULL));
- }
- }
-
- /* IOJpeg parameters */
- if (CCTK_IsThornActive ("IOJpeg"))
- {
- if (CCTK_ParameterQueryTimesSet ("out2D_dir", "IOJpeg") >
- CCTK_ParameterQueryTimesSet ("out_dir", "IOJpeg"))
- {
- CCTK_WARN (1, "Parameter 'IOJPeg::out2D_dir' is deprecated in BETA12, "
- "please use 'IOJPeg::out_dir' instead");
- CCTK_ParameterSet ("out_dir", "IOJpeg",
- *(const char **) CCTK_ParameterGet ("out2D_dir", "IOJPeg", NULL));
- }
- if (CCTK_ParameterQueryTimesSet ("out2D_every", "IOJpeg") >
- CCTK_ParameterQueryTimesSet ("out_every", "IOJpeg"))
- {
- CCTK_WARN (1, "Parameter 'IOJPeg::out2D_every' is deprecated in BETA12, "
- "please use 'IOJPeg::out_every' instead");
- sprintf (buffer, "%d",
- *(const CCTK_INT *) CCTK_ParameterGet ("out2D_every", "IOJPeg", NULL));
- CCTK_ParameterSet ("out_every", "IOJpeg", buffer);
- }
- if (CCTK_ParameterQueryTimesSet ("out2D_vars", "IOJpeg") >
- CCTK_ParameterQueryTimesSet ("out_vars", "IOJpeg"))
- {
- CCTK_WARN (1, "Parameter 'IOJPeg::out2D_vars' is deprecated in BETA12, "
- "please use 'IOJPeg::out_vars' instead");
- CCTK_ParameterSet ("out_vars", "IOJpeg",
- *(const char **) CCTK_ParameterGet ("out2D_vars", "IOJPeg", NULL));
- }
- }
-
- /* IsoSurfacer parameters */
- if (CCTK_IsThornActive ("IsoSurfacer"))
- {
- if (CCTK_ParameterQueryTimesSet ("outdir", "IsoSurfacer") >
- CCTK_ParameterQueryTimesSet ("out_dir", "IsoSurfacer"))
- {
- CCTK_WARN (1, "Parameter 'IsoSurfacer::outdir' is deprecated in BETA12, "
- "please use 'IsoSurfacer::out_dir' instead");
- CCTK_ParameterSet ("out_dir", "IsoSurfacer",
- *(const char **) CCTK_ParameterGet ("outdir", "IsoSurfacer", NULL));
- }
- if (CCTK_ParameterQueryTimesSet ("output_var", "IsoSurfacer") >
- CCTK_ParameterQueryTimesSet ("out_vars", "IsoSurfacer"))
- {
- CCTK_WARN (1, "Parameter 'IsoSurfacer::output_var' is deprecated in BETA12, "
- "please use 'IsoSurfacer::out_vars' instead");
- CCTK_ParameterSet ("out_vars", "IsoSurfacer",
- *(const char **) CCTK_ParameterGet ("output_var", "IsoSurfacer", NULL));
- }
- if (CCTK_ParameterQueryTimesSet ("output_frequency", "IsoSurfacer") >
- CCTK_ParameterQueryTimesSet ("out_every", "IsoSurfacer"))
- {
- CCTK_WARN (1, "Parameter 'IsoSurfacer::output_frequency' is deprecated in BETA12, "
- "please use 'IsoSurfacer::out_every' instead");
- sprintf (buffer, "%d",
- *(const CCTK_INT *) CCTK_ParameterGet ("output_frequency", "IsoSurfacer", NULL));
- CCTK_ParameterSet ("out_every", "IsoSurfacer", buffer);
- }
- if (CCTK_ParameterQueryTimesSet ("output_start", "IsoSurfacer") >
- CCTK_ParameterQueryTimesSet ("out_start", "IsoSurfacer"))
- {
- CCTK_WARN (1, "Parameter 'IsoSurfacer::output_start' is deprecated in BETA12, "
- "please use 'IsoSurfacer::out_start' instead");
- sprintf (buffer, "%d",
- *(const CCTK_INT *) CCTK_ParameterGet ("output_start", "IsoSurfacer", NULL));
- CCTK_ParameterSet ("out_start", "IsoSurfacer", buffer);
- }
- if (CCTK_ParameterQueryTimesSet ("output_format", "IsoSurfacer") >
- CCTK_ParameterQueryTimesSet ("out_format", "IsoSurfacer"))
- {
- CCTK_WARN (1, "Parameter 'IsoSurfacer::output_format' is deprecated in BETA12, "
- "please use 'IsoSurfacer::out_format' instead");
- CCTK_ParameterSet ("out_format", "IsoSurfacer",
- *(const char **) CCTK_ParameterGet ("output_format", "IsoSurfacer", NULL));
- }
- }
-
- /* IOFlexIO parameters */
- if (CCTK_IsThornActive ("IOFlexIO"))
- {
- if (CCTK_ParameterQueryTimesSet ("outdir2D", "IOFlexIO") >
- CCTK_ParameterQueryTimesSet ("out2D_dir", "IOFlexIO"))
- {
- CCTK_WARN (1, "Parameter 'IOFlexIO::outdir2D' is deprecated in BETA12, "
- "please use 'IOFlexIO::out2D_dir' instead");
- CCTK_ParameterSet ("out2D_dir", "IOFlexIO",
- *(const char **) CCTK_ParameterGet ("outdir2D", "IOFlexIO", NULL));
- }
- if (CCTK_ParameterQueryTimesSet ("outdir3D", "IOFlexIO") >
- CCTK_ParameterQueryTimesSet ("out_dir", "IOFlexIO"))
- {
- CCTK_WARN (1, "Parameter 'IOFlexIO::outdir3D' is deprecated in BETA12, "
- "please use 'IOFlexIO::out_dir' instead");
- CCTK_ParameterSet ("out_dir", "IOFlexIO",
- *(const char **) CCTK_ParameterGet ("outdir3D", "IOFlexIO", NULL));
- }
- if (CCTK_ParameterQueryTimesSet ("out3D_every", "IOFlexIO") >
- CCTK_ParameterQueryTimesSet ("out_every", "IOFlexIO"))
- {
- CCTK_WARN (1, "Parameter 'IOFlexIO::out3D_every' is deprecated in BETA12, "
- "please use 'IOFlexIO::out_every' instead");
- sprintf (buffer, "%d",
- *(const CCTK_INT *) CCTK_ParameterGet ("out3D_every", "IOFlexIO", NULL));
- CCTK_ParameterSet ("out_every", "IOFlexIO", buffer);
- }
- if (CCTK_ParameterQueryTimesSet ("out3D_vars", "IOFlexIO") >
- CCTK_ParameterQueryTimesSet ("out_vars", "IOFlexIO"))
- {
- CCTK_WARN (1, "Parameter 'IOFlexIO::out3D_vars' is deprecated in BETA12, "
- "please use 'IOFlexIO::out_vars' instead");
- CCTK_ParameterSet ("out_vars", "IOFlexIO",
- *(const char **) CCTK_ParameterGet ("out3D_vars", "IOFlexIO", NULL));
- }
- }
-
- /* IOHDF5 parameters */
- if (CCTK_IsThornActive ("IOHDF5"))
- {
- if (CCTK_ParameterQueryTimesSet ("out3D_vars", "IOHDF5") >
- CCTK_ParameterQueryTimesSet ("out_vars", "IOHDF5"))
- {
- CCTK_WARN (1, "Parameter 'IOHDF5::out3D_vars' is deprecated in BETA12, "
- "please use 'IOHDF5::out_vars' instead");
- CCTK_ParameterSet ("out_vars", "IOHDF5",
- *(const char **) CCTK_ParameterGet ("out3D_vars", "IOHDF5", NULL));
- }
- if (CCTK_ParameterQueryTimesSet ("outdir3D", "IOHDF5") >
- CCTK_ParameterQueryTimesSet ("out_dir", "IOHDF5"))
- {
- CCTK_WARN (1, "Parameter 'IOHDF5::outdir3D' is deprecated in BETA12, "
- "please use 'IOHDF5::out_dir' instead");
- CCTK_ParameterSet ("out_dir", "IOHDF5",
- *(const char **) CCTK_ParameterGet ("outdir3D", "IOHDF5", NULL));
- }
- if (CCTK_ParameterQueryTimesSet ("outdir_HDF5", "IOHDF5") >
- CCTK_ParameterQueryTimesSet ("out_dir", "IOHDF5"))
- {
- CCTK_WARN (1, "Parameter 'IOHDF5::outdir_HDF5' is deprecated in BETA12, "
- "please use 'IOHDF5::out_dir' instead");
- CCTK_ParameterSet ("out_dir", "IOHDF5",
- *(const char **) CCTK_ParameterGet ("outdir_HDF5", "IOHDF5", NULL));
- }
- if (CCTK_ParameterQueryTimesSet ("outHDF5_every", "IOHDF5") >
- CCTK_ParameterQueryTimesSet ("out_every", "IOHDF5"))
- {
- CCTK_WARN (1, "Parameter 'IOHDF5::outHDF5_every' is deprecated in BETA12, "
- "please use 'IOHDF5::out_every' instead");
- sprintf (buffer, "%d",
- *(const CCTK_INT *) CCTK_ParameterGet ("outHDF5_every", "IOHDF5", NULL));
- CCTK_ParameterSet ("out_every", "IOHDF5", buffer);
- }
- if (CCTK_ParameterQueryTimesSet ("out3D_every", "IOHDF5") >
- CCTK_ParameterQueryTimesSet ("out_every", "IOHDF5"))
- {
- CCTK_WARN (1, "Parameter 'IOHDF5::out3D_every' is deprecated in BETA12, "
- "please use 'IOHDF5::out_every' instead");
- sprintf (buffer, "%d",
- *(const CCTK_INT *) CCTK_ParameterGet ("out3D_every", "IOHDF5", NULL));
- CCTK_ParameterSet ("out_every", "IOHDF5", buffer);
- }
- }
-
- return (0);
-}
-
-
/********************************************************************
*********************** Local Functions ***********************
********************************************************************/