gem5  v22.0.0.1
Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
sc_gem5::VcdTraceFile Class Reference

#include <vcd.hh>

Inheritance diagram for sc_gem5::VcdTraceFile:
sc_gem5::TraceFile sc_core::sc_trace_file

Public Member Functions

 VcdTraceFile (const std::string &name)
 
 ~VcdTraceFile ()
 
void trace (bool delta) override
 
template<typename TV >
void addNewTraceVal (const typename TV::TracedType *v, const std::string &name, int width=1)
 
void addTraceVal (const bool *v, const std::string &name) override
 
void addTraceVal (const float *v, const std::string &name) override
 
void addTraceVal (const double *v, const std::string &name) override
 
void addTraceVal (const sc_dt::sc_logic *v, const std::string &name) override
 
void addTraceVal (const sc_dt::sc_int_base *v, const std::string &name) override
 
void addTraceVal (const sc_dt::sc_uint_base *v, const std::string &name) override
 
void addTraceVal (const sc_dt::sc_signed *v, const std::string &name) override
 
void addTraceVal (const sc_dt::sc_unsigned *v, const std::string &name) override
 
void addTraceVal (const sc_dt::sc_bv_base *v, const std::string &name) override
 
void addTraceVal (const sc_dt::sc_lv_base *v, const std::string &name) override
 
void addTraceVal (const sc_dt::sc_fxval *v, const std::string &name) override
 
void addTraceVal (const sc_dt::sc_fxval_fast *v, const std::string &name) override
 
void addTraceVal (const sc_dt::sc_fxnum *v, const std::string &name) override
 
void addTraceVal (const sc_dt::sc_fxnum_fast *v, const std::string &name) override
 
void addTraceVal (const sc_core::sc_event *v, const std::string &name) override
 
void addTraceVal (const sc_core::sc_time *v, const std::string &name) override
 
void addTraceVal (const unsigned char *v, const std::string &name, int width) override
 
void addTraceVal (const char *v, const std::string &name, int width) override
 
void addTraceVal (const unsigned short *v, const std::string &name, int width) override
 
void addTraceVal (const short *v, const std::string &name, int width) override
 
void addTraceVal (const unsigned int *v, const std::string &name, int width) override
 
void addTraceVal (const int *v, const std::string &name, int width) override
 
void addTraceVal (const unsigned long *v, const std::string &name, int width) override
 
void addTraceVal (const long *v, const std::string &name, int width) override
 
void addTraceVal (const sc_dt::int64 *v, const std::string &name, int width) override
 
void addTraceVal (const sc_dt::uint64 *v, const std::string &name, int width) override
 
void addTraceVal (const unsigned int *, const std::string &name, const char **literals) override
 
void writeComment (const std::string &comment) override
 
- Public Member Functions inherited from sc_gem5::TraceFile
 ~TraceFile ()
 
void traceDeltas (bool on)
 
void set_time_unit (double, ::sc_core::sc_time_unit) override
 
void finalizeTime ()
 
- Public Member Functions inherited from sc_core::sc_trace_file
virtual ~sc_trace_file ()
 
virtual void set_time_unit (double, sc_time_unit)=0
 

Private Member Functions

std::string nextSignalName ()
 
void initialize ()
 

Private Attributes

gem5::Tick lastPrintedTime
 
uint64_t deltasAtNow
 
char _nextName [NextNameChars+1]
 
bool initialized
 
std::vector< VcdTraceValBase * > traceVals
 
VcdTraceScope topScope
 

Static Private Attributes

static const int NextNameChars = 5
 

Additional Inherited Members

- Protected Member Functions inherited from sc_gem5::TraceFile
 TraceFile (const std::string &name)
 
std::ostream & stream ()
 
- Protected Member Functions inherited from sc_core::sc_trace_file
 sc_trace_file ()
 
- Protected Attributes inherited from sc_gem5::TraceFile
gem5::OutputStream_os
 
uint64_t timeUnitTicks
 
double timeUnitValue
 
::sc_core::sc_time_unit timeUnitUnit
 
