gem5  v20.0.0.2
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
Public Member Functions | Protected Types | Protected Attributes | List of all members
Trace::InstRecord Class Referenceabstract

#include <insttracer.hh>

Inheritance diagram for Trace::InstRecord:
Trace::ExeTracerRecord Trace::InstPBTraceRecord Trace::IntelTraceRecord Trace::TarmacBaseRecord Trace::NativeTraceRecord Trace::TarmacParserRecord Trace::TarmacTracerRecord Trace::TarmacTracerRecordV8

Public Member Functions

 InstRecord (Tick _when, ThreadContext *_thread, const StaticInstPtr _staticInst, TheISA::PCState _pc, const StaticInstPtr _macroStaticInst=NULL)
 
virtual ~InstRecord ()
 
void setWhen (Tick new_when)
 
void setMem (Addr a, Addr s, unsigned f)
 
template<typename T , size_t N>
void setData (std::array< T, N > d)
 
void setData (uint64_t d)
 
void setData (uint32_t d)
 
void setData (uint16_t d)
 
void setData (uint8_t d)
 
void setData (int64_t d)
 
void setData (int32_t d)
 
void setData (int16_t d)
 
void setData (int8_t d)
 
void setData (double d)
 
void setData (::VecRegContainer< TheISA::VecRegSizeBytes > &d)
 
void setData (::VecPredRegContainer< TheISA::VecPredRegSizeBits, TheISA::VecPredRegHasPackedRepr > &d)
 
void setFetchSeq (InstSeqNum seq)
 
void setCPSeq (InstSeqNum seq)
 
void setPredicate (bool val)
 
virtual void dump ()=0
 
Tick getWhen () const
 
ThreadContextgetThread () const
 
StaticInstPtr getStaticInst () const
 
TheISA::PCState getPCState () const
 
StaticInstPtr getMacroStaticInst () const
 
Addr getAddr () const
 
Addr getSize () const
 
unsigned getFlags () const
 
bool getMemValid () const
 
uint64_t getIntData () const
 
double getFloatData () const
 
int getDataStatus () const
 
InstSeqNum getFetchSeq () const
 
bool getFetchSeqValid () const
 
InstSeqNum getCpSeq () const
 
bool getCpSeqValid () const
 

Protected Types

enum  DataStatus {
  DataInvalid = 0, DataInt8 = 1, DataInt16 = 2, DataInt32 = 4,
  DataInt64 = 8, DataDouble = 3, DataVec = 5, DataVecPred = 6
}
 What size of data was written? More...
 

Protected Attributes

Tick when
 
ThreadContextthread
 
StaticInstPtr staticInst
 
TheISA::PCState pc
 
StaticInstPtr macroStaticInst
 
Addr addr
 The address that was accessed. More...
 
Addr size
 The size of the memory request. More...
 
unsigned flags
 The flags that were assigned to the request. More...
 
union {
   uint64_t   as_int
 
   double   as_double
 
   ::VecRegContainer< TheISA::VecRegSizeBytes > *   as_vec
 
