diff --git a/src/KOKKOS/verlet_kokkos.h b/src/KOKKOS/verlet_kokkos.h index 7b140b6f81ae40bdb393534c7ce29e0f564bc5f2..1e36b1cf6eb718c5296eb9cde905c066f9f3e606 100644 --- a/src/KOKKOS/verlet_kokkos.h +++ b/src/KOKKOS/verlet_kokkos.h @@ -31,7 +31,7 @@ class VerletKokkos : public Verlet { public: VerletKokkos(class LAMMPS *, int, char **); ~VerletKokkos() {} - void setup(int flag=1); + void setup(int); void setup_minimal(int); void run(int); diff --git a/src/REPLICA/prd.cpp b/src/REPLICA/prd.cpp index 14eeac8d664551927278454f577de998a7bdc4a0..f7d369cee6a4b162a5fdecc040310f5f60c492b5 100644 --- a/src/REPLICA/prd.cpp +++ b/src/REPLICA/prd.cpp @@ -293,7 +293,7 @@ void PRD::command(int narg, char **arg) update->whichflag = 1; lmp->init(); - update->integrate->setup(); + update->integrate->setup(1); if (temp_flag == 0) { if (universe->iworld == 0) temp_dephase = temperature->compute_scalar(); @@ -390,7 +390,7 @@ void PRD::command(int narg, char **arg) update->whichflag = 1; lmp->init(); - update->integrate->setup(); + update->integrate->setup(1); timer->barrier_start(); @@ -545,7 +545,7 @@ void PRD::dynamics(int nsteps, double &time_category) update->nsteps = nsteps; lmp->init(); - update->integrate->setup(); + update->integrate->setup(1); // this may be needed if don't do full init //modify->addstep_compute_all(update->ntimestep); bigint ncalls = neighbor->ncalls; diff --git a/src/REPLICA/tad.cpp b/src/REPLICA/tad.cpp index 347cd3ba67c0927740086a879d2de5f750cf3faf..958a57e4e8936e895621fd4ec6fb5cf89baf153e 100644 --- a/src/REPLICA/tad.cpp +++ b/src/REPLICA/tad.cpp @@ -264,7 +264,7 @@ void TAD::command(int narg, char **arg) update->whichflag = 1; lmp->init(); - update->integrate->setup(); + update->integrate->setup(1); // main loop: look for events until out of time // (1) dynamics, store state, quench, check event, restore state @@ -342,7 +342,7 @@ void TAD::command(int narg, char **arg) update->whichflag = 1; lmp->init(); - update->integrate->setup(); + update->integrate->setup(1); // write restart file of hot coords @@ -448,7 +448,7 @@ void TAD::dynamics() update->nsteps = t_event; lmp->init(); - update->integrate->setup(); + update->integrate->setup(1); // this may be needed if don't do full init //modify->addstep_compute_all(update->ntimestep); int ncalls = neighbor->ncalls; diff --git a/src/REPLICA/temper.cpp b/src/REPLICA/temper.cpp index 667f2893c6da1c43828f78c561a0a5d49338b308..d7e8c981bb51a729595aeee17ae8c2c4b43fd71d 100644 --- a/src/REPLICA/temper.cpp +++ b/src/REPLICA/temper.cpp @@ -212,7 +212,7 @@ void Temper::command(int narg, char **arg) if (me_universe == 0 && universe->uscreen) fprintf(universe->uscreen,"Setting up tempering ...\n"); - update->integrate->setup(); + update->integrate->setup(1); if (me_universe == 0) { if (universe->uscreen) { diff --git a/src/REPLICA/verlet_split.cpp b/src/REPLICA/verlet_split.cpp index 4572170f34f6132fa4ca6ef1b081147142a8d011..3d4e25b7b42d06284f15324a8f8aef1f824c6ac7 100644 --- a/src/REPLICA/verlet_split.cpp +++ b/src/REPLICA/verlet_split.cpp @@ -239,13 +239,13 @@ void VerletSplit::init() servant partition only sets up KSpace calculation ------------------------------------------------------------------------- */ -void VerletSplit::setup() +void VerletSplit::setup(int flag) { if (comm->me == 0 && screen) fprintf(screen,"Setting up Verlet/split run ...\n"); if (!master) force->kspace->setup(); - else Verlet::setup(); + else Verlet::setup(flag); } /* ---------------------------------------------------------------------- diff --git a/src/REPLICA/verlet_split.h b/src/REPLICA/verlet_split.h index 2d25131df30b5c289a4983a317f98f79ec7b336b..b3ee87e580bbfc47e7585c05ce0d9195cc3d6af5 100644 --- a/src/REPLICA/verlet_split.h +++ b/src/REPLICA/verlet_split.h @@ -29,7 +29,7 @@ class VerletSplit : public Verlet { VerletSplit(class LAMMPS *, int, char **); ~VerletSplit(); void init(); - void setup(); + void setup(int); void setup_minimal(int); void run(int); bigint memory_usage(); diff --git a/src/USER-INTEL/verlet_lrt_intel.h b/src/USER-INTEL/verlet_lrt_intel.h index 0d7154ff643ee7a71af39057b13668345939ce1d..7380cc6376b3c649351579ecbc0a563f6a85cf99 100644 --- a/src/USER-INTEL/verlet_lrt_intel.h +++ b/src/USER-INTEL/verlet_lrt_intel.h @@ -41,7 +41,7 @@ class VerletLRTIntel : public Verlet { VerletLRTIntel(class LAMMPS *, int, char **); virtual ~VerletLRTIntel(); virtual void init(); - virtual void setup(int flag = 1); + virtual void setup(int flag); virtual void run(int); protected: diff --git a/src/USER-MISC/temper_grem.cpp b/src/USER-MISC/temper_grem.cpp index 6ce7da8d6adea2267ebbb87a92469cfe7367f41f..9e5a4c5c3b95aed6cec87ea62e88d000874d9cc8 100644 --- a/src/USER-MISC/temper_grem.cpp +++ b/src/USER-MISC/temper_grem.cpp @@ -214,7 +214,7 @@ void TemperGrem::command(int narg, char **arg) if (me_universe == 0 && universe->uscreen) fprintf(universe->uscreen,"Setting up tempering ...\n"); - update->integrate->setup(); + update->integrate->setup(1); if (me_universe == 0) { if (universe->uscreen) { diff --git a/src/USER-MISC/temper_npt.cpp b/src/USER-MISC/temper_npt.cpp index e405377d794a02a0ad1133199ab633ddf913bf95..60f9313fdd7a192b1ae59b6720204f9c13cebadf 100644 --- a/src/USER-MISC/temper_npt.cpp +++ b/src/USER-MISC/temper_npt.cpp @@ -190,7 +190,7 @@ void TemperNPT::command(int narg, char **arg) if (me_universe == 0 && universe->uscreen) fprintf(universe->uscreen,"Setting up tempering ...\n"); - update->integrate->setup(); + update->integrate->setup(1); if (me_universe == 0) { if (universe->uscreen) { diff --git a/src/USER-OMP/respa_omp.cpp b/src/USER-OMP/respa_omp.cpp index aa4aa65a4fcefec8bc143367d63347306c1c3bc6..ac1c2d53d4222da3d3fa6975455abb3745a6e23c 100644 --- a/src/USER-OMP/respa_omp.cpp +++ b/src/USER-OMP/respa_omp.cpp @@ -67,24 +67,26 @@ void RespaOMP::init() setup before run ------------------------------------------------------------------------- */ -void RespaOMP::setup() +void RespaOMP::setup(int flag) { if (comm->me == 0 && screen) { fprintf(screen,"Setting up r-RESPA/omp run ...\n"); - fprintf(screen," Unit style : %s\n", update->unit_style); - fprintf(screen," Current step : " BIGINT_FORMAT "\n", update->ntimestep); - fprintf(screen," Time steps :"); - for (int ilevel=0; ilevel < nlevels; ++ilevel) - fprintf(screen," %d:%g",ilevel+1, step[ilevel]); - fprintf(screen,"\n r-RESPA fixes :"); - for (int l=0; l < modify->n_post_force_respa; ++l) { - Fix *f = modify->fix[modify->list_post_force_respa[l]]; - if (f->respa_level >= 0) - fprintf(screen," %d:%s[%s]", - MIN(f->respa_level+1,nlevels),f->style,f->id); + if (flag) { + fprintf(screen," Unit style : %s\n", update->unit_style); + fprintf(screen," Current step : " BIGINT_FORMAT "\n", update->ntimestep); + fprintf(screen," Time steps :"); + for (int ilevel=0; ilevel < nlevels; ++ilevel) + fprintf(screen," %d:%g",ilevel+1, step[ilevel]); + fprintf(screen,"\n r-RESPA fixes :"); + for (int l=0; l < modify->n_post_force_respa; ++l) { + Fix *f = modify->fix[modify->list_post_force_respa[l]]; + if (f->respa_level >= 0) + fprintf(screen," %d:%s[%s]", + MIN(f->respa_level+1,nlevels),f->style,f->id); + } + fprintf(screen,"\n"); + timer->print_timeout(screen); } - fprintf(screen,"\n"); - timer->print_timeout(screen); } update->setupflag = 1; diff --git a/src/USER-OMP/respa_omp.h b/src/USER-OMP/respa_omp.h index 89ddbe78af8b42acb5260cdf79e3499a18514afb..dc01e3dc5bc9d09db88e650ea453509bdfd92b77 100644 --- a/src/USER-OMP/respa_omp.h +++ b/src/USER-OMP/respa_omp.h @@ -30,7 +30,7 @@ class RespaOMP : public Respa, public ThrOMP { RespaOMP(class LAMMPS *, int, char **); virtual ~RespaOMP() {} virtual void init(); - virtual void setup(); + virtual void setup(int); virtual void setup_minimal(int); protected: diff --git a/src/integrate.h b/src/integrate.h index 4ca3a788fa3d8f1754674a030cb0ce6d8b5d7c32..9a50fad1f74c3c5a20df76d7764bda389a57f537 100644 --- a/src/integrate.h +++ b/src/integrate.h @@ -23,7 +23,7 @@ class Integrate : protected Pointers { Integrate(class LAMMPS *, int, char **); virtual ~Integrate(); virtual void init(); - virtual void setup(int flag=1) = 0; + virtual void setup(int flag) = 0; virtual void setup_minimal(int) = 0; virtual void run(int) = 0; virtual void cleanup() {} diff --git a/src/respa.h b/src/respa.h index 0b08b12bd7088220ce63000c054b3278cba34fe2..f910f0c666179f5d75247d9c1023490c221d86f8 100644 --- a/src/respa.h +++ b/src/respa.h @@ -48,7 +48,7 @@ class Respa : public Integrate { Respa(class LAMMPS *, int, char **); virtual ~Respa(); virtual void init(); - virtual void setup(int flag=1); + virtual void setup(int); virtual void setup_minimal(int); virtual void run(int); virtual void cleanup(); diff --git a/src/run.cpp b/src/run.cpp index 331754534287e9561b38c91a27e2234f0f7fdc67..37af977e3450f2b2b07ff38c3c35199447ddcc44 100644 --- a/src/run.cpp +++ b/src/run.cpp @@ -175,7 +175,7 @@ void Run::command(int narg, char **arg) if (preflag || update->first_update == 0) { lmp->init(); - update->integrate->setup(); + update->integrate->setup(1); } else output->setup(0); timer->init(); @@ -216,7 +216,7 @@ void Run::command(int narg, char **arg) if (preflag || iter == 0) { lmp->init(); - update->integrate->setup(); + update->integrate->setup(1); } else output->setup(0); timer->init(); diff --git a/src/verlet.h b/src/verlet.h index 29bd3f16b34424d16ea5abd0a0f48b7715ef6829..e71932a8615e9d1eefa5a2e560a9faccf8681351 100644 --- a/src/verlet.h +++ b/src/verlet.h @@ -29,7 +29,7 @@ class Verlet : public Integrate { Verlet(class LAMMPS *, int, char **); virtual ~Verlet() {} virtual void init(); - virtual void setup(int flag=1); + virtual void setup(int flag); virtual void setup_minimal(int); virtual void run(int); void cleanup();