profile_start_timer Subroutine

private subroutine profile_start_timer(self, label)

Type Bound

type_time

Arguments

Type IntentOptional Attributes Name
class(type_time), intent(inout) :: self
character(len=*), intent(in) :: label

Called by

proc~~profile_start_timer~~CalledByGraph proc~profile_start_timer type_time%profile_start_timer proc~initialize_type_ftdss type_ftdss%initialize_type_ftdss proc~initialize_type_ftdss->proc~profile_start_timer

Source Code

    subroutine profile_start_timer(self, label)
        class(type_time), intent(inout) :: self
        character(len=*), intent(in) :: label
        integer :: i
        do i = 1, size(self%sections)
            if (trim(self%sections(i)%label) == trim(label)) then
#ifdef _OPENMP
                self%sections(i)%start_time_wtime = omp_get_wtime()
#else
                call system_clock(count=self%sections(i)%start_tick)
#endif
                return
            end if
        end do
        write (*, '(3a)') "Error: Profiling section '", trim(label), "' not found. Timer not started."
    end subroutine profile_start_timer