   ::VecPredRegContainer< TheISA::VecPredRegSizeBits, TheISA::VecPredRegHasPackedRepr > *   as_pred
 
data
 
InstSeqNum fetch_seq
 
InstSeqNum cp_seq
 
enum Trace::InstRecord::DataStatus data_status
 
bool mem_valid
 Are the memory fields in the record valid? More...
 
bool fetch_seq_valid
 Are the fetch sequence number fields valid? More...
 
bool cp_seq_valid
 Are the commit sequence number fields valid? More...
 
bool predicate
 is the predicate for execution this inst true or false (not execed)? More...
 

Detailed Description

Definition at line 55 of file insttracer.hh.

Constructor & Destructor Documentation

◆ InstRecord()

Trace::InstRecord::InstRecord ( Tick  _when,
ThreadContext _thread,
const StaticInstPtr  _staticInst,
TheISA::PCState  _pc,
const StaticInstPtr  _macroStaticInst = NULL 
)
inline

Definition at line 147 of file insttracer.hh.

◆ ~InstRecord()

virtual Trace::InstRecord::~InstRecord ( )
inlinevirtual

Definition at line 157 of file insttracer.hh.

References data, data_status, DataVec, and DataVecPred.

Member Function Documentation

◆ dump()

virtual void Trace::InstRecord::dump ( )
pure virtual

◆ getAddr()

Addr Trace::InstRecord::getAddr ( ) const
inline

◆ getCpSeq()

InstSeqNum Trace::InstRecord::getCpSeq ( ) const
inline

Definition at line 242 of file insttracer.hh.

References cp_seq.

◆ getCpSeqValid()

bool Trace::InstRecord::getCpSeqValid ( ) const
inline

Definition at line 243 of file insttracer.hh.

References cp_seq_valid.

◆ getDataStatus()

int Trace::InstRecord::getDataStatus ( ) const
inline

Definition at line 237 of file insttracer.hh.

References data_status.

◆ getFetchSeq()

InstSeqNum Trace::InstRecord::getFetchSeq ( ) const
inline

Definition at line 239 of file insttracer.hh.

References fetch_seq.

◆ getFetchSeqValid()

bool Trace::InstRecord::getFetchSeqValid ( ) const
inline

Definition at line 240 of file insttracer.hh.

References fetch_seq_valid.

◆ getFlags()

unsigned Trace::InstRecord::getFlags ( ) const
inline

Definition at line 232 of file insttracer.hh.

References flags.

Referenced by Trace::InstPBTraceRecord::dump().

◆ getFloatData()

double Trace::InstRecord::getFloatData ( ) const
inline

Definition at line 236 of file insttracer.hh.

References data.

◆ getIntData()

uint64_t Trace::InstRecord::getIntData ( ) const
inline

◆ getMacroStaticInst()

StaticInstPtr Trace::InstRecord::getMacroStaticInst ( ) const
inline

Definition at line 228 of file insttracer.hh.

References macroStaticInst.

Referenced by Trace::ArmNativeTrace::check().

◆ getMemValid()

bool Trace::InstRecord::getMemValid ( ) const
inline

◆ getPCState()

TheISA::PCState Trace::InstRecord::getPCState ( ) const
inline

Definition at line 227 of file insttracer.hh.

References pc.

◆ getSize()

Addr Trace::InstRecord::getSize ( ) const
inline

◆ getStaticInst()

StaticInstPtr Trace::InstRecord::getStaticInst ( ) const
inline

Definition at line 226 of file insttracer.hh.

References staticInst.

Referenced by Trace::X86NativeTrace::check(), and Trace::ArmNativeTrace::check().

◆ getThread()

ThreadContext* Trace::InstRecord::getThread ( ) const
inline

◆ getWhen()

Tick Trace::InstRecord::getWhen ( ) const
inline

Definition at line 224 of file insttracer.hh.

References when.

◆ setCPSeq()

void Trace::InstRecord::setCPSeq ( InstSeqNum  seq)
inline

Definition at line 216 of file insttracer.hh.

◆ setData() [1/12]

template<typename T , size_t N>
void Trace::InstRecord::setData ( std::array< T, N >  d)
inline

◆ setData() [2/12]

void Trace::InstRecord::setData ( uint64_t  d)
inline

Definition at line 185 of file insttracer.hh.

References ArmISA::d, data, data_status, and DataInt64.

◆ setData() [3/12]

void Trace::InstRecord::setData ( uint32_t  d)
inline

Definition at line 186 of file insttracer.hh.

References ArmISA::d, data, data_status, and DataInt32.

◆ setData() [4/12]

void Trace::InstRecord::setData ( uint16_t  d)
inline

Definition at line 187 of file insttracer.hh.

References ArmISA::d, data, data_status, and DataInt16.

◆ setData() [5/12]

void Trace::InstRecord::setData ( uint8_t  d)
inline

Definition at line 188 of file insttracer.hh.

References ArmISA::d, data, data_status, and DataInt8.

◆ setData() [6/12]

void Trace::InstRecord::setData ( int64_t  d)
inline

Definition at line 190 of file insttracer.hh.

References setData().

Referenced by setData().

◆ setData() [7/12]

void Trace::InstRecord::setData ( int32_t  d)
inline

Definition at line 191 of file insttracer.hh.

References setData().

Referenced by setData().

◆ setData() [8/12]

void Trace::InstRecord::setData ( int16_t  d)
inline

Definition at line 192 of file insttracer.hh.

References setData().

Referenced by setData().

◆ setData() [9/12]

void Trace::InstRecord::setData ( int8_t  d)
inline

Definition at line 193 of file insttracer.hh.

References setData().

Referenced by setData().

◆ setData() [10/12]

void Trace::InstRecord::setData ( double  d)
inline

Definition at line 195 of file insttracer.hh.

References ArmISA::d, data, data_status, and DataDouble.

◆ setData() [11/12]

void Trace::InstRecord::setData ( ::VecRegContainer< TheISA::VecRegSizeBytes > &  d)
inline

Definition at line 198 of file insttracer.hh.

References ArmISA::d, data, data_status, and DataVec.

◆ setData() [12/12]

void Trace::InstRecord::setData ( ::VecPredRegContainer< TheISA::VecPredRegSizeBits, TheISA::VecPredRegHasPackedRepr > &  d)
inline

◆ setFetchSeq()

void Trace::InstRecord::setFetchSeq ( InstSeqNum  seq)
inline

Definition at line 213 of file insttracer.hh.

◆ setMem()

void Trace::InstRecord::setMem ( Addr  a,
Addr  s,
unsigned  f 
)
inline

◆ setPredicate()

void Trace::InstRecord::setPredicate ( bool  val)
inline

Definition at line 219 of file insttracer.hh.

References dump(), and X86ISA::val.

Referenced by SimpleExecContext::setPredicate(), and BaseDynInst< Impl >::setPredicate().

◆ setWhen()

void Trace::InstRecord::setWhen ( Tick  new_when)
inline

Definition at line 168 of file insttracer.hh.

Member Data Documentation

◆ addr

Addr Trace::InstRecord::addr
protected

◆ as_double

double Trace::InstRecord::as_double

Definition at line 96 of file insttracer.hh.

◆ as_int

uint64_t Trace::InstRecord::as_int

Definition at line 95 of file insttracer.hh.

◆ as_pred

::VecPredRegContainer<TheISA::VecPredRegSizeBits, TheISA::VecPredRegHasPackedRepr>* Trace::InstRecord::as_pred

Definition at line 99 of file insttracer.hh.

◆ as_vec

::VecRegContainer<TheISA::VecRegSizeBytes>* Trace::InstRecord::as_vec

Definition at line 97 of file insttracer.hh.

◆ cp_seq

InstSeqNum Trace::InstRecord::cp_seq
protected

Definition at line 112 of file insttracer.hh.

Referenced by getCpSeq().

◆ data

union { ... } Trace::InstRecord::data

◆ fetch_seq

InstSeqNum Trace::InstRecord::fetch_seq
protected

Definition at line 106 of file insttracer.hh.

Referenced by getFetchSeq().

◆ flags

unsigned Trace::InstRecord::flags
protected

The flags that were assigned to the request.

Definition at line 82 of file insttracer.hh.

Referenced by getFlags().

◆ macroStaticInst

StaticInstPtr Trace::InstRecord::macroStaticInst
protected

◆ pc

TheISA::PCState Trace::InstRecord::pc
protected

◆ predicate

bool Trace::InstRecord::predicate
protected

is the predicate for execution this inst true or false (not execed)?

Definition at line 144 of file insttracer.hh.

Referenced by Trace::TarmacTracerRecordV8::addInstEntry(), Trace::TarmacTracerRecord::addInstEntry(), and Trace::TarmacBaseRecord::TarmacBaseRecord().

◆ size

Addr Trace::InstRecord::size
protected

The size of the memory request.

Definition at line 81 of file insttracer.hh.

Referenced by getSize(), Trace::TarmacTracerRecordV8::TraceMemEntryV8::print(), and Trace::TarmacTracerRecord::TraceMemEntry::print().

◆ staticInst

StaticInstPtr Trace::InstRecord::staticInst
protected

◆ thread

ThreadContext* Trace::InstRecord::thread
protected

◆ when

Tick Trace::InstRecord::when
protected

Definition at line 58 of file insttracer.hh.

Referenced by getWhen(), and Trace::InstTracer::~InstTracer().


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

Generated on Mon Jun 8 2020 15:46:05 for gem5 by doxygen 1.8.13