Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(517)

Side by Side Diff: src/IceInstARM32.cpp

Issue 1886263004: Subzero. ARM32. Implements vector select. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Addresses comments. Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/IceInstARM32.h ('k') | src/IceTargetLoweringARM32.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 686 matching lines...) Expand 10 before | Expand all | Expand 10 after
697 case IceType_v8i1: 697 case IceType_v8i1:
698 case IceType_v16i1: 698 case IceType_v16i1:
699 case IceType_v16i8: 699 case IceType_v16i8:
700 case IceType_v8i16: 700 case IceType_v8i16:
701 case IceType_v4i32: 701 case IceType_v4i32:
702 Asm->vandq(Dest, getSrc(0), getSrc(1)); 702 Asm->vandq(Dest, getSrc(0), getSrc(1));
703 } 703 }
704 assert(!Asm->needsTextFixup()); 704 assert(!Asm->needsTextFixup());
705 } 705 }
706 706
707 template <> void InstARM32Vbsl::emitIAS(const Cfg *Func) const {
708 auto *Asm = Func->getAssembler<ARM32::AssemblerARM32>();
709 const Variable *Dest = getDest();
710 switch (Dest->getType()) {
711 default:
712 llvm::report_fatal_error("Vbsl not defined on type " +
713 typeStdString(Dest->getType()));
714 case IceType_v4i1:
715 case IceType_v8i1:
716 case IceType_v16i1:
717 case IceType_v16i8:
718 case IceType_v8i16:
719 case IceType_v4i32:
720 Asm->vbslq(Dest, getSrc(0), getSrc(1));
721 }
722 assert(!Asm->needsTextFixup());
723 }
724
707 template <> void InstARM32Vdiv::emitIAS(const Cfg *Func) const { 725 template <> void InstARM32Vdiv::emitIAS(const Cfg *Func) const {
708 auto *Asm = Func->getAssembler<ARM32::AssemblerARM32>(); 726 auto *Asm = Func->getAssembler<ARM32::AssemblerARM32>();
709 const Variable *Dest = getDest(); 727 const Variable *Dest = getDest();
710 switch (Dest->getType()) { 728 switch (Dest->getType()) {
711 default: 729 default:
712 // TODO(kschimpf) Figure if more cases are needed. 730 // TODO(kschimpf) Figure if more cases are needed.
713 Asm->setNeedsTextFixup(); 731 Asm->setNeedsTextFixup();
714 break; 732 break;
715 case IceType_f32: 733 case IceType_f32:
716 Asm->vdivs(getDest(), getSrc(0), getSrc(1), CondARM32::AL); 734 Asm->vdivs(getDest(), getSrc(0), getSrc(1), CondARM32::AL);
(...skipping 772 matching lines...) Expand 10 before | Expand all | Expand 10 after
1489 template <> const char *InstARM32Orr::Opcode = "orr"; 1507 template <> const char *InstARM32Orr::Opcode = "orr";
1490 template <> const char *InstARM32Rsb::Opcode = "rsb"; 1508 template <> const char *InstARM32Rsb::Opcode = "rsb";
1491 template <> const char *InstARM32Rsc::Opcode = "rsc"; 1509 template <> const char *InstARM32Rsc::Opcode = "rsc";
1492 template <> const char *InstARM32Sbc::Opcode = "sbc"; 1510 template <> const char *InstARM32Sbc::Opcode = "sbc";
1493 template <> const char *InstARM32Sdiv::Opcode = "sdiv"; 1511 template <> const char *InstARM32Sdiv::Opcode = "sdiv";
1494 template <> const char *InstARM32Sub::Opcode = "sub"; 1512 template <> const char *InstARM32Sub::Opcode = "sub";
1495 template <> const char *InstARM32Udiv::Opcode = "udiv"; 1513 template <> const char *InstARM32Udiv::Opcode = "udiv";
1496 // FP 1514 // FP
1497 template <> const char *InstARM32Vadd::Opcode = "vadd"; 1515 template <> const char *InstARM32Vadd::Opcode = "vadd";
1498 template <> const char *InstARM32Vand::Opcode = "vand"; 1516 template <> const char *InstARM32Vand::Opcode = "vand";
1517 template <> const char *InstARM32Vbsl::Opcode = "vbsl";
1499 template <> const char *InstARM32Vdiv::Opcode = "vdiv"; 1518 template <> const char *InstARM32Vdiv::Opcode = "vdiv";
1500 template <> const char *InstARM32Veor::Opcode = "veor"; 1519 template <> const char *InstARM32Veor::Opcode = "veor";
1501 template <> const char *InstARM32Vmla::Opcode = "vmla"; 1520 template <> const char *InstARM32Vmla::Opcode = "vmla";
1502 template <> const char *InstARM32Vmls::Opcode = "vmls"; 1521 template <> const char *InstARM32Vmls::Opcode = "vmls";
1503 template <> const char *InstARM32Vmul::Opcode = "vmul"; 1522 template <> const char *InstARM32Vmul::Opcode = "vmul";
1504 template <> const char *InstARM32Vorr::Opcode = "vorr"; 1523 template <> const char *InstARM32Vorr::Opcode = "vorr";
1505 template <> const char *InstARM32UnaryopFP<InstARM32::Vneg>::Opcode = "vneg"; 1524 template <> const char *InstARM32UnaryopFP<InstARM32::Vneg>::Opcode = "vneg";
1506 template <> const char *InstARM32ThreeAddrFP<InstARM32::Vshl>::Opcode = "vshl"; 1525 template <> const char *InstARM32ThreeAddrFP<InstARM32::Vshl>::Opcode = "vshl";
1507 template <> const char *InstARM32ThreeAddrFP<InstARM32::Vshr>::Opcode = "vshr"; 1526 template <> const char *InstARM32ThreeAddrFP<InstARM32::Vshr>::Opcode = "vshr";
1508 template <> const char *InstARM32Vsub::Opcode = "vsub"; 1527 template <> const char *InstARM32Vsub::Opcode = "vsub";
(...skipping 1482 matching lines...) Expand 10 before | Expand all | Expand 10 after
2991 3010
2992 template class InstARM32FourAddrGPR<InstARM32::Mla>; 3011 template class InstARM32FourAddrGPR<InstARM32::Mla>;
2993 template class InstARM32FourAddrGPR<InstARM32::Mls>; 3012 template class InstARM32FourAddrGPR<InstARM32::Mls>;
2994 3013
2995 template class InstARM32CmpLike<InstARM32::Cmn>; 3014 template class InstARM32CmpLike<InstARM32::Cmn>;
2996 template class InstARM32CmpLike<InstARM32::Cmp>; 3015 template class InstARM32CmpLike<InstARM32::Cmp>;
2997 template class InstARM32CmpLike<InstARM32::Tst>; 3016 template class InstARM32CmpLike<InstARM32::Tst>;
2998 3017
2999 } // end of namespace ARM32 3018 } // end of namespace ARM32
3000 } // end of namespace Ice 3019 } // end of namespace Ice
OLDNEW
« no previous file with comments | « src/IceInstARM32.h ('k') | src/IceTargetLoweringARM32.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698