gem5 v24.0.0.0
Loading...
Searching...
No Matches
gem5::Globals Class Reference

Container for serializing global variables (not associated with any serialized object). More...

#include <globals.hh>

Inheritance diagram for gem5::Globals:
gem5::Serializable

Public Member Functions

 Globals ()
 
 ~Globals ()=default
 
void serialize (CheckpointOut &cp) const override
 Serialize an object.
 
void unserialize (CheckpointIn &cp) override
 Unserialize an object.
 
- Public Member Functions inherited from gem5::Serializable
 Serializable ()
 
virtual ~Serializable ()
 
void serializeSection (CheckpointOut &cp, const char *name) const
 Serialize an object into a new section.
 
void serializeSection (CheckpointOut &cp, const std::string &name) const
 
void unserializeSection (CheckpointIn &cp, const char *name)
 Unserialize an a child object.
 
void unserializeSection (CheckpointIn &cp, const std::string &name)
 

Public Attributes

Tick unserializedCurTick
 

Additional Inherited Members

- Static Public Member Functions inherited from gem5::Serializable
static const std::string & currentSection ()
 Gets the fully-qualified name of the active section.
 
static void generateCheckpointOut (const std::string &cpt_dir, std::ofstream &outstream)
 Generate a checkpoint file so that the serialization can be routed to it.
 

Detailed Description

Container for serializing global variables (not associated with any serialized object).

Definition at line 54 of file globals.hh.

Constructor & Destructor Documentation

◆ Globals()

gem5::Globals::Globals ( )
inline

Definition at line 57 of file globals.hh.

◆ ~Globals()

gem5::Globals::~Globals ( )
default

Member Function Documentation

◆ serialize()

void gem5::Globals::serialize ( CheckpointOut & cp) const
overridevirtual

Serialize an object.

Output an object's state into the current checkpoint section.

Parameters
cpCheckpoint state

Implements gem5::Serializable.

Definition at line 59 of file globals.cc.

References gem5::curTick(), gem5::paramOut(), SERIALIZE_CONTAINER, and gem5::version_tags.

Referenced by TEST_F().

◆ unserialize()

void gem5::Globals::unserialize ( CheckpointIn & cp)
overridevirtual

Unserialize an object.

Read an object's state from the current checkpoint section.

Parameters
cpCheckpoint state

Implements gem5::Serializable.

Definition at line 66 of file globals.cc.

References gem5::arrayParamIn(), gem5::Serializable::currentSection(), gem5::ArmISA::err, gem5::CheckpointIn::find(), gem5::paramIn(), gem5::ArmISA::t, unserializedCurTick, gem5::version_tags, and warn.

Referenced by TEST_F(), TEST_F(), TEST_F(), TEST_F(), and TEST_F().

Member Data Documentation

◆ unserializedCurTick

Tick gem5::Globals::unserializedCurTick

Definition at line 63 of file globals.hh.

Referenced by TEST_F(), TEST_F(), TEST_F(), TEST_F(), unserialize(), and gem5::Root::unserialize().


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

Generated on Tue Jun 18 2024 16:24:11 for gem5 by doxygen 1.11.0