gem5  v21.0.0.0
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
registers.hh
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2009 The University of Edinburgh
3  * All rights reserved.
4  *
5  * Redistribution and use in source and binary forms, with or without
6  * modification, are permitted provided that the following conditions are
7  * met: redistributions of source code must retain the above copyright
8  * notice, this list of conditions and the following disclaimer;
9  * redistributions in binary form must reproduce the above copyright
10  * notice, this list of conditions and the following disclaimer in the
11  * documentation and/or other materials provided with the distribution;
12  * neither the name of the copyright holders nor the names of its
13  * contributors may be used to endorse or promote products derived from
14  * this software without specific prior written permission.
15  *
16  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
17  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
18  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
19  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
20  * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
21  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
22  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
24  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
26  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27  */
28 
29 #ifndef __ARCH_POWER_REGISTERS_HH__
30 #define __ARCH_POWER_REGISTERS_HH__
31 
33 #include "arch/generic/vec_reg.hh"
34 #include "arch/power/miscregs.hh"
35 #include "base/types.hh"
36 
37 namespace PowerISA
38 {
39 
40 // Not applicable to Power
47 
48 // Not applicable to Power
54 
55 // Constants Related to the number of registers
56 const int NumIntArchRegs = 32;
57 
58 // CR, XER, LR, CTR, FPSCR, RSV, RSV-LEN, RSV-ADDR
59 // and zero register, which doesn't actually exist but needs a number
60 const int NumIntSpecialRegs = 9;
61 const int NumFloatArchRegs = 32;
62 
65 const int NumVecRegs = 1; // Not applicable to Power
66  // (1 to prevent warnings)
67 const int NumVecPredRegs = 1; // Not applicable to Power
68  // (1 to prevent warnings)
69 const int NumCCRegs = 0;
71 
72 // Semantically meaningful register indices
73 const int ReturnValueReg = 3;
74 const int StackPointerReg = 1;
75 
76 // There isn't one in Power, but we need to define one somewhere
77 const int ZeroReg = NumIntRegs - 1;
78 
88 };
89 
90 } // namespace PowerISA
91 
92 #endif // __ARCH_POWER_REGISTERS_HH__
PowerISA::VecPredRegSizeBits
constexpr size_t VecPredRegSizeBits
Definition: registers.hh:52
DummyVecRegSizeBytes
constexpr size_t DummyVecRegSizeBytes
Definition: vec_reg.hh:669
DummyVecPredRegSizeBits
constexpr size_t DummyVecPredRegSizeBits
Definition: vec_pred_reg.hh:398
VecPredRegContainer
Generic predicate register container.
Definition: vec_pred_reg.hh:47
PowerISA::INTREG_RSV_LEN
@ INTREG_RSV_LEN
Definition: registers.hh:86
PowerISA::MiscIntRegNums
MiscIntRegNums
Definition: registers.hh:79
DummyVecPredRegHasPackedRepr
constexpr bool DummyVecPredRegHasPackedRepr
Dummy type aliases and constants for architectures that do not implement vector predicate registers.
Definition: vec_pred_reg.hh:391
PowerISA::VecElem
::DummyVecElem VecElem
Definition: registers.hh:41
DummyVecPredReg
VecPredRegT< DummyVecElem, DummyNumVecElemPerVecReg, DummyVecPredRegHasPackedRepr, false > DummyVecPredReg
Definition: vec_pred_reg.hh:393
PowerISA::NumCCRegs
const int NumCCRegs
Definition: registers.hh:69
PowerISA::INTREG_CR
@ INTREG_CR
Definition: registers.hh:80
DummyVecRegContainer
DummyVecReg::Container DummyVecRegContainer
Definition: vec_reg.hh:668
PowerISA
Definition: decoder.cc:31
PowerISA::ReturnValueReg
const int ReturnValueReg
Definition: registers.hh:73
PowerISA::NumFloatArchRegs
const int NumFloatArchRegs
Definition: registers.hh:61
VecPredRegT
Predicate register view.
Definition: vec_pred_reg.hh:66
DummyConstVecReg
VecRegT< DummyVecElem, DummyNumVecElemPerVecReg, true > DummyConstVecReg
Definition: vec_reg.hh:667
PowerISA::INTREG_CTR
@ INTREG_CTR
Definition: registers.hh:83
PowerISA::INTREG_RSV_ADDR
@ INTREG_RSV_ADDR
Definition: registers.hh:87
DummyVecElem
uint32_t DummyVecElem
Dummy type aliases and constants for architectures that do not implement vector registers.
Definition: vec_reg.hh:664
vec_pred_reg.hh
PowerISA::ZeroReg
const int ZeroReg
Definition: registers.hh:77
DummyVecReg
VecRegT< DummyVecElem, DummyNumVecElemPerVecReg, false > DummyVecReg
Definition: vec_reg.hh:666
PowerISA::NumVecElemPerVecReg
constexpr unsigned NumVecElemPerVecReg
Definition: registers.hh:45
DummyVecPredRegContainer
DummyVecPredReg::Container DummyVecPredRegContainer
Definition: vec_pred_reg.hh:397
PowerISA::VecRegSizeBytes
constexpr size_t VecRegSizeBytes
Definition: registers.hh:46
PowerISA::INTREG_FPSCR
@ INTREG_FPSCR
Definition: registers.hh:84
vec_reg.hh
PowerISA::NumMiscRegs
const int NumMiscRegs
Definition: registers.hh:70
DummyConstVecPredReg
VecPredRegT< DummyVecElem, DummyNumVecElemPerVecReg, DummyVecPredRegHasPackedRepr, true > DummyConstVecPredReg
Definition: vec_pred_reg.hh:396
types.hh
PowerISA::NumVecRegs
const int NumVecRegs
Definition: registers.hh:65
PowerISA::VecPredRegHasPackedRepr
constexpr bool VecPredRegHasPackedRepr
Definition: registers.hh:53
PowerISA::NumVecPredRegs
const int NumVecPredRegs
Definition: registers.hh:67
PowerISA::INTREG_RSV
@ INTREG_RSV
Definition: registers.hh:85
DummyNumVecElemPerVecReg
constexpr unsigned DummyNumVecElemPerVecReg
Definition: vec_reg.hh:665
PowerISA::NumIntRegs
const int NumIntRegs
Definition: registers.hh:63
miscregs.hh
PowerISA::INTREG_LR
@ INTREG_LR
Definition: registers.hh:82
PowerISA::NUM_MISCREGS
@ NUM_MISCREGS
Definition: miscregs.hh:38
PowerISA::NumIntArchRegs
const int NumIntArchRegs
Definition: registers.hh:56
PowerISA::StackPointerReg
const int StackPointerReg
Definition: registers.hh:74
PowerISA::NumFloatRegs
const int NumFloatRegs
Definition: registers.hh:64
VecRegContainer
Vector Register Abstraction This generic class is the model in a particularization of MVC,...
Definition: vec_reg.hh:156
PowerISA::INTREG_XER
@ INTREG_XER
Definition: registers.hh:81
VecRegT
Vector Register Abstraction This generic class is a view in a particularization of MVC,...
Definition: vec_reg.hh:170
PowerISA::NumIntSpecialRegs
const int NumIntSpecialRegs
Definition: registers.hh:60

Generated on Tue Mar 23 2021 19:41:20 for gem5 by doxygen 1.8.17