gem5  v20.1.0.0
sve_mem.hh
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2017 ARM Limited
3  * All rights reserved
4  *
5  * The license below extends only to copyright in the software and shall
6  * not be construed as granting a license to any other intellectual
7  * property including but not limited to intellectual property relating
8  * to a hardware implementation of the functionality of the software
9  * licensed hereunder. You may use the software subject to the license
10  * terms below provided that you ensure that this notice is replicated
11  * unmodified and in its entirety in all distributions of the software,
12  * modified or unmodified, in source code or in binary form.
13  *
14  * Redistribution and use in source and binary forms, with or without
15  * modification, are permitted provided that the following conditions are
16  * met: redistributions of source code must retain the above copyright
17  * notice, this list of conditions and the following disclaimer;
18  * redistributions in binary form must reproduce the above copyright
19  * notice, this list of conditions and the following disclaimer in the
20  * documentation and/or other materials provided with the distribution;
21  * neither the name of the copyright holders nor the names of its
22  * contributors may be used to endorse or promote products derived from
23  * this software without specific prior written permission.
24  *
25  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
26  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
27  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
28  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
29  * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
30  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
31  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
32  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
33  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
34  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
35  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
36  */
37 
38 #ifndef __ARCH_ARM_SVE_MEM_HH__
39 #define __ARCH_ARM_SVE_MEM_HH__
40 
42 #include "arch/arm/tlb.hh"
43 
44 namespace ArmISA
45 {
46 
48 {
49  protected:
52  uint64_t imm;
53 
55  bool baseIsSP;
56 
57  unsigned memAccessFlags;
58 
59  SveMemVecFillSpill(const char *mnem, ExtMachInst _machInst,
60  OpClass __opClass, IntRegIndex _dest,
61  IntRegIndex _base, uint64_t _imm)
62  : ArmStaticInst(mnem, _machInst, __opClass),
63  dest(_dest), base(_base), imm(_imm),
64  memAccessFlags(ArmISA::TLB::AllowUnaligned)
65  {
66  baseIsSP = isSP(_base);
67  }
68 
69  std::string generateDisassembly(
70  Addr pc, const Loader::SymbolTable *symtab) const override;
71 };
72 
74 {
75  protected:
78  uint64_t imm;
79 
81  bool baseIsSP;
82 
83  unsigned memAccessFlags;
84 
85  SveMemPredFillSpill(const char *mnem, ExtMachInst _machInst,
86  OpClass __opClass, IntRegIndex _dest,
87  IntRegIndex _base, uint64_t _imm)
88  : ArmStaticInst(mnem, _machInst, __opClass),
89  dest(_dest), base(_base), imm(_imm),
90  memAccessFlags(ArmISA::TLB::AllowUnaligned)
91  {
92  baseIsSP = isSP(_base);
93  }
94 
95  std::string generateDisassembly(
96  Addr pc, const Loader::SymbolTable *symtab) const override;
97 };
98 
100 {
101  protected:
106 
108  bool baseIsSP;
109 
110  unsigned memAccessFlags;
111 
112  SveContigMemSS(const char *mnem, ExtMachInst _machInst, OpClass __opClass,
113  IntRegIndex _dest, IntRegIndex _gp, IntRegIndex _base,
114  IntRegIndex _offset)
115  : ArmStaticInst(mnem, _machInst, __opClass),
116  dest(_dest), gp(_gp), base(_base), offset(_offset),
117  memAccessFlags(ArmISA::TLB::AllowUnaligned)
118  {
119  baseIsSP = isSP(_base);
120  }
121 
122  std::string generateDisassembly(
123  Addr pc, const Loader::SymbolTable *symtab) const override;
124 };
125 
127 {
128  protected:
132  uint64_t imm;
133 
135  bool baseIsSP;
136 
137  unsigned memAccessFlags;
138 
139  SveContigMemSI(const char *mnem, ExtMachInst _machInst, OpClass __opClass,
140  IntRegIndex _dest, IntRegIndex _gp, IntRegIndex _base,
141  uint64_t _imm)
142  : ArmStaticInst(mnem, _machInst, __opClass),
143  dest(_dest), gp(_gp), base(_base), imm(_imm),
144  memAccessFlags(ArmISA::TLB::AllowUnaligned)
145  {
146  baseIsSP = isSP(_base);
147  }
148 
149  std::string generateDisassembly(
150  Addr pc, const Loader::SymbolTable *symtab) const override;
151 };
152 
153 } // namespace ArmISA
154 
155 #endif // __ARCH_ARM_SVE_MEM_HH__
ArmISA::SveContigMemSS::memAccessFlags
unsigned memAccessFlags
Definition: sve_mem.hh:110
ArmISA::SveMemPredFillSpill::SveMemPredFillSpill
SveMemPredFillSpill(const char *mnem, ExtMachInst _machInst, OpClass __opClass, IntRegIndex _dest, IntRegIndex _base, uint64_t _imm)
Definition: sve_mem.hh:85
ArmISA::SveContigMemSI::imm
uint64_t imm
Definition: sve_mem.hh:132
ArmISA::isSP
static bool isSP(IntRegIndex reg)
Definition: intregs.hh:515
ArmISA::SveContigMemSS::base
IntRegIndex base
Definition: sve_mem.hh:104
ArmISA::SveMemVecFillSpill::SveMemVecFillSpill
SveMemVecFillSpill(const char *mnem, ExtMachInst _machInst, OpClass __opClass, IntRegIndex _dest, IntRegIndex _base, uint64_t _imm)
Definition: sve_mem.hh:59
ArmISA::SveMemPredFillSpill::base
IntRegIndex base
Definition: sve_mem.hh:77
Loader::SymbolTable
Definition: symtab.hh:59
ArmISA::IntRegIndex
IntRegIndex
Definition: intregs.hh:51
ArmISA::SveContigMemSI::baseIsSP
bool baseIsSP
True if the base register is SP (used for SP alignment checking).
Definition: sve_mem.hh:135
ArmISA::SveContigMemSS::offset
IntRegIndex offset
Definition: sve_mem.hh:105
tlb.hh
ArmISA::SveContigMemSI::SveContigMemSI
SveContigMemSI(const char *mnem, ExtMachInst _machInst, OpClass __opClass, IntRegIndex _dest, IntRegIndex _gp, IntRegIndex _base, uint64_t _imm)
Definition: sve_mem.hh:139
ArmISA::SveContigMemSI::memAccessFlags
unsigned memAccessFlags
Definition: sve_mem.hh:137
ArmISA
Definition: ccregs.hh:41
ArmISA::SveContigMemSS::dest
IntRegIndex dest
Definition: sve_mem.hh:102
ArmISA::ArmStaticInst
Definition: static_inst.hh:60
ArmISA::SveMemPredFillSpill
Definition: sve_mem.hh:73
ArmISA::SveContigMemSS
Definition: sve_mem.hh:99
MipsISA::pc
Bitfield< 4 > pc
Definition: pra_constants.hh:240
ArmISA::SveMemVecFillSpill::imm
uint64_t imm
Definition: sve_mem.hh:52
ArmISA::SveMemVecFillSpill::generateDisassembly
std::string generateDisassembly(Addr pc, const Loader::SymbolTable *symtab) const override
Internal function to generate disassembly string.
Definition: sve_mem.cc:44
ArmISA::SveContigMemSI::base
IntRegIndex base
Definition: sve_mem.hh:131
StaticInst::ExtMachInst
TheISA::ExtMachInst ExtMachInst
Binary extended machine instruction type.
Definition: static_inst.hh:89
ArmISA::SveMemPredFillSpill::dest
IntRegIndex dest
Definition: sve_mem.hh:76
ArmISA::SveContigMemSS::gp
IntRegIndex gp
Definition: sve_mem.hh:103
ArmISA::SveMemPredFillSpill::memAccessFlags
unsigned memAccessFlags
Definition: sve_mem.hh:83
ArmISA::SveMemVecFillSpill::base
IntRegIndex base
Definition: sve_mem.hh:51
ArmISA::SveContigMemSI::generateDisassembly
std::string generateDisassembly(Addr pc, const Loader::SymbolTable *symtab) const override
Internal function to generate disassembly string.
Definition: sve_mem.cc:96
ArmISA::SveMemPredFillSpill::baseIsSP
bool baseIsSP
True if the base register is SP (used for SP alignment checking).
Definition: sve_mem.hh:81
ArmISA::SveMemVecFillSpill::baseIsSP
bool baseIsSP
True if the base register is SP (used for SP alignment checking).
Definition: sve_mem.hh:55
Addr
uint64_t Addr
Address type This will probably be moved somewhere else in the near future.
Definition: types.hh:142
ArmISA::SveContigMemSS::SveContigMemSS
SveContigMemSS(const char *mnem, ExtMachInst _machInst, OpClass __opClass, IntRegIndex _dest, IntRegIndex _gp, IntRegIndex _base, IntRegIndex _offset)
Definition: sve_mem.hh:112
ArmISA::TLB
Definition: tlb.hh:100
ArmISA::SveContigMemSI::gp
IntRegIndex gp
Definition: sve_mem.hh:130
ArmISA::SveContigMemSI::dest
IntRegIndex dest
Definition: sve_mem.hh:129
ArmISA::SveContigMemSS::baseIsSP
bool baseIsSP
True if the base register is SP (used for SP alignment checking).
Definition: sve_mem.hh:108
ArmISA::SveContigMemSI
Definition: sve_mem.hh:126
ArmISA::SveMemVecFillSpill::memAccessFlags
unsigned memAccessFlags
Definition: sve_mem.hh:57
static_inst.hh
ArmISA::SveContigMemSS::generateDisassembly
std::string generateDisassembly(Addr pc, const Loader::SymbolTable *symtab) const override
Internal function to generate disassembly string.
Definition: sve_mem.cc:76
ArmISA::SveMemPredFillSpill::imm
uint64_t imm
Definition: sve_mem.hh:78
ArmISA::SveMemVecFillSpill
Definition: sve_mem.hh:47
ArmISA::SveMemPredFillSpill::generateDisassembly
std::string generateDisassembly(Addr pc, const Loader::SymbolTable *symtab) const override
Internal function to generate disassembly string.
Definition: sve_mem.cc:60
ArmISA::SveMemVecFillSpill::dest
IntRegIndex dest
Definition: sve_mem.hh:50

Generated on Wed Sep 30 2020 14:02:00 for gem5 by doxygen 1.8.17