scc 2025.09
SystemC components library
scc::perf_estimator Class Reference

a performance estimator More...

#include <perf_estimator.h>

Inheritance diagram for scc::perf_estimator:
Collaboration diagram for scc::perf_estimator:

Public Member Functions

 perf_estimator ()
 default constructor creating an unnamed perf_estimator
 perf_estimator (sc_core::sc_time heart_beat)
 default constructor creating an unnamed perf_estimator having a heart beat
virtual ~perf_estimator ()
 destructor
void set_cycle_time (sc_core::sc_time cycle_period)
 set the cycle time for cylces per second calculation

Protected Member Functions

 perf_estimator (const sc_core::sc_module_name &nm, sc_core::sc_time heart_beat)
void end_of_elaboration () override
 SystemC callbacks.
void start_of_simulation () override
void end_of_simulation () override
void beat ()
long get_memory ()

Protected Attributes

time_stamp soc
 the recorded time stamps
time_stamp eoe
time_stamp sos
time_stamp eos
sc_core::sc_time beat_delay
sc_core::sc_time cycle_period
long max_memory {0}

Detailed Description

a performance estimator

It records the time stamps a various time points (start and end of simulation) and calculates some performance figures. Optionally it provides a heart beat which periodically calls a functor If a cycle time is provides it calculates also the cycles per (wall clock) second

Definition at line 39 of file perf_estimator.h.

Constructor & Destructor Documentation

◆ perf_estimator() [1/2]

scc::perf_estimator::perf_estimator ( )
inline

default constructor creating an unnamed perf_estimator

Definition at line 67 of file perf_estimator.h.

◆ perf_estimator() [2/2]

scc::perf_estimator::perf_estimator ( sc_core::sc_time heart_beat)
inline

default constructor creating an unnamed perf_estimator having a heart beat

Parameters
heart_beat

Definition at line 75 of file perf_estimator.h.

◆ ~perf_estimator()

scc::perf_estimator::~perf_estimator ( )
virtual

destructor

Definition at line 49 of file perf_estimator.cpp.

Member Function Documentation

◆ beat()

void scc::perf_estimator::beat ( )
protected

Definition at line 85 of file perf_estimator.cpp.

◆ end_of_elaboration()

void scc::perf_estimator::end_of_elaboration ( )
overrideprotected

SystemC callbacks.

Definition at line 63 of file perf_estimator.cpp.

◆ end_of_simulation()

void scc::perf_estimator::end_of_simulation ( )
overrideprotected

Definition at line 70 of file perf_estimator.cpp.

◆ get_memory()

long scc::perf_estimator::get_memory ( )
protected

Definition at line 152 of file perf_estimator.cpp.

◆ set_cycle_time()

void scc::perf_estimator::set_cycle_time ( sc_core::sc_time cycle_period)
inline

set the cycle time for cylces per second calculation

Parameters
cycle_period

Definition at line 89 of file perf_estimator.h.

◆ start_of_simulation()

void scc::perf_estimator::start_of_simulation ( )
overrideprotected

Definition at line 65 of file perf_estimator.cpp.

Member Data Documentation

◆ beat_delay

sc_core::sc_time scc::perf_estimator::beat_delay
protected

Definition at line 102 of file perf_estimator.h.

◆ cycle_period

sc_core::sc_time scc::perf_estimator::cycle_period
protected

Definition at line 102 of file perf_estimator.h.

◆ eoe

time_stamp scc::perf_estimator::eoe
protected

Definition at line 99 of file perf_estimator.h.

◆ eos

time_stamp scc::perf_estimator::eos
protected

Definition at line 101 of file perf_estimator.h.

◆ max_memory

long scc::perf_estimator::max_memory {0}
protected

Definition at line 105 of file perf_estimator.h.

◆ soc

time_stamp scc::perf_estimator::soc
protected

the recorded time stamps

Definition at line 98 of file perf_estimator.h.

◆ sos

time_stamp scc::perf_estimator::sos
protected

Definition at line 100 of file perf_estimator.h.


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