Commit 9447d04b authored by Andreas Marek's avatar Andreas Marek
Browse files

Timer for MPI communication in elpa2.F90

parent cf04198f
...@@ -451,6 +451,9 @@ module ELPA2 ...@@ -451,6 +451,9 @@ module ELPA2
call timer%start("solve_evp_real_2stage_double") call timer%start("solve_evp_real_2stage_double")
#endif #endif
#ifdef HAVE_DETAILED_TIMINGS
call timer%start("mpi_communication")
#endif
call mpi_comm_rank(mpi_comm_all,my_pe,mpierr) call mpi_comm_rank(mpi_comm_all,my_pe,mpierr)
call mpi_comm_size(mpi_comm_all,n_pes,mpierr) call mpi_comm_size(mpi_comm_all,n_pes,mpierr)
...@@ -458,7 +461,9 @@ module ELPA2 ...@@ -458,7 +461,9 @@ module ELPA2
call mpi_comm_size(mpi_comm_rows,np_rows,mpierr) call mpi_comm_size(mpi_comm_rows,np_rows,mpierr)
call mpi_comm_rank(mpi_comm_cols,my_pcol,mpierr) call mpi_comm_rank(mpi_comm_cols,my_pcol,mpierr)
call mpi_comm_size(mpi_comm_cols,np_cols,mpierr) call mpi_comm_size(mpi_comm_cols,np_cols,mpierr)
#ifdef HAVE_DETAILED_TIMINGS
call timer%stop("mpi_communication")
#endif
wantDebug = .false. wantDebug = .false.
if (firstCall) then if (firstCall) then
...@@ -609,7 +614,9 @@ module ELPA2 ...@@ -609,7 +614,9 @@ module ELPA2
write(error_unit,*) 'Time tridiag_band_real :',ttt1-ttt0 write(error_unit,*) 'Time tridiag_band_real :',ttt1-ttt0
#ifdef WITH_MPI #ifdef WITH_MPI
#ifdef HAVE_DETAILED_TIMINGS
call timer%start("mpi_communication")
#endif
#ifdef DOUBLE_PRECISION_REAL #ifdef DOUBLE_PRECISION_REAL
call mpi_bcast(ev,na,MPI_REAL8,0,mpi_comm_all,mpierr) call mpi_bcast(ev,na,MPI_REAL8,0,mpi_comm_all,mpierr)
call mpi_bcast(e,na,MPI_REAL8,0,mpi_comm_all,mpierr) call mpi_bcast(e,na,MPI_REAL8,0,mpi_comm_all,mpierr)
...@@ -617,7 +624,9 @@ module ELPA2 ...@@ -617,7 +624,9 @@ module ELPA2
call mpi_bcast(ev,na,MPI_REAL4,0,mpi_comm_all,mpierr) call mpi_bcast(ev,na,MPI_REAL4,0,mpi_comm_all,mpierr)
call mpi_bcast(e,na,MPI_REAL4,0,mpi_comm_all,mpierr) call mpi_bcast(e,na,MPI_REAL4,0,mpi_comm_all,mpierr)
#endif #endif
#ifdef HAVE_DETAILED_TIMINGS
call timer%stop("mpi_communication")
#endif
#endif /* WITH_MPI */ #endif /* WITH_MPI */
ttt1 = MPI_Wtime() ttt1 = MPI_Wtime()
time_evp_fwd = ttt1-ttts time_evp_fwd = ttt1-ttts
...@@ -807,7 +816,9 @@ module ELPA2 ...@@ -807,7 +816,9 @@ module ELPA2
#ifdef HAVE_DETAILED_TIMINGS #ifdef HAVE_DETAILED_TIMINGS
call timer%start("solve_evp_real_2stage_single") call timer%start("solve_evp_real_2stage_single")
#endif #endif
#ifdef HAVE_DETAILED_TIMINGS
call timer%start("mpi_communication")
#endif
call mpi_comm_rank(mpi_comm_all,my_pe,mpierr) call mpi_comm_rank(mpi_comm_all,my_pe,mpierr)
call mpi_comm_size(mpi_comm_all,n_pes,mpierr) call mpi_comm_size(mpi_comm_all,n_pes,mpierr)
...@@ -815,7 +826,9 @@ module ELPA2 ...@@ -815,7 +826,9 @@ module ELPA2
call mpi_comm_size(mpi_comm_rows,np_rows,mpierr) call mpi_comm_size(mpi_comm_rows,np_rows,mpierr)
call mpi_comm_rank(mpi_comm_cols,my_pcol,mpierr) call mpi_comm_rank(mpi_comm_cols,my_pcol,mpierr)
call mpi_comm_size(mpi_comm_cols,np_cols,mpierr) call mpi_comm_size(mpi_comm_cols,np_cols,mpierr)
#ifdef HAVE_DETAILED_TIMINGS
call timer%stop("mpi_communication")
#endif
wantDebug = .false. wantDebug = .false.
if (firstCall) then if (firstCall) then
! are debug messages desired? ! are debug messages desired?
...@@ -965,7 +978,9 @@ module ELPA2 ...@@ -965,7 +978,9 @@ module ELPA2
write(error_unit,*) 'Time tridiag_band_real :',ttt1-ttt0 write(error_unit,*) 'Time tridiag_band_real :',ttt1-ttt0
#ifdef WITH_MPI #ifdef WITH_MPI
#ifdef HAVE_DETAILED_TIMINGS
call timer%start("mpi_communication")
#endif
#ifdef DOUBLE_PRECISION_REAL #ifdef DOUBLE_PRECISION_REAL
call mpi_bcast(ev,na,MPI_REAL8,0,mpi_comm_all,mpierr) call mpi_bcast(ev,na,MPI_REAL8,0,mpi_comm_all,mpierr)
call mpi_bcast(e,na,MPI_REAL8,0,mpi_comm_all,mpierr) call mpi_bcast(e,na,MPI_REAL8,0,mpi_comm_all,mpierr)
...@@ -973,7 +988,9 @@ module ELPA2 ...@@ -973,7 +988,9 @@ module ELPA2
call mpi_bcast(ev,na,MPI_REAL4,0,mpi_comm_all,mpierr) call mpi_bcast(ev,na,MPI_REAL4,0,mpi_comm_all,mpierr)
call mpi_bcast(e,na,MPI_REAL4,0,mpi_comm_all,mpierr) call mpi_bcast(e,na,MPI_REAL4,0,mpi_comm_all,mpierr)
#endif #endif
#ifdef HAVE_DETAILED_TIMINGS
call timer%stop("mpi_communication")
#endif
#endif /* WITH_MPI */ #endif /* WITH_MPI */
ttt1 = MPI_Wtime() ttt1 = MPI_Wtime()
time_evp_fwd = ttt1-ttts time_evp_fwd = ttt1-ttts
...@@ -1151,7 +1168,9 @@ function solve_evp_complex_2stage_single(na, nev, a, lda, ev, q, ldq, nblk, & ...@@ -1151,7 +1168,9 @@ function solve_evp_complex_2stage_single(na, nev, a, lda, ev, q, ldq, nblk, &
#ifdef HAVE_DETAILED_TIMINGS #ifdef HAVE_DETAILED_TIMINGS
call timer%start("solve_evp_complex_2stage_double") call timer%start("solve_evp_complex_2stage_double")
#endif #endif
#ifdef HAVE_DETAILED_TIMINGS
call timer%start("mpi_communication")
#endif
call mpi_comm_rank(mpi_comm_all,my_pe,mpierr) call mpi_comm_rank(mpi_comm_all,my_pe,mpierr)
call mpi_comm_size(mpi_comm_all,n_pes,mpierr) call mpi_comm_size(mpi_comm_all,n_pes,mpierr)
...@@ -1159,7 +1178,9 @@ function solve_evp_complex_2stage_single(na, nev, a, lda, ev, q, ldq, nblk, & ...@@ -1159,7 +1178,9 @@ function solve_evp_complex_2stage_single(na, nev, a, lda, ev, q, ldq, nblk, &
call mpi_comm_size(mpi_comm_rows,np_rows,mpierr) call mpi_comm_size(mpi_comm_rows,np_rows,mpierr)
call mpi_comm_rank(mpi_comm_cols,my_pcol,mpierr) call mpi_comm_rank(mpi_comm_cols,my_pcol,mpierr)
call mpi_comm_size(mpi_comm_cols,np_cols,mpierr) call mpi_comm_size(mpi_comm_cols,np_cols,mpierr)
#ifdef HAVE_DETAILED_TIMINGS
call timer%stop("mpi_communication")
#endif
useGPU = .false. useGPU = .false.
wantDebug = .false. wantDebug = .false.
if (firstCall) then if (firstCall) then
...@@ -1274,7 +1295,9 @@ function solve_evp_complex_2stage_single(na, nev, a, lda, ev, q, ldq, nblk, & ...@@ -1274,7 +1295,9 @@ function solve_evp_complex_2stage_single(na, nev, a, lda, ev, q, ldq, nblk, &
write(error_unit,*) 'Time tridiag_band_complex :',ttt1-ttt0 write(error_unit,*) 'Time tridiag_band_complex :',ttt1-ttt0
#ifdef WITH_MPI #ifdef WITH_MPI
#ifdef HAVE_DETAILED_TIMINGS
call timer%start("mpi_communication")
#endif
#ifdef DOUBLE_PRECISION_COMPLEX #ifdef DOUBLE_PRECISION_COMPLEX
call mpi_bcast(ev, na, mpi_real8, 0, mpi_comm_all, mpierr) call mpi_bcast(ev, na, mpi_real8, 0, mpi_comm_all, mpierr)
call mpi_bcast(e, na, mpi_real8, 0, mpi_comm_all, mpierr) call mpi_bcast(e, na, mpi_real8, 0, mpi_comm_all, mpierr)
...@@ -1282,7 +1305,9 @@ function solve_evp_complex_2stage_single(na, nev, a, lda, ev, q, ldq, nblk, & ...@@ -1282,7 +1305,9 @@ function solve_evp_complex_2stage_single(na, nev, a, lda, ev, q, ldq, nblk, &
call mpi_bcast(ev, na, mpi_real4, 0, mpi_comm_all, mpierr) call mpi_bcast(ev, na, mpi_real4, 0, mpi_comm_all, mpierr)
call mpi_bcast(e, na, mpi_real4, 0, mpi_comm_all, mpierr) call mpi_bcast(e, na, mpi_real4, 0, mpi_comm_all, mpierr)
#endif #endif
#ifdef HAVE_DETAILED_TIMINGS
call timer%stop("mpi_communication")
#endif
#endif /* WITH_MPI */ #endif /* WITH_MPI */
ttt1 = MPI_Wtime() ttt1 = MPI_Wtime()
time_evp_fwd = ttt1-ttts time_evp_fwd = ttt1-ttts
...@@ -1471,7 +1496,9 @@ function solve_evp_complex_2stage_single(na, nev, a, lda, ev, q, ldq, nblk, & ...@@ -1471,7 +1496,9 @@ function solve_evp_complex_2stage_single(na, nev, a, lda, ev, q, ldq, nblk, &
#ifdef HAVE_DETAILED_TIMINGS #ifdef HAVE_DETAILED_TIMINGS
call timer%start("solve_evp_complex_2stage_single") call timer%start("solve_evp_complex_2stage_single")
#endif #endif
#ifdef HAVE_DETAILED_TIMINGS
call timer%start("mpi_communication")
#endif
call mpi_comm_rank(mpi_comm_all,my_pe,mpierr) call mpi_comm_rank(mpi_comm_all,my_pe,mpierr)
call mpi_comm_size(mpi_comm_all,n_pes,mpierr) call mpi_comm_size(mpi_comm_all,n_pes,mpierr)
...@@ -1479,7 +1506,9 @@ function solve_evp_complex_2stage_single(na, nev, a, lda, ev, q, ldq, nblk, & ...@@ -1479,7 +1506,9 @@ function solve_evp_complex_2stage_single(na, nev, a, lda, ev, q, ldq, nblk, &
call mpi_comm_size(mpi_comm_rows,np_rows,mpierr) call mpi_comm_size(mpi_comm_rows,np_rows,mpierr)
call mpi_comm_rank(mpi_comm_cols,my_pcol,mpierr) call mpi_comm_rank(mpi_comm_cols,my_pcol,mpierr)
call mpi_comm_size(mpi_comm_cols,np_cols,mpierr) call mpi_comm_size(mpi_comm_cols,np_cols,mpierr)
#ifdef HAVE_DETAILED_TIMINGS
call timer%stop("mpi_communication")
#endif
useGPU = .false. useGPU = .false.
wantDebug = .false. wantDebug = .false.
if (firstCall) then if (firstCall) then
...@@ -1594,7 +1623,9 @@ function solve_evp_complex_2stage_single(na, nev, a, lda, ev, q, ldq, nblk, & ...@@ -1594,7 +1623,9 @@ function solve_evp_complex_2stage_single(na, nev, a, lda, ev, q, ldq, nblk, &
write(error_unit,*) 'Time tridiag_band_complex :',ttt1-ttt0 write(error_unit,*) 'Time tridiag_band_complex :',ttt1-ttt0
#ifdef WITH_MPI #ifdef WITH_MPI
#ifdef HAVE_DETAILED_TIMINGS
call timer%start("mpi_communication")
#endif
#ifdef DOUBLE_PRECISION_COMPLEX #ifdef DOUBLE_PRECISION_COMPLEX
call mpi_bcast(ev, na, mpi_real8, 0, mpi_comm_all, mpierr) call mpi_bcast(ev, na, mpi_real8, 0, mpi_comm_all, mpierr)
call mpi_bcast(e, na, mpi_real8, 0, mpi_comm_all, mpierr) call mpi_bcast(e, na, mpi_real8, 0, mpi_comm_all, mpierr)
...@@ -1602,7 +1633,9 @@ function solve_evp_complex_2stage_single(na, nev, a, lda, ev, q, ldq, nblk, & ...@@ -1602,7 +1633,9 @@ function solve_evp_complex_2stage_single(na, nev, a, lda, ev, q, ldq, nblk, &
call mpi_bcast(ev, na, mpi_real4, 0, mpi_comm_all, mpierr) call mpi_bcast(ev, na, mpi_real4, 0, mpi_comm_all, mpierr)
call mpi_bcast(e, na, mpi_real4, 0, mpi_comm_all, mpierr) call mpi_bcast(e, na, mpi_real4, 0, mpi_comm_all, mpierr)
#endif #endif
#ifdef HAVE_DETAILED_TIMINGS
call timer%stop("mpi_communication")
#endif
#endif /* WITH_MPI */ #endif /* WITH_MPI */
ttt1 = MPI_Wtime() ttt1 = MPI_Wtime()
time_evp_fwd = ttt1-ttts time_evp_fwd = ttt1-ttts
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment