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

Side by Side Diff: src/arm64/macro-assembler-arm64-inl.h

Issue 2819093002: Revert "Reland "ARM64: Add NEON support"" (Closed)
Patch Set: Created 3 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/arm64/macro-assembler-arm64.cc ('k') | src/arm64/simulator-arm64.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 // Copyright 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_ARM64_MACRO_ASSEMBLER_ARM64_INL_H_ 5 #ifndef V8_ARM64_MACRO_ASSEMBLER_ARM64_INL_H_
6 #define V8_ARM64_MACRO_ASSEMBLER_ARM64_INL_H_ 6 #define V8_ARM64_MACRO_ASSEMBLER_ARM64_INL_H_
7 7
8 #include <ctype.h> 8 #include <ctype.h>
9 9
10 #include "src/globals.h" 10 #include "src/globals.h"
(...skipping 529 matching lines...) Expand 10 before | Expand all | Expand 10 after
540 540
541 void MacroAssembler::Extr(const Register& rd, 541 void MacroAssembler::Extr(const Register& rd,
542 const Register& rn, 542 const Register& rn,
543 const Register& rm, 543 const Register& rm,
544 unsigned lsb) { 544 unsigned lsb) {
545 DCHECK(allow_macro_instructions_); 545 DCHECK(allow_macro_instructions_);
546 DCHECK(!rd.IsZero()); 546 DCHECK(!rd.IsZero());
547 extr(rd, rn, rm, lsb); 547 extr(rd, rn, rm, lsb);
548 } 548 }
549 549
550 void MacroAssembler::Fabs(const VRegister& fd, const VRegister& fn) { 550
551 void MacroAssembler::Fabs(const FPRegister& fd, const FPRegister& fn) {
551 DCHECK(allow_macro_instructions_); 552 DCHECK(allow_macro_instructions_);
552 fabs(fd, fn); 553 fabs(fd, fn);
553 } 554 }
554 555
555 void MacroAssembler::Fadd(const VRegister& fd, const VRegister& fn, 556
556 const VRegister& fm) { 557 void MacroAssembler::Fadd(const FPRegister& fd,
558 const FPRegister& fn,
559 const FPRegister& fm) {
557 DCHECK(allow_macro_instructions_); 560 DCHECK(allow_macro_instructions_);
558 fadd(fd, fn, fm); 561 fadd(fd, fn, fm);
559 } 562 }
560 563
561 void MacroAssembler::Fccmp(const VRegister& fn, const VRegister& fm, 564
562 StatusFlags nzcv, Condition cond) { 565 void MacroAssembler::Fccmp(const FPRegister& fn,
566 const FPRegister& fm,
567 StatusFlags nzcv,
568 Condition cond) {
563 DCHECK(allow_macro_instructions_); 569 DCHECK(allow_macro_instructions_);
564 DCHECK((cond != al) && (cond != nv)); 570 DCHECK((cond != al) && (cond != nv));
565 fccmp(fn, fm, nzcv, cond); 571 fccmp(fn, fm, nzcv, cond);
566 } 572 }
567 573
568 void MacroAssembler::Fcmp(const VRegister& fn, const VRegister& fm) { 574
575 void MacroAssembler::Fcmp(const FPRegister& fn, const FPRegister& fm) {
569 DCHECK(allow_macro_instructions_); 576 DCHECK(allow_macro_instructions_);
570 fcmp(fn, fm); 577 fcmp(fn, fm);
571 } 578 }
572 579
573 void MacroAssembler::Fcmp(const VRegister& fn, double value) { 580
581 void MacroAssembler::Fcmp(const FPRegister& fn, double value) {
574 DCHECK(allow_macro_instructions_); 582 DCHECK(allow_macro_instructions_);
575 if (value != 0.0) { 583 if (value != 0.0) {
576 UseScratchRegisterScope temps(this); 584 UseScratchRegisterScope temps(this);
577 VRegister tmp = temps.AcquireSameSizeAs(fn); 585 FPRegister tmp = temps.AcquireSameSizeAs(fn);
578 Fmov(tmp, value); 586 Fmov(tmp, value);
579 fcmp(fn, tmp); 587 fcmp(fn, tmp);
580 } else { 588 } else {
581 fcmp(fn, value); 589 fcmp(fn, value);
582 } 590 }
583 } 591 }
584 592
585 void MacroAssembler::Fcsel(const VRegister& fd, const VRegister& fn, 593
586 const VRegister& fm, Condition cond) { 594 void MacroAssembler::Fcsel(const FPRegister& fd,
595 const FPRegister& fn,
596 const FPRegister& fm,
597 Condition cond) {
587 DCHECK(allow_macro_instructions_); 598 DCHECK(allow_macro_instructions_);
588 DCHECK((cond != al) && (cond != nv)); 599 DCHECK((cond != al) && (cond != nv));
589 fcsel(fd, fn, fm, cond); 600 fcsel(fd, fn, fm, cond);
590 } 601 }
591 602
592 void MacroAssembler::Fcvt(const VRegister& fd, const VRegister& fn) { 603
604 void MacroAssembler::Fcvt(const FPRegister& fd, const FPRegister& fn) {
593 DCHECK(allow_macro_instructions_); 605 DCHECK(allow_macro_instructions_);
594 fcvt(fd, fn); 606 fcvt(fd, fn);
595 } 607 }
596 608
597 void MacroAssembler::Fcvtas(const Register& rd, const VRegister& fn) { 609
610 void MacroAssembler::Fcvtas(const Register& rd, const FPRegister& fn) {
598 DCHECK(allow_macro_instructions_); 611 DCHECK(allow_macro_instructions_);
599 DCHECK(!rd.IsZero()); 612 DCHECK(!rd.IsZero());
600 fcvtas(rd, fn); 613 fcvtas(rd, fn);
601 } 614 }
602 615
603 void MacroAssembler::Fcvtau(const Register& rd, const VRegister& fn) { 616
617 void MacroAssembler::Fcvtau(const Register& rd, const FPRegister& fn) {
604 DCHECK(allow_macro_instructions_); 618 DCHECK(allow_macro_instructions_);
605 DCHECK(!rd.IsZero()); 619 DCHECK(!rd.IsZero());
606 fcvtau(rd, fn); 620 fcvtau(rd, fn);
607 } 621 }
608 622
609 void MacroAssembler::Fcvtms(const Register& rd, const VRegister& fn) { 623
624 void MacroAssembler::Fcvtms(const Register& rd, const FPRegister& fn) {
610 DCHECK(allow_macro_instructions_); 625 DCHECK(allow_macro_instructions_);
611 DCHECK(!rd.IsZero()); 626 DCHECK(!rd.IsZero());
612 fcvtms(rd, fn); 627 fcvtms(rd, fn);
613 } 628 }
614 629
615 void MacroAssembler::Fcvtmu(const Register& rd, const VRegister& fn) { 630
631 void MacroAssembler::Fcvtmu(const Register& rd, const FPRegister& fn) {
616 DCHECK(allow_macro_instructions_); 632 DCHECK(allow_macro_instructions_);
617 DCHECK(!rd.IsZero()); 633 DCHECK(!rd.IsZero());
618 fcvtmu(rd, fn); 634 fcvtmu(rd, fn);
619 } 635 }
620 636
621 void MacroAssembler::Fcvtns(const Register& rd, const VRegister& fn) { 637
638 void MacroAssembler::Fcvtns(const Register& rd, const FPRegister& fn) {
622 DCHECK(allow_macro_instructions_); 639 DCHECK(allow_macro_instructions_);
623 DCHECK(!rd.IsZero()); 640 DCHECK(!rd.IsZero());
624 fcvtns(rd, fn); 641 fcvtns(rd, fn);
625 } 642 }
626 643
627 void MacroAssembler::Fcvtnu(const Register& rd, const VRegister& fn) { 644
645 void MacroAssembler::Fcvtnu(const Register& rd, const FPRegister& fn) {
628 DCHECK(allow_macro_instructions_); 646 DCHECK(allow_macro_instructions_);
629 DCHECK(!rd.IsZero()); 647 DCHECK(!rd.IsZero());
630 fcvtnu(rd, fn); 648 fcvtnu(rd, fn);
631 } 649 }
632 650
633 void MacroAssembler::Fcvtzs(const Register& rd, const VRegister& fn) { 651
652 void MacroAssembler::Fcvtzs(const Register& rd, const FPRegister& fn) {
634 DCHECK(allow_macro_instructions_); 653 DCHECK(allow_macro_instructions_);
635 DCHECK(!rd.IsZero()); 654 DCHECK(!rd.IsZero());
636 fcvtzs(rd, fn); 655 fcvtzs(rd, fn);
637 } 656 }
638 void MacroAssembler::Fcvtzu(const Register& rd, const VRegister& fn) { 657 void MacroAssembler::Fcvtzu(const Register& rd, const FPRegister& fn) {
639 DCHECK(allow_macro_instructions_); 658 DCHECK(allow_macro_instructions_);
640 DCHECK(!rd.IsZero()); 659 DCHECK(!rd.IsZero());
641 fcvtzu(rd, fn); 660 fcvtzu(rd, fn);
642 } 661 }
643 662
644 void MacroAssembler::Fdiv(const VRegister& fd, const VRegister& fn, 663
645 const VRegister& fm) { 664 void MacroAssembler::Fdiv(const FPRegister& fd,
665 const FPRegister& fn,
666 const FPRegister& fm) {
646 DCHECK(allow_macro_instructions_); 667 DCHECK(allow_macro_instructions_);
647 fdiv(fd, fn, fm); 668 fdiv(fd, fn, fm);
648 } 669 }
649 670
650 void MacroAssembler::Fmadd(const VRegister& fd, const VRegister& fn, 671
651 const VRegister& fm, const VRegister& fa) { 672 void MacroAssembler::Fmadd(const FPRegister& fd,
673 const FPRegister& fn,
674 const FPRegister& fm,
675 const FPRegister& fa) {
652 DCHECK(allow_macro_instructions_); 676 DCHECK(allow_macro_instructions_);
653 fmadd(fd, fn, fm, fa); 677 fmadd(fd, fn, fm, fa);
654 } 678 }
655 679
656 void MacroAssembler::Fmax(const VRegister& fd, const VRegister& fn, 680
657 const VRegister& fm) { 681 void MacroAssembler::Fmax(const FPRegister& fd,
682 const FPRegister& fn,
683 const FPRegister& fm) {
658 DCHECK(allow_macro_instructions_); 684 DCHECK(allow_macro_instructions_);
659 fmax(fd, fn, fm); 685 fmax(fd, fn, fm);
660 } 686 }
661 687
662 void MacroAssembler::Fmaxnm(const VRegister& fd, const VRegister& fn, 688
663 const VRegister& fm) { 689 void MacroAssembler::Fmaxnm(const FPRegister& fd,
690 const FPRegister& fn,
691 const FPRegister& fm) {
664 DCHECK(allow_macro_instructions_); 692 DCHECK(allow_macro_instructions_);
665 fmaxnm(fd, fn, fm); 693 fmaxnm(fd, fn, fm);
666 } 694 }
667 695
668 void MacroAssembler::Fmin(const VRegister& fd, const VRegister& fn, 696
669 const VRegister& fm) { 697 void MacroAssembler::Fmin(const FPRegister& fd,
698 const FPRegister& fn,
699 const FPRegister& fm) {
670 DCHECK(allow_macro_instructions_); 700 DCHECK(allow_macro_instructions_);
671 fmin(fd, fn, fm); 701 fmin(fd, fn, fm);
672 } 702 }
673 703
674 void MacroAssembler::Fminnm(const VRegister& fd, const VRegister& fn, 704
675 const VRegister& fm) { 705 void MacroAssembler::Fminnm(const FPRegister& fd,
706 const FPRegister& fn,
707 const FPRegister& fm) {
676 DCHECK(allow_macro_instructions_); 708 DCHECK(allow_macro_instructions_);
677 fminnm(fd, fn, fm); 709 fminnm(fd, fn, fm);
678 } 710 }
679 711
680 void MacroAssembler::Fmov(VRegister fd, VRegister fn) { 712
713 void MacroAssembler::Fmov(FPRegister fd, FPRegister fn) {
681 DCHECK(allow_macro_instructions_); 714 DCHECK(allow_macro_instructions_);
682 // Only emit an instruction if fd and fn are different, and they are both D 715 // Only emit an instruction if fd and fn are different, and they are both D
683 // registers. fmov(s0, s0) is not a no-op because it clears the top word of 716 // registers. fmov(s0, s0) is not a no-op because it clears the top word of
684 // d0. Technically, fmov(d0, d0) is not a no-op either because it clears the 717 // d0. Technically, fmov(d0, d0) is not a no-op either because it clears the
685 // top of q0, but VRegister does not currently support Q registers. 718 // top of q0, but FPRegister does not currently support Q registers.
686 if (!fd.Is(fn) || !fd.Is64Bits()) { 719 if (!fd.Is(fn) || !fd.Is64Bits()) {
687 fmov(fd, fn); 720 fmov(fd, fn);
688 } 721 }
689 } 722 }
690 723
691 void MacroAssembler::Fmov(VRegister fd, Register rn) { 724
725 void MacroAssembler::Fmov(FPRegister fd, Register rn) {
692 DCHECK(allow_macro_instructions_); 726 DCHECK(allow_macro_instructions_);
693 fmov(fd, rn); 727 fmov(fd, rn);
694 } 728 }
695 729
696 void MacroAssembler::Fmov(VRegister vd, double imm) { 730
697 DCHECK(allow_macro_instructions_); 731 void MacroAssembler::Fmov(FPRegister fd, double imm) {
698 732 DCHECK(allow_macro_instructions_);
699 if (vd.Is1S() || vd.Is2S() || vd.Is4S()) { 733 if (fd.Is32Bits()) {
700 Fmov(vd, static_cast<float>(imm)); 734 Fmov(fd, static_cast<float>(imm));
701 return; 735 return;
702 } 736 }
703 737
704 DCHECK(vd.Is1D() || vd.Is2D()); 738 DCHECK(fd.Is64Bits());
705 if (IsImmFP64(imm)) { 739 if (IsImmFP64(imm)) {
706 fmov(vd, imm); 740 fmov(fd, imm);
741 } else if ((imm == 0.0) && (copysign(1.0, imm) == 1.0)) {
742 fmov(fd, xzr);
707 } else { 743 } else {
708 uint64_t bits = bit_cast<uint64_t>(imm); 744 Ldr(fd, imm);
709 if (vd.IsScalar()) { 745 }
710 if (bits == 0) { 746 }
711 fmov(vd, xzr); 747
712 } else { 748
713 Ldr(vd, imm); 749 void MacroAssembler::Fmov(FPRegister fd, float imm) {
714 } 750 DCHECK(allow_macro_instructions_);
715 } else { 751 if (fd.Is64Bits()) {
716 // TODO(all): consider NEON support for load literal. 752 Fmov(fd, static_cast<double>(imm));
717 Movi(vd, bits);
718 }
719 }
720 }
721
722 void MacroAssembler::Fmov(VRegister vd, float imm) {
723 DCHECK(allow_macro_instructions_);
724 if (vd.Is1D() || vd.Is2D()) {
725 Fmov(vd, static_cast<double>(imm));
726 return; 753 return;
727 } 754 }
728 755
729 DCHECK(vd.Is1S() || vd.Is2S() || vd.Is4S()); 756 DCHECK(fd.Is32Bits());
730 if (IsImmFP32(imm)) { 757 if (IsImmFP32(imm)) {
731 fmov(vd, imm); 758 fmov(fd, imm);
759 } else if ((imm == 0.0) && (copysign(1.0, imm) == 1.0)) {
760 fmov(fd, wzr);
732 } else { 761 } else {
733 uint32_t bits = bit_cast<uint32_t>(imm); 762 UseScratchRegisterScope temps(this);
734 if (vd.IsScalar()) { 763 Register tmp = temps.AcquireW();
735 if (bits == 0) { 764 // TODO(all): Use Assembler::ldr(const FPRegister& ft, float imm).
736 fmov(vd, wzr); 765 Mov(tmp, float_to_rawbits(imm));
737 } else { 766 Fmov(fd, tmp);
738 UseScratchRegisterScope temps(this); 767 }
739 Register tmp = temps.AcquireW(); 768 }
740 // TODO(all): Use Assembler::ldr(const VRegister& ft, float imm). 769
741 Mov(tmp, bit_cast<uint32_t>(imm)); 770
742 Fmov(vd, tmp); 771 void MacroAssembler::Fmov(Register rd, FPRegister fn) {
743 }
744 } else {
745 // TODO(all): consider NEON support for load literal.
746 Movi(vd, bits);
747 }
748 }
749 }
750
751 void MacroAssembler::Fmov(Register rd, VRegister fn) {
752 DCHECK(allow_macro_instructions_); 772 DCHECK(allow_macro_instructions_);
753 DCHECK(!rd.IsZero()); 773 DCHECK(!rd.IsZero());
754 fmov(rd, fn); 774 fmov(rd, fn);
755 } 775 }
756 776
757 void MacroAssembler::Fmsub(const VRegister& fd, const VRegister& fn, 777
758 const VRegister& fm, const VRegister& fa) { 778 void MacroAssembler::Fmsub(const FPRegister& fd,
779 const FPRegister& fn,
780 const FPRegister& fm,
781 const FPRegister& fa) {
759 DCHECK(allow_macro_instructions_); 782 DCHECK(allow_macro_instructions_);
760 fmsub(fd, fn, fm, fa); 783 fmsub(fd, fn, fm, fa);
761 } 784 }
762 785
763 void MacroAssembler::Fmul(const VRegister& fd, const VRegister& fn, 786
764 const VRegister& fm) { 787 void MacroAssembler::Fmul(const FPRegister& fd,
788 const FPRegister& fn,
789 const FPRegister& fm) {
765 DCHECK(allow_macro_instructions_); 790 DCHECK(allow_macro_instructions_);
766 fmul(fd, fn, fm); 791 fmul(fd, fn, fm);
767 } 792 }
768 793
769 void MacroAssembler::Fnmadd(const VRegister& fd, const VRegister& fn, 794
770 const VRegister& fm, const VRegister& fa) { 795 void MacroAssembler::Fneg(const FPRegister& fd, const FPRegister& fn) {
796 DCHECK(allow_macro_instructions_);
797 fneg(fd, fn);
798 }
799
800
801 void MacroAssembler::Fnmadd(const FPRegister& fd,
802 const FPRegister& fn,
803 const FPRegister& fm,
804 const FPRegister& fa) {
771 DCHECK(allow_macro_instructions_); 805 DCHECK(allow_macro_instructions_);
772 fnmadd(fd, fn, fm, fa); 806 fnmadd(fd, fn, fm, fa);
773 } 807 }
774 808
775 void MacroAssembler::Fnmsub(const VRegister& fd, const VRegister& fn, 809
776 const VRegister& fm, const VRegister& fa) { 810 void MacroAssembler::Fnmsub(const FPRegister& fd,
811 const FPRegister& fn,
812 const FPRegister& fm,
813 const FPRegister& fa) {
777 DCHECK(allow_macro_instructions_); 814 DCHECK(allow_macro_instructions_);
778 fnmsub(fd, fn, fm, fa); 815 fnmsub(fd, fn, fm, fa);
779 } 816 }
780 817
781 void MacroAssembler::Fsub(const VRegister& fd, const VRegister& fn, 818
782 const VRegister& fm) { 819 void MacroAssembler::Frinta(const FPRegister& fd, const FPRegister& fn) {
820 DCHECK(allow_macro_instructions_);
821 frinta(fd, fn);
822 }
823
824
825 void MacroAssembler::Frintm(const FPRegister& fd, const FPRegister& fn) {
826 DCHECK(allow_macro_instructions_);
827 frintm(fd, fn);
828 }
829
830
831 void MacroAssembler::Frintn(const FPRegister& fd, const FPRegister& fn) {
832 DCHECK(allow_macro_instructions_);
833 frintn(fd, fn);
834 }
835
836
837 void MacroAssembler::Frintp(const FPRegister& fd, const FPRegister& fn) {
838 DCHECK(allow_macro_instructions_);
839 frintp(fd, fn);
840 }
841
842
843 void MacroAssembler::Frintz(const FPRegister& fd, const FPRegister& fn) {
844 DCHECK(allow_macro_instructions_);
845 frintz(fd, fn);
846 }
847
848
849 void MacroAssembler::Fsqrt(const FPRegister& fd, const FPRegister& fn) {
850 DCHECK(allow_macro_instructions_);
851 fsqrt(fd, fn);
852 }
853
854
855 void MacroAssembler::Fsub(const FPRegister& fd,
856 const FPRegister& fn,
857 const FPRegister& fm) {
783 DCHECK(allow_macro_instructions_); 858 DCHECK(allow_macro_instructions_);
784 fsub(fd, fn, fm); 859 fsub(fd, fn, fm);
785 } 860 }
786 861
787 862
788 void MacroAssembler::Hint(SystemHint code) { 863 void MacroAssembler::Hint(SystemHint code) {
789 DCHECK(allow_macro_instructions_); 864 DCHECK(allow_macro_instructions_);
790 hint(code); 865 hint(code);
791 } 866 }
792 867
(...skipping 12 matching lines...) Expand all
805 880
806 void MacroAssembler::Ldr(const CPURegister& rt, const Immediate& imm) { 881 void MacroAssembler::Ldr(const CPURegister& rt, const Immediate& imm) {
807 DCHECK(allow_macro_instructions_); 882 DCHECK(allow_macro_instructions_);
808 ldr(rt, imm); 883 ldr(rt, imm);
809 } 884 }
810 885
811 886
812 void MacroAssembler::Ldr(const CPURegister& rt, double imm) { 887 void MacroAssembler::Ldr(const CPURegister& rt, double imm) {
813 DCHECK(allow_macro_instructions_); 888 DCHECK(allow_macro_instructions_);
814 DCHECK(rt.Is64Bits()); 889 DCHECK(rt.Is64Bits());
815 ldr(rt, Immediate(bit_cast<uint64_t>(imm))); 890 ldr(rt, Immediate(double_to_rawbits(imm)));
816 } 891 }
817 892
818 893
819 void MacroAssembler::Lsl(const Register& rd, 894 void MacroAssembler::Lsl(const Register& rd,
820 const Register& rn, 895 const Register& rn,
821 unsigned shift) { 896 unsigned shift) {
822 DCHECK(allow_macro_instructions_); 897 DCHECK(allow_macro_instructions_);
823 DCHECK(!rd.IsZero()); 898 DCHECK(!rd.IsZero());
824 lsl(rd, rn, shift); 899 lsl(rd, rn, shift);
825 } 900 }
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after
988 1063
989 void MacroAssembler::Sbfx(const Register& rd, 1064 void MacroAssembler::Sbfx(const Register& rd,
990 const Register& rn, 1065 const Register& rn,
991 unsigned lsb, 1066 unsigned lsb,
992 unsigned width) { 1067 unsigned width) {
993 DCHECK(allow_macro_instructions_); 1068 DCHECK(allow_macro_instructions_);
994 DCHECK(!rd.IsZero()); 1069 DCHECK(!rd.IsZero());
995 sbfx(rd, rn, lsb, width); 1070 sbfx(rd, rn, lsb, width);
996 } 1071 }
997 1072
998 void MacroAssembler::Scvtf(const VRegister& fd, const Register& rn, 1073
1074 void MacroAssembler::Scvtf(const FPRegister& fd,
1075 const Register& rn,
999 unsigned fbits) { 1076 unsigned fbits) {
1000 DCHECK(allow_macro_instructions_); 1077 DCHECK(allow_macro_instructions_);
1001 scvtf(fd, rn, fbits); 1078 scvtf(fd, rn, fbits);
1002 } 1079 }
1003 1080
1004 1081
1005 void MacroAssembler::Sdiv(const Register& rd, 1082 void MacroAssembler::Sdiv(const Register& rd,
1006 const Register& rn, 1083 const Register& rn,
1007 const Register& rm) { 1084 const Register& rm) {
1008 DCHECK(allow_macro_instructions_); 1085 DCHECK(allow_macro_instructions_);
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
1090 1167
1091 void MacroAssembler::Ubfx(const Register& rd, 1168 void MacroAssembler::Ubfx(const Register& rd,
1092 const Register& rn, 1169 const Register& rn,
1093 unsigned lsb, 1170 unsigned lsb,
1094 unsigned width) { 1171 unsigned width) {
1095 DCHECK(allow_macro_instructions_); 1172 DCHECK(allow_macro_instructions_);
1096 DCHECK(!rd.IsZero()); 1173 DCHECK(!rd.IsZero());
1097 ubfx(rd, rn, lsb, width); 1174 ubfx(rd, rn, lsb, width);
1098 } 1175 }
1099 1176
1100 void MacroAssembler::Ucvtf(const VRegister& fd, const Register& rn, 1177
1178 void MacroAssembler::Ucvtf(const FPRegister& fd,
1179 const Register& rn,
1101 unsigned fbits) { 1180 unsigned fbits) {
1102 DCHECK(allow_macro_instructions_); 1181 DCHECK(allow_macro_instructions_);
1103 ucvtf(fd, rn, fbits); 1182 ucvtf(fd, rn, fbits);
1104 } 1183 }
1105 1184
1106 1185
1107 void MacroAssembler::Udiv(const Register& rd, 1186 void MacroAssembler::Udiv(const Register& rd,
1108 const Register& rn, 1187 const Register& rn,
1109 const Register& rm) { 1188 const Register& rm) {
1110 DCHECK(allow_macro_instructions_); 1189 DCHECK(allow_macro_instructions_);
(...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after
1232 DCHECK(dst.Is64Bits() && src.Is64Bits()); 1311 DCHECK(dst.Is64Bits() && src.Is64Bits());
1233 if (FLAG_enable_slow_asserts) { 1312 if (FLAG_enable_slow_asserts) {
1234 AssertSmi(src); 1313 AssertSmi(src);
1235 } 1314 }
1236 Asr(dst, src, kSmiShift); 1315 Asr(dst, src, kSmiShift);
1237 } 1316 }
1238 1317
1239 1318
1240 void MacroAssembler::SmiUntag(Register smi) { SmiUntag(smi, smi); } 1319 void MacroAssembler::SmiUntag(Register smi) { SmiUntag(smi, smi); }
1241 1320
1242 void MacroAssembler::SmiUntagToDouble(VRegister dst, Register src, 1321
1322 void MacroAssembler::SmiUntagToDouble(FPRegister dst,
1323 Register src,
1243 UntagMode mode) { 1324 UntagMode mode) {
1244 DCHECK(dst.Is64Bits() && src.Is64Bits()); 1325 DCHECK(dst.Is64Bits() && src.Is64Bits());
1245 if (FLAG_enable_slow_asserts && (mode == kNotSpeculativeUntag)) { 1326 if (FLAG_enable_slow_asserts && (mode == kNotSpeculativeUntag)) {
1246 AssertSmi(src); 1327 AssertSmi(src);
1247 } 1328 }
1248 Scvtf(dst, src, kSmiShift); 1329 Scvtf(dst, src, kSmiShift);
1249 } 1330 }
1250 1331
1251 void MacroAssembler::SmiUntagToFloat(VRegister dst, Register src, 1332
1333 void MacroAssembler::SmiUntagToFloat(FPRegister dst,
1334 Register src,
1252 UntagMode mode) { 1335 UntagMode mode) {
1253 DCHECK(dst.Is32Bits() && src.Is64Bits()); 1336 DCHECK(dst.Is32Bits() && src.Is64Bits());
1254 if (FLAG_enable_slow_asserts && (mode == kNotSpeculativeUntag)) { 1337 if (FLAG_enable_slow_asserts && (mode == kNotSpeculativeUntag)) {
1255 AssertSmi(src); 1338 AssertSmi(src);
1256 } 1339 }
1257 Scvtf(dst, src, kSmiShift); 1340 Scvtf(dst, src, kSmiShift);
1258 } 1341 }
1259 1342
1260 1343
1261 void MacroAssembler::SmiTagAndPush(Register src) { 1344 void MacroAssembler::SmiTagAndPush(Register src) {
(...skipping 324 matching lines...) Expand 10 before | Expand all | Expand 10 after
1586 DCHECK(isprint(marker_name[0]) && isprint(marker_name[1])); 1669 DCHECK(isprint(marker_name[0]) && isprint(marker_name[1]));
1587 1670
1588 InstructionAccurateScope scope(this, 1); 1671 InstructionAccurateScope scope(this, 1);
1589 movn(xzr, (marker_name[1] << 8) | marker_name[0]); 1672 movn(xzr, (marker_name[1] << 8) | marker_name[0]);
1590 } 1673 }
1591 1674
1592 } // namespace internal 1675 } // namespace internal
1593 } // namespace v8 1676 } // namespace v8
1594 1677
1595 #endif // V8_ARM64_MACRO_ASSEMBLER_ARM64_INL_H_ 1678 #endif // V8_ARM64_MACRO_ASSEMBLER_ARM64_INL_H_
OLDNEW
« no previous file with comments | « src/arm64/macro-assembler-arm64.cc ('k') | src/arm64/simulator-arm64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698