Vulpes  0.1.0
Versatile and parallel compUtational Library for high-order discontinuous Polytopal Element Simulations
Loading...
Searching...
No Matches
profiler.hpp File Reference
#include <algorithm>
#include <chrono>
#include <cstddef>
#include <iomanip>
#include <iostream>
#include <string>
#include <unordered_map>
#include <utility>
#include <vector>
#include <nlohmann/json.hpp>
Include dependency graph for profiler.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  Profiler
 Collects high-resolution timing data for labeled code sections. More...

Macros

#define PROFILE(func)
 Time a single execution of func under the label #func using Profiler::start()/stop().
#define PROFILE_INTERVAL(func)
 Time a single execution of func under the label #func using Profiler::startInterval()/stopInterval().

Macro Definition Documentation

◆ PROFILE

#define PROFILE ( func)
Value:
do { \
Profiler::start(#func); \
func; \
Profiler::stop(#func); \
} while (0)

Time a single execution of func under the label #func using Profiler::start()/stop().

◆ PROFILE_INTERVAL

#define PROFILE_INTERVAL ( func)
Value:
do { \
Profiler::startInterval(#func); \
func; \
Profiler::stopInterval(#func); \
} while (0)

Time a single execution of func under the label #func using Profiler::startInterval()/stopInterval().