Skip to content

Commit ad59f47

Browse files
committed
drop extra have and start restart calls
1 parent 461a433 commit ad59f47

File tree

1 file changed

+2
-14
lines changed

1 file changed

+2
-14
lines changed

src/CheckPoint.C

Lines changed: 2 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1368,20 +1368,6 @@ void CheckPoint::read_checkpoint_hdf5(float_sw4& a_time, int& a_cycle,
13681368
MPI_Comm_rank(MPI_COMM_WORLD, &myrank);
13691369
MPI_Comm_size(MPI_COMM_WORLD, &nrank);
13701370

1371-
#ifdef SW4_USE_SCR
1372-
// Double check that SCR has a checkpoint loaded
1373-
int have_restart = 0;
1374-
char cycle_num[SCR_MAX_FILENAME];
1375-
SCR_Have_restart(&have_restart, cycle_num);
1376-
if (! have_restart) {
1377-
// We expected SCR to have something to get to this point
1378-
abort();
1379-
}
1380-
1381-
// Get checkpoint name from SCR (we use application cycle number)
1382-
SCR_Start_restart(cycle_num);
1383-
#endif
1384-
13851371
std::stringstream s;
13861372
if (mRestartPathSet)
13871373
s << mRestartPath << "/";
@@ -1391,6 +1377,8 @@ void CheckPoint::read_checkpoint_hdf5(float_sw4& a_time, int& a_cycle,
13911377
#ifndef SW4_USE_SCR
13921378
s << mRestartFile;
13931379
#else
1380+
// TODO: need to get cycle_num from earlier call to Have_restart
1381+
13941382
// TODO: this is not right, but you get the idea...
13951383
std::stringstream fileSuffix;
13961384
compute_file_suffix(cycle_num, fileSuffix);

0 commit comments

Comments
 (0)