OLD | NEW |
1 //===- subzero/src/IceInstARM32.cpp - ARM32 instruction implementation ----===// | 1 //===- subzero/src/IceInstARM32.cpp - ARM32 instruction implementation ----===// |
2 // | 2 // |
3 // The Subzero Code Generator | 3 // The Subzero Code Generator |
4 // | 4 // |
5 // This file is distributed under the University of Illinois Open Source | 5 // This file is distributed under the University of Illinois Open Source |
6 // License. See LICENSE.TXT for details. | 6 // License. See LICENSE.TXT for details. |
7 // | 7 // |
8 //===----------------------------------------------------------------------===// | 8 //===----------------------------------------------------------------------===// |
9 /// | 9 /// |
10 /// \file | 10 /// \file |
(...skipping 1173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1184 template <InstARM32::InstKindARM32 K> | 1184 template <InstARM32::InstKindARM32 K> |
1185 void InstARM32TwoAddrGPR<K>::emitIAS(const Cfg *Func) const { | 1185 void InstARM32TwoAddrGPR<K>::emitIAS(const Cfg *Func) const { |
1186 emitUsingTextFixup(Func); | 1186 emitUsingTextFixup(Func); |
1187 } | 1187 } |
1188 | 1188 |
1189 template <InstARM32::InstKindARM32 K, bool Nws> | 1189 template <InstARM32::InstKindARM32 K, bool Nws> |
1190 void InstARM32UnaryopGPR<K, Nws>::emitIAS(const Cfg *Func) const { | 1190 void InstARM32UnaryopGPR<K, Nws>::emitIAS(const Cfg *Func) const { |
1191 emitUsingTextFixup(Func); | 1191 emitUsingTextFixup(Func); |
1192 } | 1192 } |
1193 | 1193 |
| 1194 template <> void InstARM32Rev::emitIAS(const Cfg *Func) const { |
| 1195 assert(getSrcSize() == 1); |
| 1196 auto *Asm = Func->getAssembler<ARM32::AssemblerARM32>(); |
| 1197 Asm->rev(getDest(), getSrc(0), getPredicate()); |
| 1198 if (Asm->needsTextFixup()) |
| 1199 emitUsingTextFixup(Func); |
| 1200 } |
| 1201 |
1194 template <> void InstARM32Movw::emit(const Cfg *Func) const { | 1202 template <> void InstARM32Movw::emit(const Cfg *Func) const { |
1195 if (!BuildDefs::dump()) | 1203 if (!BuildDefs::dump()) |
1196 return; | 1204 return; |
1197 Ostream &Str = Func->getContext()->getStrEmit(); | 1205 Ostream &Str = Func->getContext()->getStrEmit(); |
1198 assert(getSrcSize() == 1); | 1206 assert(getSrcSize() == 1); |
1199 Str << "\t" << Opcode << getPredicate() << "\t"; | 1207 Str << "\t" << Opcode << getPredicate() << "\t"; |
1200 getDest()->emit(Func); | 1208 getDest()->emit(Func); |
1201 Str << ", "; | 1209 Str << ", "; |
1202 Constant *Src0 = llvm::cast<Constant>(getSrc(0)); | 1210 Constant *Src0 = llvm::cast<Constant>(getSrc(0)); |
1203 if (auto *CR = llvm::dyn_cast<ConstantRelocatable>(Src0)) { | 1211 if (auto *CR = llvm::dyn_cast<ConstantRelocatable>(Src0)) { |
(...skipping 823 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2027 template class InstARM32UnaryopFP<InstARM32::Vsqrt>; | 2035 template class InstARM32UnaryopFP<InstARM32::Vsqrt>; |
2028 | 2036 |
2029 template class InstARM32FourAddrGPR<InstARM32::Mla>; | 2037 template class InstARM32FourAddrGPR<InstARM32::Mla>; |
2030 template class InstARM32FourAddrGPR<InstARM32::Mls>; | 2038 template class InstARM32FourAddrGPR<InstARM32::Mls>; |
2031 | 2039 |
2032 template class InstARM32CmpLike<InstARM32::Cmn>; | 2040 template class InstARM32CmpLike<InstARM32::Cmn>; |
2033 template class InstARM32CmpLike<InstARM32::Cmp>; | 2041 template class InstARM32CmpLike<InstARM32::Cmp>; |
2034 template class InstARM32CmpLike<InstARM32::Tst>; | 2042 template class InstARM32CmpLike<InstARM32::Tst>; |
2035 | 2043 |
2036 } // end of namespace Ice | 2044 } // end of namespace Ice |
OLD | NEW |