CppBenchmark  1.0.4.0
C++ Benchmark Library
Public Member Functions | Protected Member Functions | List of all members
CppBenchmark::FixturePC Class Reference

Producers/Consumers benchmark fixture. More...

#include <fixture_pc.h>

Inheritance diagram for CppBenchmark::FixturePC:
CppBenchmark::BenchmarkPC

Public Member Functions

 FixturePC () noexcept=default
 
 FixturePC (const FixturePC &) noexcept=default
 
 FixturePC (FixturePC &&) noexcept=default
 
virtual ~FixturePC () noexcept=default
 
FixturePCoperator= (const FixturePC &) noexcept=default
 
FixturePCoperator= (FixturePC &&) noexcept=default
 

Protected Member Functions

virtual void Initialize (ContextPC &context)
 Initialize benchmark. More...
 
virtual void Cleanup (ContextPC &context)
 Cleanup benchmark. More...
 
virtual void InitializeProducer (ContextPC &context)
 Initialize producer. More...
 
virtual void InitializeConsumer (ContextPC &context)
 Initialize consumer. More...
 
virtual void CleanupProducer (ContextPC &context)
 Cleanup producer. More...
 
virtual void CleanupConsumer (ContextPC &context)
 Cleanup consumer. More...
 

Detailed Description

Producers/Consumers benchmark fixture.

Provides interface to initialize and cleanup producers/consumers benchmarks.

Definition at line 20 of file fixture_pc.h.

Constructor & Destructor Documentation

◆ FixturePC() [1/3]

CppBenchmark::FixturePC::FixturePC ( )
defaultnoexcept

◆ FixturePC() [2/3]

CppBenchmark::FixturePC::FixturePC ( const FixturePC )
defaultnoexcept

◆ FixturePC() [3/3]

CppBenchmark::FixturePC::FixturePC ( FixturePC &&  )
defaultnoexcept

◆ ~FixturePC()

virtual CppBenchmark::FixturePC::~FixturePC ( )
virtualdefaultnoexcept

Member Function Documentation

◆ Cleanup()

virtual void CppBenchmark::FixturePC::Cleanup ( ContextPC context)
inlineprotectedvirtual

Cleanup benchmark.

This method is called after benchmark run method.

Parameters
context- Benchmark running context
Examples
mpmc.cpp, mpsc.cpp, and spsc.cpp.

Definition at line 45 of file fixture_pc.h.

◆ CleanupConsumer()

virtual void CppBenchmark::FixturePC::CleanupConsumer ( ContextPC context)
inlineprotectedvirtual

Cleanup consumer.

This method is called to cleanup consumer in separate thread.

Parameters
context- Consumer running context

Definition at line 74 of file fixture_pc.h.

◆ CleanupProducer()

virtual void CppBenchmark::FixturePC::CleanupProducer ( ContextPC context)
inlineprotectedvirtual

Cleanup producer.

This method is called to cleanup producer in separate thread.

Parameters
context- Producer running context

Definition at line 67 of file fixture_pc.h.

◆ Initialize()

virtual void CppBenchmark::FixturePC::Initialize ( ContextPC context)
inlineprotectedvirtual

Initialize benchmark.

This method is called before benchmark run method.

Parameters
context- Benchmark running context
Examples
mpmc.cpp, mpsc.cpp, and spsc.cpp.

Definition at line 38 of file fixture_pc.h.

◆ InitializeConsumer()

virtual void CppBenchmark::FixturePC::InitializeConsumer ( ContextPC context)
inlineprotectedvirtual

Initialize consumer.

This method is called to initialize consumer in separate thread.

Parameters
context- Consumer running context

Definition at line 60 of file fixture_pc.h.

◆ InitializeProducer()

virtual void CppBenchmark::FixturePC::InitializeProducer ( ContextPC context)
inlineprotectedvirtual

Initialize producer.

This method is called to initialize producer in separate thread.

Parameters
context- Producer running context

Definition at line 53 of file fixture_pc.h.

◆ operator=() [1/2]

FixturePC& CppBenchmark::FixturePC::operator= ( const FixturePC )
defaultnoexcept

◆ operator=() [2/2]

FixturePC& CppBenchmark::FixturePC::operator= ( FixturePC &&  )
defaultnoexcept

The documentation for this class was generated from the following file: