Skip to content

Commit

Permalink
timing verbosity
Browse files Browse the repository at this point in the history
  • Loading branch information
Angelyr committed Jul 11, 2024
1 parent 50a4002 commit 21954c3
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 1 deletion.
4 changes: 4 additions & 0 deletions src/pmpo_c.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -900,4 +900,8 @@ void polympo_enableTiming_f(){

void polympo_summarizeTime_f(){
pumipic::SummarizeTime();
}

void polympo_setTimingVerbosity_f(int v){
pumipic::SetTimingVerbosity(v);
}
2 changes: 1 addition & 1 deletion src/pmpo_c.h
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,6 @@ void polympo_applyReconstruction_f(MPMesh_ptr p_mpmesh);
// Timing
void polympo_enableTiming_f();
void polympo_summarizeTime_f();

void polympo_setTimingVerbosity_f(int v);
}
#endif
7 changes: 7 additions & 0 deletions src/pmpo_fortran.f90
Original file line number Diff line number Diff line change
Expand Up @@ -714,6 +714,13 @@ subroutine polympo_enableTiming() bind(C, NAME='polympo_enableTiming_f')
subroutine polympo_summarizeTime() bind(C, NAME='polympo_summarizeTime_f')
use :: iso_c_binding
end subroutine
!---------------------------------------------------------------------------
!> @brief set verbosity of timings collected
!---------------------------------------------------------------------------
subroutine polympo_setTimingVerbosity(v) bind(C, NAME='polympo_setTimingVerbosity_f')
use :: iso_c_binding
integer(c_int), value :: v
end subroutine
end interface
contains
!---------------------------------------------------------------------------
Expand Down
1 change: 1 addition & 0 deletions test/testFortranMPAdvection.f90
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ program main
call polympo_setMPICommunicator(mpi_comm_handle)
call polympo_initialize()
call polympo_enableTiming()
call polympo_setTimingVerbosity(1)

call polympo_checkPrecisionForRealKind(MPAS_RKIND)
argc = command_argument_count()
Expand Down

0 comments on commit 21954c3

Please sign in to comment.