18 void StartSetup() { m_setupStartTime = std::chrono::steady_clock::now(); }
24 m_setupDuration = std::chrono::steady_clock::now() - m_setupStartTime;
30 void StartSolve() { m_solveStartTime = std::chrono::steady_clock::now(); }
37 auto now = std::chrono::steady_clock::now();
38 ++m_solveMeasurements;
39 m_averageSolveDuration =
40 (m_solveMeasurements - 1.0) / m_solveMeasurements *
41 m_averageSolveDuration +
42 1.0 / m_solveMeasurements * (
now - m_solveStartTime);
49 using std::chrono::duration_cast;
50 using std::chrono::nanoseconds;
63 using std::chrono::duration_cast;
64 using std::chrono::nanoseconds;
69 std::chrono::steady_clock::time_point m_setupStartTime;
70 std::chrono::duration<double> m_setupDuration{0.0};
72 int m_solveMeasurements = 0;
73 std::chrono::duration<double> m_averageSolveDuration{0.0};
74 std::chrono::steady_clock::time_point m_solveStartTime;
Definition Profiler.hpp:13
void StopSolve()
Definition Profiler.hpp:36
void StartSetup()
Definition Profiler.hpp:18
double SetupDuration() const
Definition Profiler.hpp:48
int SolveMeasurements() const
Definition Profiler.hpp:57
double AverageSolveDuration() const
Definition Profiler.hpp:62
void StartSolve()
Definition Profiler.hpp:30
void StopSetup()
Definition Profiler.hpp:23
Definition Expression.hpp:18
IntrusiveSharedPtr< T > AllocateIntrusiveShared(Alloc alloc, Args &&... args)
Definition IntrusiveSharedPtr.hpp:275