gem5 [DEVELOP-FOR-25.1]
Loading...
Searching...
No Matches
cpu.hh
Go to the documentation of this file.
1/*
2 * Copyright (c) 2011-2013, 2016-2020 ARM Limited
3 * Copyright (c) 2013 Advanced Micro Devices, Inc.
4 * Copyright (c) 2022-2023 The University of Edinburgh
5 * All rights reserved
6 *
7 * The license below extends only to copyright in the software and shall
8 * not be construed as granting a license to any other intellectual
9 * property including but not limited to intellectual property relating
10 * to a hardware implementation of the functionality of the software
11 * licensed hereunder. You may use the software subject to the license
12 * terms below provided that you ensure that this notice is replicated
13 * unmodified and in its entirety in all distributions of the software,
14 * modified or unmodified, in source code or in binary form.
15 *
16 * Copyright (c) 2004-2005 The Regents of The University of Michigan
17 * Copyright (c) 2011 Regents of the University of California
18 * All rights reserved.
19 *
20 * Redistribution and use in source and binary forms, with or without
21 * modification, are permitted provided that the following conditions are
22 * met: redistributions of source code must retain the above copyright
23 * notice, this list of conditions and the following disclaimer;
24 * redistributions in binary form must reproduce the above copyright
25 * notice, this list of conditions and the following disclaimer in the
26 * documentation and/or other materials provided with the distribution;
27 * neither the name of the copyright holders nor the names of its
28 * contributors may be used to endorse or promote products derived from
29 * this software without specific prior written permission.
30 *
31 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
32 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
33 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
34 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
35 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
36 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
37 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
38 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
39 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
40 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
41 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
42 */
43
44#ifndef __CPU_O3_CPU_HH__
45#define __CPU_O3_CPU_HH__
46
47#include <iostream>
48#include <list>
49#include <queue>
50#include <set>
51#include <vector>
52
54#include "base/statistics.hh"
55#include "cpu/activity.hh"
56#include "cpu/base.hh"
57#include "cpu/o3/bac.hh"
58#include "cpu/o3/comm.hh"
59#include "cpu/o3/commit.hh"
60#include "cpu/o3/decode.hh"
62#include "cpu/o3/fetch.hh"
63#include "cpu/o3/free_list.hh"
64#include "cpu/o3/ftq.hh"
65#include "cpu/o3/iew.hh"
66#include "cpu/o3/limits.hh"
67#include "cpu/o3/rename.hh"
68#include "cpu/o3/rob.hh"
69#include "cpu/o3/scoreboard.hh"
71#include "cpu/simple_thread.hh"
72#include "cpu/timebuf.hh"
73#include "params/BaseO3CPU.hh"
74#include "sim/process.hh"
75
76namespace gem5
77{
78
79template <class>
80class Checker;
81class ThreadContext;
82
83class Checkpoint;
84class Process;
85
86namespace o3
87{
88
89class ThreadContext;
90
96class CPU : public BaseCPU
97{
98 public:
100
101 friend class ThreadContext;
102
103 public:
112
115
118
121
122 private:
123
126
129
131 void
133 {
134 if (tickEvent.squashed())
136 else if (!tickEvent.scheduled())
138 }
139
141 void
143 {
144 if (tickEvent.scheduled())
145 tickEvent.squash();
146 }
147
159 bool tryDrain();
160
170 void drainSanityCheck() const;
171
173 bool isCpuDrained() const;
174
175 public:
177 CPU(const BaseO3CPUParams &params);
178
181
183 void regProbePoints() override;
184
185 void
186 demapPage(Addr vaddr, uint64_t asn)
187 {
188 mmu->demapPage(vaddr, asn);
189 }
190
194 void tick();
195
197 void init() override;
198
199 void startup() override;
200
202 int
204 {
205 return activeThreads.size();
206 }
207
209 void activateThread(ThreadID tid);
210
212 void deactivateThread(ThreadID tid);
213
215 void insertThread(ThreadID tid);
216
218 void removeThread(ThreadID tid);
219
221 Counter totalInsts() const override;
222
224 Counter totalOps() const override;
225
227 void activateContext(ThreadID tid) override;
228
230 void suspendContext(ThreadID tid) override;
231
235 void haltContext(ThreadID tid) override;
236
239
241 bool isDraining() const { return drainState() == DrainState::Draining; }
242
243 void serializeThread(CheckpointOut &cp, ThreadID tid) const override;
244 void unserializeThread(CheckpointIn &cp, ThreadID tid) override;
245
248
250 bool isThreadExiting(ThreadID tid) const;
251
257
259 void exitThreads();
260
261 public:
264 DrainState drain() override;
265
267 void drainResume() override;
268
276 void commitDrained(ThreadID tid);
277
279 void switchOut() override;
280
282 void takeOverFrom(BaseCPU *oldCPU) override;
283
284 void verifyMemoryMode() const override;
285
288
292 {
293 return globalFTSeqNum++;
294 }
295
297 void trap(const Fault &fault, ThreadID tid, const StaticInstPtr &inst);
298
301
303 void processInterrupts(const Fault &interrupt);
304
306 void halt() { panic("Halt not implemented!\n"); }
307
309
312
317
320
324 void setMiscReg(int misc_reg, RegVal val, ThreadID tid);
325
326 RegVal getReg(PhysRegIdPtr phys_reg, ThreadID tid);
327 void getReg(PhysRegIdPtr phys_reg, void *val, ThreadID tid);
328 void *getWritableReg(PhysRegIdPtr phys_reg, ThreadID tid);
329
330 void setReg(PhysRegIdPtr phys_reg, RegVal val, ThreadID tid);
331 void setReg(PhysRegIdPtr phys_reg, const void *val, ThreadID tid);
332
338
339 RegVal getArchReg(const RegId &reg, ThreadID tid);
340 void getArchReg(const RegId &reg, void *val, ThreadID tid);
341 void *getWritableArchReg(const RegId &reg, ThreadID tid);
342
343 void setArchReg(const RegId &reg, RegVal val, ThreadID tid);
344 void setArchReg(const RegId &reg, const void *val, ThreadID tid);
345
347 void pcState(const PCStateBase &new_pc_state, ThreadID tid);
348
350 const PCStateBase &pcState(ThreadID tid);
351
356 void squashFromTC(ThreadID tid);
357
361 ListIt addInst(const DynInstPtr &inst);
362
364 void instDone(ThreadID tid, const DynInstPtr &inst);
365
369 void removeFrontInst(const DynInstPtr &inst);
370
374
376 void removeInstsUntil(const InstSeqNum &seq_num, ThreadID tid);
377
379 void squashInstIt(const ListIt &instIt, ThreadID tid);
380
382 void cleanUpRemovedInsts();
383
385 void dumpInsts();
386
387 public:
388#ifndef NDEBUG
391#endif
392
395
399 std::queue<ListIt> removeList;
400
401#ifdef GEM5_DEBUG
405 std::set<InstSeqNum> snList;
406#endif
407
412
413 protected:
416
419
422
425
428
431
434
437
440
443
446
449
452
458 std::unordered_map<ThreadID, bool> exitingThreads;
459
462
464
465 public:
480
483
486
489
492
495
496 private:
502
503 public:
505 void activityThisCycle() { activityRec.activity(); }
506
508 void
510 {
511 activityRec.activateStage(idx);
512 }
513
515 void
517 {
518 activityRec.deactivateStage(idx);
519 }
520
522 void wakeCPU();
523
524 virtual void wakeup(ThreadID tid) override;
525
528
535 bool inUserMode(ThreadID tid);
536
537 public:
541 {
542 return thread[tid]->getTC();
543 }
544
547
550
556
559
562
565
568
571
573 std::map<ThreadID, unsigned> threadMap;
574
577
579 Fault
580 pushRequest(const DynInstPtr& inst, bool isLoad, uint8_t *data,
581 unsigned int size, Addr addr, Request::Flags flags,
582 uint64_t *res, AtomicOpFunctorPtr amo_op = nullptr,
583 const std::vector<bool>& byte_enable=std::vector<bool>())
584
585 {
586 return iew.ldstQueue.pushRequest(inst, isLoad, data, size, addr,
587 flags, res, std::move(amo_op), byte_enable);
588 }
589
591 Port &
592 getInstPort() override
593 {
594 return fetch.getInstPort();
595 }
596
598 Port &
599 getDataPort() override
600 {
601 return iew.ldstQueue.getDataPort();
602 }
603
616
617 public:
618 // hardware transactional memory
619 void htmSendAbortSignal(ThreadID tid, uint64_t htm_uid,
620 HtmFailureFaultCause cause) override;
621};
622
623} // namespace o3
624} // namespace gem5
625
626#endif // __CPU_O3_CPU_HH__
const char data[]
ActivityRecorder helper class that informs the CPU if it can switch over to being idle or not.
Definition activity.hh:54
BaseCPU(const Params &params, bool is_checker=false)
Definition base.cc:129
Templated Checker class.
Definition cpu.hh:448
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...
Cycles is a wrapper class for representing cycle counts, i.e.
Definition types.hh:79
Ports are used to interface objects to each other.
Definition port.hh:62
ProbePointArg generates a point for the class of Arg.
Definition probe.hh:273
Register ID: describe an architectural register with its class and index.
Definition reg_class.hh:94
gem5::Flags< FlagsType > Flags
Definition request.hh:102
ThreadContext is the external interface to all thread state for anything outside of the CPU.
std::vector< BaseISA * > isa
Definition cpu.hh:463
void instDone(ThreadID tid, const DynInstPtr &inst)
Function to tell the CPU that an instruction has completed.
Definition cpu.cc:1156
IEW iew
The issue/execute/writeback stages.
Definition cpu.hh:430
gem5::Checker< DynInstPtr > * checker
Pointer to the checker, which can dynamically verify instruction results at run time.
Definition cpu.hh:555
void dumpInsts()
Debug function to print all instructions on the list.
Definition cpu.cc:1309
void drainSanityCheck() const
Perform sanity checks after a drain.
Definition cpu.cc:806
void htmSendAbortSignal(ThreadID tid, uint64_t htm_uid, HtmFailureFaultCause cause) override
This function is used to instruct the memory subsystem that a transaction should be aborted and the s...
Definition cpu.cc:1472
std::list< DynInstPtr > instList
List of all the instructions in flight.
Definition cpu.hh:394
RegVal getReg(PhysRegIdPtr phys_reg, ThreadID tid)
Definition cpu.cc:969
Fault pushRequest(const DynInstPtr &inst, bool isLoad, uint8_t *data, unsigned int size, Addr addr, Request::Flags flags, uint64_t *res, AtomicOpFunctorPtr amo_op=nullptr, const std::vector< bool > &byte_enable=std::vector< bool >())
CPU pushRequest function, forwards request to LSQ.
Definition cpu.hh:580
ListIt addInst(const DynInstPtr &inst)
Function to add instruction onto the head of the list of the instructions.
Definition cpu.cc:1148
void setArchReg(const RegId &reg, RegVal val, ThreadID tid)
Definition cpu.cc:1113
ROB rob
The re-order buffer.
Definition cpu.hh:448
InstSeqNum globalSeqNum
The global sequence number counter.
Definition cpu.hh:546
void haltContext(ThreadID tid) override
Remove Thread from Active Threads List && Remove Thread Context from CPU.
Definition cpu.cc:582
TimeBuffer< DecodeStruct > decodeQueue
The decode stage's instruction queue.
Definition cpu.hh:488
EventFunctionWrapper tickEvent
The tick event used for scheduling CPU ticks.
Definition cpu.hh:125
void serializeThread(CheckpointOut &cp, ThreadID tid) const override
Serialize a single thread.
Definition cpu.cc:717
void startup() override
startup() is the final initialization call before simulation.
Definition cpu.cc:446
void drainResume() override
Resumes execution after a drain.
Definition cpu.cc:868
Rename rename
The dispatch stage.
Definition cpu.hh:427
void regProbePoints() override
Register probe points.
Definition cpu.cc:326
int numActiveThreads()
Returns the Number of Active Threads in the CPU.
Definition cpu.hh:203
UnifiedRenameMap::PerThreadUnifiedRenameMap PerThreadUnifiedRenameMap
Definition cpu.hh:116
void deactivateThread(ThreadID tid)
Remove Thread from Active Threads List.
Definition cpu.cc:475
Counter totalInsts() const override
Count the Total Instructions Committed in the CPU.
Definition cpu.cc:500
void trap(const Fault &fault, ThreadID tid, const StaticInstPtr &inst)
Traps to handle given fault.
Definition cpu.cc:710
CPU(const BaseO3CPUParams &params)
Constructs a CPU with the given parameters.
Definition cpu.cc:73
BAC bac
The branch and PC address calculation stage.
Definition cpu.hh:415
ProbePointArg< PacketPtr > * ppInstAccessComplete
Definition cpu.hh:179
void exitThreads()
Terminate all threads that are ready to exit.
Definition cpu.cc:1449
ThreadID getFreeTid()
Gets a free thread id.
Definition cpu.cc:1369
std::vector< ThreadState * > thread
Pointers to all of the threads in the CPU.
Definition cpu.hh:561
void tick()
Ticks CPU, calling tick() on each stage, and checking the overall activity to see if the CPU should d...
Definition cpu.cc:368
void halt()
Halts the CPU.
Definition cpu.hh:306
void removeThread(ThreadID tid)
Remove all of a thread's context from CPU.
Definition cpu.cc:642
void commitDrained(ThreadID tid)
Commit has reached a safe point to drain a thread.
Definition cpu.cc:861
void unscheduleTickEvent()
Unschedule tick event, regardless of its current state.
Definition cpu.hh:142
FTSeqNum globalFTSeqNum
The global FT sequence number counter.
Definition cpu.hh:549
gem5::o3::CPU::CPUStats cpuStats
UnifiedFreeList freeList
The free list.
Definition cpu.hh:439
Status _status
Overall CPU status.
Definition cpu.hh:120
std::list< DynInstPtr >::iterator ListIt
Definition cpu.hh:99
void activateContext(ThreadID tid) override
Add Thread to Active Threads List.
Definition cpu.cc:524
virtual void wakeup(ThreadID tid) override
Definition cpu.cc:1357
bool removeInstsThisCycle
Records if instructions need to be removed this cycle due to being retired or squashed.
Definition cpu.hh:411
void setMiscReg(int misc_reg, RegVal val, ThreadID tid)
Sets a misc.
Definition cpu.cc:962
void activityThisCycle()
Records that there was time buffer activity this cycle.
Definition cpu.hh:505
std::vector< ThreadID > tids
Available thread ids in the cpu.
Definition cpu.hh:576
Port & getInstPort() override
Used by the fetch unit to get a hold of the instruction port.
Definition cpu.hh:592
ProbePointArg< std::pair< DynInstPtr, PacketPtr > > * ppDataAccessComplete
Definition cpu.hh:180
PerThreadUnifiedRenameMap commitRenameMap
The commit rename map.
Definition cpu.hh:445
void setMiscRegNoEffect(int misc_reg, RegVal val, ThreadID tid)
Sets a miscellaneous register.
Definition cpu.cc:956
void removeInstsUntil(const InstSeqNum &seq_num, ThreadID tid)
Remove all instructions younger than the given sequence number.
Definition cpu.cc:1237
bool isDraining() const
Is the CPU draining?
Definition cpu.hh:241
std::queue< ListIt > removeList
List of all the instructions that will be removed at the end of this cycle.
Definition cpu.hh:399
TimeBuffer< FetchStruct > fetchQueue
The fetch stage's instruction queue.
Definition cpu.hh:485
void cleanUpRemovedInsts()
Cleans up all instructions on the remove list.
Definition cpu.cc:1285
@ SwitchedOut
Definition cpu.hh:110
Commit commit
The commit stage.
Definition cpu.hh:433
void suspendContext(ThreadID tid) override
Remove Thread from Active Threads List.
Definition cpu.cc:562
void demapPage(Addr vaddr, uint64_t asn)
Definition cpu.hh:186
void unserializeThread(CheckpointIn &cp, ThreadID tid) override
Unserialize one thread.
Definition cpu.cc:723
void removeInstsNotInROB(ThreadID tid)
Remove all instructions that are not currently in the ROB.
Definition cpu.cc:1193
void takeOverFrom(BaseCPU *oldCPU) override
Takes over from another CPU.
Definition cpu.cc:912
void switchOut() override
Switches out this CPU.
Definition cpu.cc:898
PhysRegFile regFile
The register file.
Definition cpu.hh:436
Cycles lastRunningCycle
The cycle that the CPU was last running, used for statistics.
Definition cpu.hh:567
bool tryDrain()
Check if the pipeline has drained and signal drain done.
Definition cpu.cc:791
friend class ThreadContext
Definition cpu.hh:101
ActivityRecorder activityRec
The activity recorder; used to tell if the CPU has any activity remaining or if it can go to idle and...
Definition cpu.hh:501
void processInterrupts(const Fault &interrupt)
Processes any an interrupt fault.
Definition cpu.cc:694
void squashFromTC(ThreadID tid)
Initiates a squash of all in-flight instructions for a given thread.
Definition cpu.cc:1141
TimeBuffer< TimeStruct > timeBuffer
The main time buffer to do backwards communication.
Definition cpu.hh:482
Tick lastActivatedCycle
The cycle that the CPU was last activated by a new thread.
Definition cpu.hh:570
StageIdx
Enum to give each stage a specific index, so when calling activateStage() or deactivateStage(),...
Definition cpu.hh:471
int instcount
Count of total number of dynamic instructions in flight.
Definition cpu.hh:390
void deactivateStage(const StageIdx idx)
Changes a stage's status to inactive within the activity recorder.
Definition cpu.hh:516
void squashInstIt(const ListIt &instIt, ThreadID tid)
Removes the instruction pointed to by the iterator.
Definition cpu.cc:1265
BaseMMU * mmu
Definition cpu.hh:113
System * system
Pointer to the system.
Definition cpu.hh:558
Decode decode
The decode stage.
Definition cpu.hh:424
void verifyMemoryMode() const override
Verify that the system is in a memory mode supported by the CPU.
Definition cpu.cc:934
RegVal getArchReg(const RegId &reg, ThreadID tid)
Architectural register accessors.
Definition cpu.cc:1089
Port & getDataPort() override
Get the dcache port (used to find block size for translations).
Definition cpu.hh:599
TimeBuffer< IEWStruct > iewQueue
The IEW stage's instruction queue.
Definition cpu.hh:494
EventFunctionWrapper threadExitEvent
The exit event used for terminating all ready-to-exit threads.
Definition cpu.hh:128
DrainState drain() override
Starts draining the CPU's pipeline of all instructions in order to stop all memory accesses.
Definition cpu.cc:729
std::list< ThreadID > activeThreads
Active Threads List.
Definition cpu.hh:451
PerThreadUnifiedRenameMap renameMap
The rename map.
Definition cpu.hh:442
Fault getInterrupts()
Returns the Fault for any valid interrupt.
Definition cpu.cc:687
InstSeqNum getAndIncrementInstSeq()
Get the current instruction sequence number, and increment it.
Definition cpu.hh:287
void scheduleTickEvent(Cycles delay)
Schedule tick event, regardless of its current state.
Definition cpu.hh:132
RegVal readMiscRegNoEffect(int misc_reg, ThreadID tid) const
Register accessors.
Definition cpu.cc:943
bool isCpuDrained() const
Check if a system is in a drained state.
Definition cpu.cc:818
Fetch fetch
The fetch stage.
Definition cpu.hh:421
void addThreadToExitingList(ThreadID tid)
Insert tid to the list of threads trying to exit.
Definition cpu.cc:1404
void pcState(const PCStateBase &new_pc_state, ThreadID tid)
Sets the commit PC state of a specific thread.
Definition cpu.cc:1135
void scheduleThreadExitEvent(ThreadID tid)
If a thread is trying to exit and its corresponding trap event has been completed,...
Definition cpu.cc:1429
InstSeqNum getAndIncrementFTSeq()
Get the current fetch target sequence number, and increment it.
Definition cpu.hh:291
void updateThreadPriority()
Update The Order In Which We Process Threads.
Definition cpu.cc:1388
void setReg(PhysRegIdPtr phys_reg, RegVal val, ThreadID tid)
Definition cpu.cc:1037
bool isThreadExiting(ThreadID tid) const
Is the thread trying to exit?
Definition cpu.cc:1423
LSQ::LSQRequest LSQRequest
Definition cpu.hh:114
void removeFrontInst(const DynInstPtr &inst)
Remove an instruction from the front end of the list.
Definition cpu.cc:1180
std::map< ThreadID, unsigned > threadMap
Mapping for system thread id to cpu id.
Definition cpu.hh:573
void * getWritableArchReg(const RegId &reg, ThreadID tid)
Definition cpu.cc:1105
RegVal readMiscReg(int misc_reg, ThreadID tid)
Reads a misc.
Definition cpu.cc:949
void init() override
Initialize the CPU.
Definition cpu.cc:428
void activateThread(ThreadID tid)
Add Thread to Active Threads List.
Definition cpu.cc:459
gem5::ThreadContext * tcBase(ThreadID tid)
Returns a pointer to a thread context.
Definition cpu.hh:540
FTQ ftq
The Fetch taget queue.
Definition cpu.hh:418
void activateStage(const StageIdx idx)
Changes a stage's status to active within the activity recorder.
Definition cpu.hh:509
std::list< int > cpuWaitList
Threads Scheduled to Enter CPU.
Definition cpu.hh:564
Scoreboard scoreboard
Integer Register Scoreboard.
Definition cpu.hh:461
void * getWritableReg(PhysRegIdPtr phys_reg, ThreadID tid)
Definition cpu.cc:1021
std::unordered_map< ThreadID, bool > exitingThreads
This is a list of threads that are trying to exit.
Definition cpu.hh:458
Counter totalOps() const override
Count the Total Ops (including micro ops) committed in the CPU.
Definition cpu.cc:512
void wakeCPU()
Wakes the CPU, rescheduling the CPU if it's not already active.
Definition cpu.cc:1336
bool inUserMode(ThreadID tid)
Get whether a thread is in user mode.
Definition cpu.cc:1382
void insertThread(ThreadID tid)
Setup CPU to insert a thread's context.
Definition cpu.cc:604
TimeBuffer< RenameStruct > renameQueue
The rename stage's instruction queue.
Definition cpu.hh:491
Commit handles single threaded and SMT commit.
Definition commit.hh:92
Decode class handles both single threaded and SMT decode.
Definition decode.hh:71
FTQ class.
Definition ftq.hh:227
Fetch class handles both single threaded and SMT fetch.
Definition fetch.hh:83
IEW handles both single threaded and SMT IEW (issue/execute/writeback).
Definition iew.hh:88
Memory operation metadata.
Definition lsq.hh:220
Simple physical register file class.
Definition regfile.hh:66
ROB class.
Definition rob.hh:72
Rename handles both single threaded and SMT rename.
Definition rename.hh:79
Implements a simple scoreboard to track which registers are ready.
Definition scoreboard.hh:55
Derived ThreadContext class for use with the O3CPU.
FreeList class that simply holds the list of free integer and floating point registers.
Definition free_list.hh:125
std::array< UnifiedRenameMap, MaxThreads > PerThreadUnifiedRenameMap
Statistics container.
Definition group.hh:93
This is a simple scalar statistic, like a counter.
STL list class.
Definition stl.hh:51
STL vector class.
Definition stl.hh:37
std::unique_ptr< AtomicOpFunctor > AtomicOpFunctorPtr
Definition amo.hh:269
DrainState drainState() const
Return the current drain state of an object.
Definition drain.hh:329
DrainState
Object drain/handover states.
Definition drain.hh:76
@ Draining
Draining buffers pending serialization/handover.
Definition drain.hh:78
void schedule(Event &event, Tick when)
Definition eventq.hh:1012
void reschedule(Event &event, Tick when, bool always=false)
Definition eventq.hh:1030
#define panic(...)
This implements a cprintf based panic() function.
Definition logging.hh:220
const Params & params() const
Bitfield< 5, 3 > reg
Definition types.hh:92
Bitfield< 63 > val
Definition misc.hh:804
Bitfield< 3 > addr
Definition types.hh:84
InstSeqNum FTSeqNum
Definition ftq.hh:67
RefCountingPtr< DynInst > DynInstPtr
double Counter
All counters are of 64-bit values.
Definition types.hh:46
Copyright (c) 2024 Arm Limited All rights reserved.
Definition binary32.hh:36
std::shared_ptr< FaultBase > Fault
Definition types.hh:249
int16_t ThreadID
Thread index/ID type.
Definition types.hh:235
uint64_t RegVal
Definition types.hh:173
std::ostream CheckpointOut
Definition serialize.hh:66
uint64_t Addr
Address type This will probably be moved somewhere else in the near future.
Definition types.hh:147
PhysRegId * PhysRegIdPtr
Definition reg_class.hh:511
uint64_t Tick
Tick count type.
Definition types.hh:58
RefCountingPtr< StaticInst > StaticInstPtr
HtmFailureFaultCause
Definition htm.hh:48
uint64_t InstSeqNum
Definition inst_seq.hh:40
Declaration of Statistics objects.
statistics::Scalar timesIdled
Stat for total number of times the CPU is descheduled.
Definition cpu.hh:609
statistics::Scalar quiesceCycles
Stat for total number of cycles the CPU spends descheduled due to a quiesce operation or waiting for ...
Definition cpu.hh:614
statistics::Scalar idleCycles
Stat for total number of cycles the CPU spends descheduled.
Definition cpu.hh:611
CPUStats(CPU *cpu)
Definition cpu.cc:344

Generated on Mon Oct 27 2025 04:13:00 for gem5 by doxygen 1.14.0