12#ifndef ARCANE_UTILS_IPROFILINGSERVICE_H
13#define ARCANE_UTILS_IPROFILINGSERVICE_H
65 virtual void switchEvent() = 0;
108class ARCANE_UTILS_EXPORT ProfilingSentry
116 m_service->startProfiling();
121 m_service->stopProfiling();
154 if (!m_service->isInitialized())
155 m_service->initialize();
156 m_service->startProfiling();
163 m_service->stopProfiling();
165 m_service->printInfos(
false);
171 IProfilingService* service() {
return m_service; }
178 bool m_print_at_end =
false;
Declarations of types used in Arcane.
virtual bool isInitialized() const
Indicates if initialize() has already been called.
virtual ITimerMng * timerMng()=0
Timer using the features of this service if they exist. Can be null.
virtual bool isRunning() const =0
Indicates if the profiling is running.
virtual void stopProfiling()=0
Stops profiling.
virtual void startProfiling()=0
Starts profiling.
virtual void initialize()=0
Initializes the profiling service.
virtual void dumpJSON(JSONWriter &writer)=0
Writes the profiling information to the writer writer.
virtual void reset()=0
Resets the counters.
virtual void printInfos(bool dump_file=false)=0
Displays profiling information.
Interface of a timer manager.
Class allowing automatic start and stop of a service.
void setPrintAtEnd(bool v)
Indicates if results are printed at the end of profiling.
ProfilingSentryWithInitialize(IProfilingService *s)
Constructs an instance associated with the service s.
-- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature --
Array< Int64 > Int64Array
Dynamic one-dimensional array of 64-bit integers.