switch to using wall time

This commit is contained in:
Axel Kohlmeyer
2022-05-06 16:58:28 -04:00
parent 6e78269612
commit 907bc7eaa5
2 changed files with 13 additions and 13 deletions

View File

@ -501,10 +501,10 @@ void Variable::set(int narg, char **arg)
}
// TIMER
// stores current MPI_Wtime() as a string
// stores current walltime as a timestamp in seconds
// replace pre-existing var if also style TIMER (allows reset with current time)
// num = 1, for string representation of dvalue, set by retrieve()
// dvalue = numeric initialization via platform::cputime()
// dvalue = numeric initialization via platform::walltime()
} else if (strcmp(arg[1],"timer") == 0) {
if (narg != 2) error->all(FLERR,"Illegal variable command");
@ -512,7 +512,7 @@ void Variable::set(int narg, char **arg)
if (ivar >= 0) {
if (style[ivar] != TIMER)
error->all(FLERR,"Cannot redefine variable as a different style");
dvalue[ivar] = platform::cputime();
dvalue[ivar] = platform::walltime();
replaceflag = 1;
} else {
if (nvar == maxvar) grow();
@ -522,7 +522,7 @@ void Variable::set(int narg, char **arg)
pad[nvar] = 0;
data[nvar] = new char*[num[nvar]];
data[nvar][0] = new char[VALUELENGTH];
dvalue[nvar] = platform::cputime();
dvalue[nvar] = platform::walltime();
}
// INTERNAL