| 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 2203 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2214 Ostream &Str = Func->getContext()->getStrEmit(); | 2214 Ostream &Str = Func->getContext()->getStrEmit(); |
| 2215 assert(getSrcSize() == 1); | 2215 assert(getSrcSize() == 1); |
| 2216 Str << "\t" | 2216 Str << "\t" |
| 2217 "vabs" << getPredicate() << getVecWidthString(getSrc(0)->getType()) | 2217 "vabs" << getPredicate() << getVecWidthString(getSrc(0)->getType()) |
| 2218 << "\t"; | 2218 << "\t"; |
| 2219 getDest()->emit(Func); | 2219 getDest()->emit(Func); |
| 2220 Str << ", "; | 2220 Str << ", "; |
| 2221 getSrc(0)->emit(Func); | 2221 getSrc(0)->emit(Func); |
| 2222 } | 2222 } |
| 2223 | 2223 |
| 2224 void InstARM32Vabs::emitIAS(const Cfg *Func) const { |
| 2225 assert(getSrcSize() == 1); |
| 2226 auto *Asm = Func->getAssembler<ARM32::AssemblerARM32>(); |
| 2227 const Variable *Dest = getDest(); |
| 2228 switch (Dest->getType()) { |
| 2229 default: |
| 2230 // TODO(kschimpf): Implement vector fabs. |
| 2231 Asm->setNeedsTextFixup(); |
| 2232 break; |
| 2233 case IceType_f32: |
| 2234 Asm->vabss(Dest, getSrc(0), getPredicate()); |
| 2235 break; |
| 2236 case IceType_f64: |
| 2237 Asm->vabsd(Dest, getSrc(0), getPredicate()); |
| 2238 break; |
| 2239 } |
| 2240 if (Asm->needsTextFixup()) |
| 2241 emitUsingTextFixup(Func); |
| 2242 } |
| 2243 |
| 2224 void InstARM32Vabs::dump(const Cfg *Func) const { | 2244 void InstARM32Vabs::dump(const Cfg *Func) const { |
| 2225 if (!BuildDefs::dump()) | 2245 if (!BuildDefs::dump()) |
| 2226 return; | 2246 return; |
| 2227 Ostream &Str = Func->getContext()->getStrDump(); | 2247 Ostream &Str = Func->getContext()->getStrDump(); |
| 2228 dumpDest(Func); | 2248 dumpDest(Func); |
| 2229 Str << " = vabs" << getPredicate() << getVecWidthString(getSrc(0)->getType()); | 2249 Str << " = vabs" << getPredicate() << getVecWidthString(getSrc(0)->getType()); |
| 2230 } | 2250 } |
| 2231 | 2251 |
| 2232 void InstARM32Dmb::emit(const Cfg *Func) const { | 2252 void InstARM32Dmb::emit(const Cfg *Func) const { |
| 2233 if (!BuildDefs::dump()) | 2253 if (!BuildDefs::dump()) |
| (...skipping 265 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2499 | 2519 |
| 2500 template class InstARM32FourAddrGPR<InstARM32::Mla>; | 2520 template class InstARM32FourAddrGPR<InstARM32::Mla>; |
| 2501 template class InstARM32FourAddrGPR<InstARM32::Mls>; | 2521 template class InstARM32FourAddrGPR<InstARM32::Mls>; |
| 2502 | 2522 |
| 2503 template class InstARM32CmpLike<InstARM32::Cmn>; | 2523 template class InstARM32CmpLike<InstARM32::Cmn>; |
| 2504 template class InstARM32CmpLike<InstARM32::Cmp>; | 2524 template class InstARM32CmpLike<InstARM32::Cmp>; |
| 2505 template class InstARM32CmpLike<InstARM32::Tst>; | 2525 template class InstARM32CmpLike<InstARM32::Tst>; |
| 2506 | 2526 |
| 2507 } // end of namespace ARM32 | 2527 } // end of namespace ARM32 |
| 2508 } // end of namespace Ice | 2528 } // end of namespace Ice |
| OLD | NEW |