Go to the documentation of this file.
44 #ifndef __SIM_CLOCKED_OBJECT_HH__
45 #define __SIM_CLOCKED_OBJECT_HH__
48 #include "params/ClockedObject.hh"
100 cycle += elapsedCycles;
140 cycle = elapsedCycles;
250 #endif //__SIM_CLOCKED_OBJECT_HH__
Tick curTick()
The universal simulation clock.
Clocked & operator=(Clocked &)=delete
virtual void clockPeriodUpdated()
A hook subclasses can implement so they can do any extra work that's needed when the clock rate is ch...
Cycles curCycle() const
Determine the current cycle, corresponding to a tick aligned to a clock edge.
Tick Frequency
The simulated frequency of curTick(). (In ticks per second)
void registerWithClockDomain(Clocked *c)
Register a Clocked object with this ClockDomain.
void unserialize(CheckpointIn &cp) override
Unserialize an object.
void update() const
Align cycle and tick to the next clock edge if not already done.
Helper class for objects that need to be clocked.
Cycles is a wrapper class for representing cycle counts, i.e.
virtual ~Clocked()
Virtual destructor due to inheritance.
Tick cyclesToTicks(Cycles c) const
The ClockDomain provides clock to group of clocked objects bundled under the same clock domain.
ClockedObject(const ClockedObjectParams &p)
uint64_t Tick
Tick count type.
Helper class for objects that have power states.
void serialize(CheckpointOut &cp) const override
Serialize an object.
void updateClockPeriod()
Update the tick to the current tick.
Abstract superclass for simulation objects.
double voltage() const
Get the current voltage this clock domain operates at.
ClockDomain & clockDomain
The clock domain this clocked object belongs to.
The ClockedObject class extends the SimObject with a clock and accessor functions to relate ticks to ...
Tick clockEdge(Cycles cycles=Cycles(0)) const
Determine the tick when a cycle begins, by default the current one, but the argument also enables the...
static constexpr T divCeil(const T &a, const U &b)
Tick nextCycle() const
Based on the clock of the object, determine the start tick of the first cycle that is at least one cy...
Clocked(ClockDomain &clk_domain)
Create a clocked object and set the clock domain based on the parameters.
void resetClock() const
Reset the object's clock using the current global tick value.
std::ostream CheckpointOut
ClockedObjectParams Params
Parameters of ClockedObject.
Cycles ticksToCycles(Tick t) const
uint64_t frequency() const
Reference material can be found at the JEDEC website: UFS standard http://www.jedec....
Tick clockPeriod() const
Get the clock period.
Generated on Sun Jul 30 2023 01:56:59 for gem5 by doxygen 1.8.17