DOLFINx 0.8.0
DOLFINx C++ interface
Loading...
Searching...
No Matches
timing.h
1// Copyright (C) 2005-2010 Anders Logg, 2015 Jan Blechta
2//
3// This file is part of DOLFINx (https://www.fenicsproject.org)
4//
5// SPDX-License-Identifier: LGPL-3.0-or-later
6
7#pragma once
8
9#include <dolfinx/common/Table.h>
10#include <mpi.h>
11#include <set>
12#include <string>
13#include <tuple>
14
15namespace dolfinx
16{
17
22enum class TimingType : int
23{
24 wall = 0,
25 user = 1,
26 system = 2
27};
28
33Table timings(std::set<TimingType> type);
34
41void list_timings(MPI_Comm comm, std::set<TimingType> type,
42 Table::Reduction reduction = Table::Reduction::max);
43
49std::tuple<std::size_t, double, double, double> timing(std::string task);
50
51} // namespace dolfinx
Reduction
Definition Table.h:33
Top-level namespace.
Definition defines.h:12
void list_timings(MPI_Comm comm, std::set< TimingType > type, Table::Reduction reduction=Table::Reduction::max)
Definition timing.cpp:22
std::tuple< std::size_t, double, double, double > timing(std::string task)
Definition timing.cpp:29
Table timings(std::set< TimingType > type)
Definition timing.cpp:17
TimingType
Definition timing.h:23