16 #ifndef dealii_timer_h
17 #define dealii_timer_h
50 using rep = duration::rep;
60 using time_point = std::chrono::time_point<CPUClock, duration>;
141 Timer(
MPI_Comm mpi_communicator,
const bool sync_lap_times =
false);
150 get_last_lap_wall_time_data()
const;
159 get_accumulated_wall_time_data()
const;
165 template <
class StreamType>
167 print_last_lap_wall_time_data(StreamType &stream)
const;
173 template <
class StreamType>
175 print_accumulated_wall_time_data(StreamType &stream)
const;
221 last_wall_time()
const;
239 last_cpu_time()
const;
253 template <
class clock_type_>
657 cpu_and_wall_times_grouped
671 const OutputFrequency output_frequency,
685 const OutputFrequency output_frequency,
712 std::ostream & stream,
713 const OutputFrequency output_frequency,
741 const OutputFrequency output_frequency,
755 enter_subsection(
const std::string §ion_name);
763 enter_section(
const std::string §ion_name);
770 leave_subsection(
const std::string §ion_name =
"");
778 exit_section(
const std::string §ion_name =
"");
783 std::map<std::string, double>
784 get_summary_data(
const OutputData kind)
const;
791 print_summary()
const;
811 print_wall_time_statistics(
const MPI_Comm mpi_comm,
812 const double print_quantile = 0.)
const;
921 return last_lap_wall_time_data;
929 return accumulated_wall_time_data;
934 template <
class StreamType>
939 stream << statistic.
max <<
" wall,"
940 <<
" max @" << statistic.
max_index <<
", min=" << statistic.
min <<
" @"
941 << statistic.
min_index <<
", avg=" << statistic.
avg << std::endl;
946 template <
class StreamType>
951 stream << statistic.
max <<
" wall,"
952 <<
" max @" << statistic.
max_index <<
", min=" << statistic.
min <<
" @"
953 << statistic.
min_index <<
", avg=" << statistic.
avg << std::endl;
961 enter_subsection(section_name);
969 leave_subsection(section_name);
973 const std::string & section_name_)
975 , section_name(section_name_)
990 timer.exit_section(section_name);