bool _traceDeltas
 

Detailed Description

Definition at line 52 of file vcd.hh.

Constructor & Destructor Documentation

◆ VcdTraceFile()

sc_gem5::VcdTraceFile::VcdTraceFile ( const std::string &  name)
inline

Definition at line 69 of file vcd.hh.

References _nextName, gem5::ArmISA::i, and NextNameChars.

◆ ~VcdTraceFile()

sc_gem5::VcdTraceFile::~VcdTraceFile ( )

Member Function Documentation

◆ addNewTraceVal()

template<typename TV >
void sc_gem5::VcdTraceFile::addNewTraceVal ( const typename TV::TracedType *  v,
const std::string &  name,
int  width = 1 
)
inline

◆ addTraceVal() [1/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const bool *  v,
const std::string &  name 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 339 of file vcd.cc.

References name(), and gem5::VegaISA::v.

◆ addTraceVal() [2/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const char *  v,
const std::string &  name,
int  width 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 629 of file vcd.cc.

References name(), gem5::VegaISA::v, and gem5::ArmISA::width.

◆ addTraceVal() [3/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const double *  v,
const std::string &  name 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 365 of file vcd.cc.

References name(), and gem5::VegaISA::v.

◆ addTraceVal() [4/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const float *  v,
const std::string &  name 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 360 of file vcd.cc.

References name(), and gem5::VegaISA::v.

◆ addTraceVal() [5/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const int *  v,
const std::string &  name,
int  width 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 651 of file vcd.cc.

References name(), gem5::VegaISA::v, and gem5::ArmISA::width.

◆ addTraceVal() [6/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const long *  v,
const std::string &  name,
int  width 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 662 of file vcd.cc.

References name(), gem5::VegaISA::v, and gem5::ArmISA::width.

◆ addTraceVal() [7/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const sc_core::sc_event v,
const std::string &  name 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 553 of file vcd.cc.

References name(), and gem5::VegaISA::v.

◆ addTraceVal() [8/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const sc_core::sc_time v,
const std::string &  name 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 589 of file vcd.cc.

References name(), and gem5::VegaISA::v.

◆ addTraceVal() [9/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const sc_dt::int64 v,
const std::string &  name,
int  width 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 668 of file vcd.cc.

References name(), gem5::VegaISA::v, and gem5::ArmISA::width.

◆ addTraceVal() [10/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const sc_dt::sc_bv_base v,
const std::string &  name 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 465 of file vcd.cc.

References name(), and gem5::VegaISA::v.

◆ addTraceVal() [11/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const sc_dt::sc_fxnum v,
const std::string &  name 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 524 of file vcd.cc.

References name(), and gem5::VegaISA::v.

◆ addTraceVal() [12/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const sc_dt::sc_fxnum_fast v,
const std::string &  name 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 529 of file vcd.cc.

References name(), and gem5::VegaISA::v.

◆ addTraceVal() [13/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const sc_dt::sc_fxval v,
const std::string &  name 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 492 of file vcd.cc.

References name(), and gem5::VegaISA::v.

◆ addTraceVal() [14/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const sc_dt::sc_fxval_fast v,
const std::string &  name 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 497 of file vcd.cc.

References name(), and gem5::VegaISA::v.

◆ addTraceVal() [15/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const sc_dt::sc_int_base v,
const std::string &  name 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 420 of file vcd.cc.

References name(), and gem5::VegaISA::v.

◆ addTraceVal() [16/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const sc_dt::sc_logic v,
const std::string &  name 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 387 of file vcd.cc.

References name(), and gem5::VegaISA::v.

◆ addTraceVal() [17/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const sc_dt::sc_lv_base v,
const std::string &  name 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 470 of file vcd.cc.

References name(), and gem5::VegaISA::v.

◆ addTraceVal() [18/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const sc_dt::sc_signed v,
const std::string &  name 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 433 of file vcd.cc.

References name(), and gem5::VegaISA::v.

◆ addTraceVal() [19/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const sc_dt::sc_uint_base v,
const std::string &  name 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 426 of file vcd.cc.

References name(), and gem5::VegaISA::v.

◆ addTraceVal() [20/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const sc_dt::sc_unsigned v,
const std::string &  name 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 438 of file vcd.cc.

References name(), and gem5::VegaISA::v.

◆ addTraceVal() [21/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const sc_dt::uint64 v,
const std::string &  name,
int  width 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 674 of file vcd.cc.

References name(), gem5::VegaISA::v, and gem5::ArmISA::width.

◆ addTraceVal() [22/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const short *  v,
const std::string &  name,
int  width 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 640 of file vcd.cc.

References name(), gem5::VegaISA::v, and gem5::ArmISA::width.

◆ addTraceVal() [23/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const unsigned char *  v,
const std::string &  name,
int  width 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 623 of file vcd.cc.

References name(), gem5::VegaISA::v, and gem5::ArmISA::width.

◆ addTraceVal() [24/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const unsigned int *  v,
const std::string &  name,
const char **  literals 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 681 of file vcd.cc.

References gem5::bits(), gem5::X86ISA::count, name(), and gem5::VegaISA::v.

◆ addTraceVal() [25/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const unsigned int *  v,
const std::string &  name,
int  width 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 645 of file vcd.cc.

References name(), gem5::VegaISA::v, and gem5::ArmISA::width.

◆ addTraceVal() [26/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const unsigned long *  v,
const std::string &  name,
int  width 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 656 of file vcd.cc.

References name(), gem5::VegaISA::v, and gem5::ArmISA::width.

◆ addTraceVal() [27/27]

void sc_gem5::VcdTraceFile::addTraceVal ( const unsigned short *  v,
const std::string &  name,
int  width 
)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 634 of file vcd.cc.

References name(), gem5::VegaISA::v, and gem5::ArmISA::width.

◆ initialize()

void sc_gem5::VcdTraceFile::initialize ( )
private

◆ nextSignalName()

std::string sc_gem5::VcdTraceFile::nextSignalName ( )
private

Definition at line 205 of file vcd.cc.

References _nextName, name(), and NextNameChars.

Referenced by addNewTraceVal().

◆ trace()

void sc_gem5::VcdTraceFile::trace ( bool  delta)
overridevirtual

◆ writeComment()

void sc_gem5::VcdTraceFile::writeComment ( const std::string &  comment)
overridevirtual

Implements sc_gem5::TraceFile.

Definition at line 696 of file vcd.cc.

References sc_gem5::TraceFile::stream().

Referenced by initialize().

Member Data Documentation

◆ _nextName

char sc_gem5::VcdTraceFile::_nextName[NextNameChars+1]
private

Definition at line 59 of file vcd.hh.

Referenced by nextSignalName(), and VcdTraceFile().

◆ deltasAtNow

uint64_t sc_gem5::VcdTraceFile::deltasAtNow
private

Definition at line 56 of file vcd.hh.

Referenced by trace().

◆ initialized

bool sc_gem5::VcdTraceFile::initialized
private

Definition at line 62 of file vcd.hh.

Referenced by initialize(), and trace().

◆ lastPrintedTime

gem5::Tick sc_gem5::VcdTraceFile::lastPrintedTime
private

Definition at line 55 of file vcd.hh.

Referenced by initialize(), and trace().

◆ NextNameChars

const int sc_gem5::VcdTraceFile::NextNameChars = 5
staticprivate

Definition at line 58 of file vcd.hh.

Referenced by nextSignalName(), and VcdTraceFile().

◆ topScope

VcdTraceScope sc_gem5::VcdTraceFile::topScope
private

Definition at line 66 of file vcd.hh.

Referenced by addNewTraceVal(), and initialize().

◆ traceVals

std::vector<VcdTraceValBase *> sc_gem5::VcdTraceFile::traceVals
private

Definition at line 65 of file vcd.hh.

Referenced by addNewTraceVal(), initialize(), trace(), and ~VcdTraceFile().


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

Generated on Sat Jun 18 2022 08:15:27 for gem5 by doxygen 1.8.17