Go to the documentation of this file.
15 #include <boost/format.hpp>
51 for (
unsigned long i = 0; i <
m_cycles; ++i ) result += sin(
gauss() );
85 const std::string format =
"| %1$-6d| %2$-12.5g| %3$12.5g+-%4$-12.5g|%6$12.5g/%7$-12.5g|";
86 const std::string header =
"| |%1$=7.7s|%2$=13.13s|%3$13.13s+-%4$-12.12s|%6$12.12g/%7$-12.12s|";
88 using namespace boost::io;
90 hdr.exceptions( all_error_bits ^ ( too_many_args_bit | too_few_args_bit ) );
92 hdr %
"#" %
"Total" %
"Mean" %
"RMS" %
"ErrMean" %
"Min" %
"Max";
94 always() <<
"The timing is (in us)" <<
std::endl
108 using GaudiTestSuite::TimingAlg::TimingAlg;
StatusCode execute() override
double doSomething()
do something CPU-intensive
SmartIF< IRndmGenSvc > & randSvc() const
The standard RandomGen service, Return a pointer to the service if present.
IChronoSvc::ChronoStatus stop()
stop the chrono
const std::string & name() const override
The identifying name of the algorithm object.
Alias for backward compatibility.
IChronoSvc::ChronoStatus start()
start the current chrono
SmartIF< IChronoStatSvc > & chronoSvc() const
The standard Chrono & Stat service, Return a pointer to the service if present.
Parameters for the Gauss random number generation.
Random number accessor This small class encapsulates the use of the random number generator.
std::string outputUserTime() const
print the chrono ;
GAUDI_API std::string format(const char *,...)
MsgStream format utility "a la sprintf(...)".
MsgStream & endmsg(MsgStream &s)
MsgStream Modifier: endmsg. Calls the output method of the MsgStream.
Gaudi::Property< unsigned long > m_cycles
the length of the internal loops (property)
StatusCode finalize() override
the default (empty) implementation of IStateful::finalize() method
constexpr static const auto SUCCESS
#define DECLARE_COMPONENT(type)
StatusCode finalize() override
Algorithm(std::string name, ISvcLocator *svcloc, std::string version=PACKAGE_VERSION)
Constructor.