Toolbox snapshot
The Reactive C++ Toolbox
Loading...
Searching...
No Matches
Namespaces | Classes | Functions
toolbox::bm Namespace Reference

Namespaces

namespace  detail
 

Classes

struct  Benchmark
 
class  BenchmarkRange
 
class  BenchmarkRecord
 
class  BenchmarkSuite
 
class  Context
 

Functions

void clobber_memory () noexcept
 
template<typename ValueT >
void do_not_optimise (const ValueT &val) noexcept
 
template<typename ValueT >
void do_not_optimise (ValueT &val) noexcept
 

Function Documentation

◆ clobber_memory()

void toolbox::bm::clobber_memory ( )
inlinenoexcept

The clobber_memory function instructs the compiler that something might have changed in the memory and no assumptions can be made that would discard memory writes.

Definition at line 27 of file Utility.hpp.

◆ do_not_optimise() [1/2]

template<typename ValueT >
void toolbox::bm::do_not_optimise ( const ValueT val)
inlinenoexcept

The do_not_optimise function emulates the creation additional uses of the reference essentially instructing the compiler that pointers in it's scope are now available to call though global pointers.

Definition at line 36 of file Utility.hpp.

◆ do_not_optimise() [2/2]

template<typename ValueT >
void toolbox::bm::do_not_optimise ( ValueT val)
inlinenoexcept

The do_not_optimise function emulates the creation additional uses of the reference essentially instructing the compiler that pointers in it's scope are now available to call though global pointers.

Definition at line 45 of file Utility.hpp.