make the output of the %CPU/OpenMP threads line consistent with compiling in OpenMP support, not having USER-OMP installed
This commit is contained in:
@ -158,25 +158,24 @@ void Finish::end(int flag)
|
|||||||
|
|
||||||
// CPU use on MPI tasks and OpenMP threads
|
// CPU use on MPI tasks and OpenMP threads
|
||||||
|
|
||||||
#ifdef LMP_USER_OMP
|
|
||||||
const char fmt2[] =
|
|
||||||
"%.1f%% CPU use with %d MPI tasks x %d OpenMP threads\n";
|
|
||||||
if (screen) fprintf(screen,fmt2,cpu_loop,nprocs,nthreads);
|
|
||||||
if (logfile) fprintf(logfile,fmt2,cpu_loop,nprocs,nthreads);
|
|
||||||
#else
|
|
||||||
if (lmp->kokkos) {
|
if (lmp->kokkos) {
|
||||||
const char fmt2[] =
|
const char fmt2[] =
|
||||||
"%.1f%% CPU use with %d MPI tasks x %d OpenMP threads\n";
|
"%.1f%% CPU use with %d MPI tasks x %d OpenMP threads\n";
|
||||||
if (screen) fprintf(screen,fmt2,cpu_loop,nprocs,lmp->kokkos->num_threads);
|
if (screen) fprintf(screen,fmt2,cpu_loop,nprocs,lmp->kokkos->num_threads);
|
||||||
if (logfile) fprintf(logfile,fmt2,cpu_loop,nprocs,lmp->kokkos->num_threads);
|
if (logfile) fprintf(logfile,fmt2,cpu_loop,nprocs,lmp->kokkos->num_threads);
|
||||||
} else {
|
} else {
|
||||||
|
#if defined(_OPENMP)
|
||||||
|
const char fmt2[] =
|
||||||
|
"%.1f%% CPU use with %d MPI tasks x %d OpenMP threads\n";
|
||||||
|
if (screen) fprintf(screen,fmt2,cpu_loop,nprocs,nthreads);
|
||||||
|
if (logfile) fprintf(logfile,fmt2,cpu_loop,nprocs,nthreads);
|
||||||
|
#else
|
||||||
const char fmt2[] =
|
const char fmt2[] =
|
||||||
"%.1f%% CPU use with %d MPI tasks x no OpenMP threads\n";
|
"%.1f%% CPU use with %d MPI tasks x no OpenMP threads\n";
|
||||||
if (screen) fprintf(screen,fmt2,cpu_loop,nprocs);
|
if (screen) fprintf(screen,fmt2,cpu_loop,nprocs);
|
||||||
if (logfile) fprintf(logfile,fmt2,cpu_loop,nprocs);
|
if (logfile) fprintf(logfile,fmt2,cpu_loop,nprocs);
|
||||||
}
|
|
||||||
#endif
|
#endif
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user