• Home
  • Raw
  • Download

Lines Matching refs:CGP

3 …sa3d -mcpu=hawaii -denormal-fp-math-f32=preserve-sign < %s | FileCheck -check-prefixes=CHECK,CGP %s
678 ; CGP-LABEL: v_srem_v2i64:
679 ; CGP: ; %bb.0:
680 ; CGP-NEXT: s_waitcnt vmcnt(0) expcnt(0) lgkmcnt(0)
681 ; CGP-NEXT: v_mov_b32_e32 v9, v1
682 ; CGP-NEXT: v_mov_b32_e32 v8, v0
683 ; CGP-NEXT: v_or_b32_e32 v1, v9, v5
684 ; CGP-NEXT: v_mov_b32_e32 v0, 0
685 ; CGP-NEXT: v_cmp_ne_u64_e32 vcc, 0, v[0:1]
686 ; CGP-NEXT: ; implicit-def: $vgpr0_vgpr1
687 ; CGP-NEXT: s_and_saveexec_b64 s[4:5], vcc
688 ; CGP-NEXT: s_xor_b64 s[6:7], exec, s[4:5]
689 ; CGP-NEXT: s_cbranch_execz BB2_2
690 ; CGP-NEXT: ; %bb.1:
691 ; CGP-NEXT: v_ashrrev_i32_e32 v0, 31, v5
692 ; CGP-NEXT: v_add_i32_e32 v1, vcc, v4, v0
693 ; CGP-NEXT: v_addc_u32_e32 v5, vcc, v5, v0, vcc
694 ; CGP-NEXT: v_xor_b32_e32 v1, v1, v0
695 ; CGP-NEXT: v_xor_b32_e32 v0, v5, v0
696 ; CGP-NEXT: v_cvt_f32_u32_e32 v5, v1
697 ; CGP-NEXT: v_cvt_f32_u32_e32 v10, v0
698 ; CGP-NEXT: v_ashrrev_i32_e32 v11, 31, v9
699 ; CGP-NEXT: v_mac_f32_e32 v5, 0x4f800000, v10
700 ; CGP-NEXT: v_rcp_iflag_f32_e32 v5, v5
701 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v8, v11
702 ; CGP-NEXT: v_addc_u32_e32 v9, vcc, v9, v11, vcc
703 ; CGP-NEXT: v_sub_i32_e32 v13, vcc, 0, v1
704 ; CGP-NEXT: v_mul_f32_e32 v5, 0x5f7ffffc, v5
705 ; CGP-NEXT: v_mul_f32_e32 v12, 0x2f800000, v5
706 ; CGP-NEXT: v_trunc_f32_e32 v12, v12
707 ; CGP-NEXT: v_mac_f32_e32 v5, 0xcf800000, v12
708 ; CGP-NEXT: v_cvt_u32_f32_e32 v5, v5
709 ; CGP-NEXT: v_cvt_u32_f32_e32 v12, v12
710 ; CGP-NEXT: v_subb_u32_e32 v14, vcc, 0, v0, vcc
711 ; CGP-NEXT: v_xor_b32_e32 v10, v10, v11
712 ; CGP-NEXT: v_mul_lo_u32 v15, v14, v5
713 ; CGP-NEXT: v_mul_lo_u32 v16, v13, v12
714 ; CGP-NEXT: v_mul_hi_u32 v18, v13, v5
715 ; CGP-NEXT: v_mul_lo_u32 v17, v13, v5
716 ; CGP-NEXT: v_xor_b32_e32 v9, v9, v11
717 ; CGP-NEXT: v_add_i32_e32 v15, vcc, v15, v16
718 ; CGP-NEXT: v_add_i32_e32 v15, vcc, v15, v18
719 ; CGP-NEXT: v_mul_lo_u32 v16, v12, v17
720 ; CGP-NEXT: v_mul_lo_u32 v18, v5, v15
721 ; CGP-NEXT: v_mul_hi_u32 v19, v5, v17
722 ; CGP-NEXT: v_mul_hi_u32 v17, v12, v17
723 ; CGP-NEXT: v_add_i32_e32 v16, vcc, v16, v18
724 ; CGP-NEXT: v_cndmask_b32_e64 v18, 0, 1, vcc
725 ; CGP-NEXT: v_add_i32_e32 v16, vcc, v16, v19
726 ; CGP-NEXT: v_cndmask_b32_e64 v16, 0, 1, vcc
727 ; CGP-NEXT: v_mul_lo_u32 v19, v12, v15
728 ; CGP-NEXT: v_add_i32_e32 v16, vcc, v18, v16
729 ; CGP-NEXT: v_mul_hi_u32 v18, v5, v15
730 ; CGP-NEXT: v_mul_hi_u32 v15, v12, v15
731 ; CGP-NEXT: v_add_i32_e32 v17, vcc, v19, v17
732 ; CGP-NEXT: v_cndmask_b32_e64 v19, 0, 1, vcc
733 ; CGP-NEXT: v_add_i32_e32 v17, vcc, v17, v18
734 ; CGP-NEXT: v_cndmask_b32_e64 v18, 0, 1, vcc
735 ; CGP-NEXT: v_add_i32_e32 v18, vcc, v19, v18
736 ; CGP-NEXT: v_add_i32_e32 v16, vcc, v17, v16
737 ; CGP-NEXT: v_cndmask_b32_e64 v17, 0, 1, vcc
738 ; CGP-NEXT: v_add_i32_e32 v17, vcc, v18, v17
739 ; CGP-NEXT: v_add_i32_e32 v15, vcc, v15, v17
740 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v5, v16
741 ; CGP-NEXT: v_addc_u32_e64 v16, s[4:5], v12, v15, vcc
742 ; CGP-NEXT: v_mul_lo_u32 v14, v14, v5
743 ; CGP-NEXT: v_mul_lo_u32 v17, v13, v16
744 ; CGP-NEXT: v_mul_lo_u32 v18, v13, v5
745 ; CGP-NEXT: v_mul_hi_u32 v13, v13, v5
746 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v12, v15
747 ; CGP-NEXT: v_add_i32_e64 v14, s[4:5], v14, v17
748 ; CGP-NEXT: v_mul_hi_u32 v15, v5, v18
749 ; CGP-NEXT: v_add_i32_e64 v13, s[4:5], v14, v13
750 ; CGP-NEXT: v_mul_lo_u32 v14, v16, v18
751 ; CGP-NEXT: v_mul_lo_u32 v17, v5, v13
752 ; CGP-NEXT: v_mul_hi_u32 v18, v16, v18
753 ; CGP-NEXT: v_add_i32_e64 v14, s[4:5], v14, v17
754 ; CGP-NEXT: v_cndmask_b32_e64 v17, 0, 1, s[4:5]
755 ; CGP-NEXT: v_add_i32_e64 v14, s[4:5], v14, v15
756 ; CGP-NEXT: v_cndmask_b32_e64 v14, 0, 1, s[4:5]
757 ; CGP-NEXT: v_mul_lo_u32 v15, v16, v13
758 ; CGP-NEXT: v_add_i32_e64 v14, s[4:5], v17, v14
759 ; CGP-NEXT: v_mul_hi_u32 v17, v5, v13
760 ; CGP-NEXT: v_mul_hi_u32 v13, v16, v13
761 ; CGP-NEXT: v_add_i32_e64 v15, s[4:5], v15, v18
762 ; CGP-NEXT: v_cndmask_b32_e64 v18, 0, 1, s[4:5]
763 ; CGP-NEXT: v_add_i32_e64 v15, s[4:5], v15, v17
764 ; CGP-NEXT: v_cndmask_b32_e64 v17, 0, 1, s[4:5]
765 ; CGP-NEXT: v_add_i32_e64 v17, s[4:5], v18, v17
766 ; CGP-NEXT: v_add_i32_e64 v14, s[4:5], v15, v14
767 ; CGP-NEXT: v_cndmask_b32_e64 v15, 0, 1, s[4:5]
768 ; CGP-NEXT: v_add_i32_e64 v15, s[4:5], v17, v15
769 ; CGP-NEXT: v_add_i32_e64 v13, s[4:5], v13, v15
770 ; CGP-NEXT: v_addc_u32_e32 v12, vcc, v12, v13, vcc
771 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v5, v14
772 ; CGP-NEXT: v_addc_u32_e32 v12, vcc, 0, v12, vcc
773 ; CGP-NEXT: v_mul_lo_u32 v13, v9, v5
774 ; CGP-NEXT: v_mul_lo_u32 v14, v10, v12
775 ; CGP-NEXT: v_mul_hi_u32 v15, v10, v5
776 ; CGP-NEXT: v_mul_hi_u32 v5, v9, v5
777 ; CGP-NEXT: v_add_i32_e32 v13, vcc, v13, v14
778 ; CGP-NEXT: v_cndmask_b32_e64 v14, 0, 1, vcc
779 ; CGP-NEXT: v_add_i32_e32 v13, vcc, v13, v15
780 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, 1, vcc
781 ; CGP-NEXT: v_mul_lo_u32 v15, v9, v12
782 ; CGP-NEXT: v_add_i32_e32 v13, vcc, v14, v13
783 ; CGP-NEXT: v_mul_hi_u32 v14, v10, v12
784 ; CGP-NEXT: v_mul_hi_u32 v12, v9, v12
785 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v15, v5
786 ; CGP-NEXT: v_cndmask_b32_e64 v15, 0, 1, vcc
787 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v5, v14
788 ; CGP-NEXT: v_cndmask_b32_e64 v14, 0, 1, vcc
789 ; CGP-NEXT: v_add_i32_e32 v14, vcc, v15, v14
790 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v5, v13
791 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, 1, vcc
792 ; CGP-NEXT: v_add_i32_e32 v13, vcc, v14, v13
793 ; CGP-NEXT: v_add_i32_e32 v12, vcc, v12, v13
794 ; CGP-NEXT: v_mul_lo_u32 v13, v0, v5
795 ; CGP-NEXT: v_mul_lo_u32 v12, v1, v12
796 ; CGP-NEXT: v_mul_lo_u32 v14, v1, v5
797 ; CGP-NEXT: v_mul_hi_u32 v5, v1, v5
798 ; CGP-NEXT: v_add_i32_e32 v12, vcc, v13, v12
799 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v12, v5
800 ; CGP-NEXT: v_sub_i32_e32 v10, vcc, v10, v14
801 ; CGP-NEXT: v_subb_u32_e64 v12, s[4:5], v9, v5, vcc
802 ; CGP-NEXT: v_sub_i32_e64 v5, s[4:5], v9, v5
803 ; CGP-NEXT: v_cmp_ge_u32_e64 s[4:5], v12, v0
804 ; CGP-NEXT: v_cndmask_b32_e64 v9, 0, -1, s[4:5]
805 ; CGP-NEXT: v_cmp_ge_u32_e64 s[4:5], v10, v1
806 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, -1, s[4:5]
807 ; CGP-NEXT: v_cmp_eq_u32_e64 s[4:5], v12, v0
808 ; CGP-NEXT: v_subb_u32_e32 v5, vcc, v5, v0, vcc
809 ; CGP-NEXT: v_cndmask_b32_e64 v9, v9, v13, s[4:5]
810 ; CGP-NEXT: v_sub_i32_e32 v13, vcc, v10, v1
811 ; CGP-NEXT: v_subbrev_u32_e64 v14, s[4:5], 0, v5, vcc
812 ; CGP-NEXT: v_cmp_ge_u32_e64 s[4:5], v14, v0
813 ; CGP-NEXT: v_cndmask_b32_e64 v15, 0, -1, s[4:5]
814 ; CGP-NEXT: v_cmp_ge_u32_e64 s[4:5], v13, v1
815 ; CGP-NEXT: v_cndmask_b32_e64 v16, 0, -1, s[4:5]
816 ; CGP-NEXT: v_cmp_eq_u32_e64 s[4:5], v14, v0
817 ; CGP-NEXT: v_subb_u32_e32 v0, vcc, v5, v0, vcc
818 ; CGP-NEXT: v_sub_i32_e32 v1, vcc, v13, v1
819 ; CGP-NEXT: v_cndmask_b32_e64 v15, v15, v16, s[4:5]
820 ; CGP-NEXT: v_subbrev_u32_e32 v0, vcc, 0, v0, vcc
821 ; CGP-NEXT: v_cmp_ne_u32_e32 vcc, 0, v15
822 ; CGP-NEXT: v_cndmask_b32_e32 v1, v13, v1, vcc
823 ; CGP-NEXT: v_cndmask_b32_e32 v0, v14, v0, vcc
824 ; CGP-NEXT: v_cmp_ne_u32_e32 vcc, 0, v9
825 ; CGP-NEXT: v_cndmask_b32_e32 v1, v10, v1, vcc
826 ; CGP-NEXT: v_cndmask_b32_e32 v0, v12, v0, vcc
827 ; CGP-NEXT: v_xor_b32_e32 v1, v1, v11
828 ; CGP-NEXT: v_xor_b32_e32 v5, v0, v11
829 ; CGP-NEXT: v_sub_i32_e32 v0, vcc, v1, v11
830 ; CGP-NEXT: v_subb_u32_e32 v1, vcc, v5, v11, vcc
831 ; CGP-NEXT: BB2_2: ; %Flow2
832 ; CGP-NEXT: s_or_saveexec_b64 s[4:5], s[6:7]
833 ; CGP-NEXT: s_xor_b64 exec, exec, s[4:5]
834 ; CGP-NEXT: s_cbranch_execz BB2_4
835 ; CGP-NEXT: ; %bb.3:
836 ; CGP-NEXT: v_cvt_f32_u32_e32 v0, v4
837 ; CGP-NEXT: v_sub_i32_e32 v1, vcc, 0, v4
838 ; CGP-NEXT: v_rcp_iflag_f32_e32 v0, v0
839 ; CGP-NEXT: v_mul_f32_e32 v0, 0x4f7ffffe, v0
840 ; CGP-NEXT: v_cvt_u32_f32_e32 v0, v0
841 ; CGP-NEXT: v_mul_lo_u32 v1, v1, v0
842 ; CGP-NEXT: v_mul_hi_u32 v1, v0, v1
843 ; CGP-NEXT: v_add_i32_e32 v0, vcc, v0, v1
844 ; CGP-NEXT: v_mul_hi_u32 v0, v8, v0
845 ; CGP-NEXT: v_mul_lo_u32 v0, v0, v4
846 ; CGP-NEXT: v_sub_i32_e32 v0, vcc, v8, v0
847 ; CGP-NEXT: v_sub_i32_e32 v1, vcc, v0, v4
848 ; CGP-NEXT: v_cmp_ge_u32_e32 vcc, v0, v4
849 ; CGP-NEXT: v_cndmask_b32_e32 v0, v0, v1, vcc
850 ; CGP-NEXT: v_sub_i32_e32 v1, vcc, v0, v4
851 ; CGP-NEXT: v_cmp_ge_u32_e32 vcc, v0, v4
852 ; CGP-NEXT: v_cndmask_b32_e32 v0, v0, v1, vcc
853 ; CGP-NEXT: v_mov_b32_e32 v1, 0
854 ; CGP-NEXT: BB2_4:
855 ; CGP-NEXT: s_or_b64 exec, exec, s[4:5]
856 ; CGP-NEXT: v_or_b32_e32 v5, v3, v7
857 ; CGP-NEXT: v_mov_b32_e32 v4, 0
858 ; CGP-NEXT: v_cmp_ne_u64_e32 vcc, 0, v[4:5]
859 ; CGP-NEXT: ; implicit-def: $vgpr4_vgpr5
860 ; CGP-NEXT: s_and_saveexec_b64 s[4:5], vcc
861 ; CGP-NEXT: s_xor_b64 s[6:7], exec, s[4:5]
862 ; CGP-NEXT: s_cbranch_execz BB2_6
863 ; CGP-NEXT: ; %bb.5:
864 ; CGP-NEXT: v_ashrrev_i32_e32 v4, 31, v7
865 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v6, v4
866 ; CGP-NEXT: v_addc_u32_e32 v7, vcc, v7, v4, vcc
867 ; CGP-NEXT: v_xor_b32_e32 v5, v5, v4
868 ; CGP-NEXT: v_xor_b32_e32 v4, v7, v4
869 ; CGP-NEXT: v_cvt_f32_u32_e32 v7, v5
870 ; CGP-NEXT: v_cvt_f32_u32_e32 v8, v4
871 ; CGP-NEXT: v_ashrrev_i32_e32 v9, 31, v3
872 ; CGP-NEXT: v_mac_f32_e32 v7, 0x4f800000, v8
873 ; CGP-NEXT: v_rcp_iflag_f32_e32 v7, v7
874 ; CGP-NEXT: v_add_i32_e32 v8, vcc, v2, v9
875 ; CGP-NEXT: v_addc_u32_e32 v3, vcc, v3, v9, vcc
876 ; CGP-NEXT: v_sub_i32_e32 v11, vcc, 0, v5
877 ; CGP-NEXT: v_mul_f32_e32 v7, 0x5f7ffffc, v7
878 ; CGP-NEXT: v_mul_f32_e32 v10, 0x2f800000, v7
879 ; CGP-NEXT: v_trunc_f32_e32 v10, v10
880 ; CGP-NEXT: v_mac_f32_e32 v7, 0xcf800000, v10
881 ; CGP-NEXT: v_cvt_u32_f32_e32 v7, v7
882 ; CGP-NEXT: v_cvt_u32_f32_e32 v10, v10
883 ; CGP-NEXT: v_subb_u32_e32 v12, vcc, 0, v4, vcc
884 ; CGP-NEXT: v_xor_b32_e32 v8, v8, v9
885 ; CGP-NEXT: v_mul_lo_u32 v13, v12, v7
886 ; CGP-NEXT: v_mul_lo_u32 v14, v11, v10
887 ; CGP-NEXT: v_mul_hi_u32 v16, v11, v7
888 ; CGP-NEXT: v_mul_lo_u32 v15, v11, v7
889 ; CGP-NEXT: v_xor_b32_e32 v3, v3, v9
890 ; CGP-NEXT: v_add_i32_e32 v13, vcc, v13, v14
891 ; CGP-NEXT: v_add_i32_e32 v13, vcc, v13, v16
892 ; CGP-NEXT: v_mul_lo_u32 v14, v10, v15
893 ; CGP-NEXT: v_mul_lo_u32 v16, v7, v13
894 ; CGP-NEXT: v_mul_hi_u32 v17, v7, v15
895 ; CGP-NEXT: v_mul_hi_u32 v15, v10, v15
896 ; CGP-NEXT: v_add_i32_e32 v14, vcc, v14, v16
897 ; CGP-NEXT: v_cndmask_b32_e64 v16, 0, 1, vcc
898 ; CGP-NEXT: v_add_i32_e32 v14, vcc, v14, v17
899 ; CGP-NEXT: v_cndmask_b32_e64 v14, 0, 1, vcc
900 ; CGP-NEXT: v_mul_lo_u32 v17, v10, v13
901 ; CGP-NEXT: v_add_i32_e32 v14, vcc, v16, v14
902 ; CGP-NEXT: v_mul_hi_u32 v16, v7, v13
903 ; CGP-NEXT: v_mul_hi_u32 v13, v10, v13
904 ; CGP-NEXT: v_add_i32_e32 v15, vcc, v17, v15
905 ; CGP-NEXT: v_cndmask_b32_e64 v17, 0, 1, vcc
906 ; CGP-NEXT: v_add_i32_e32 v15, vcc, v15, v16
907 ; CGP-NEXT: v_cndmask_b32_e64 v16, 0, 1, vcc
908 ; CGP-NEXT: v_add_i32_e32 v16, vcc, v17, v16
909 ; CGP-NEXT: v_add_i32_e32 v14, vcc, v15, v14
910 ; CGP-NEXT: v_cndmask_b32_e64 v15, 0, 1, vcc
911 ; CGP-NEXT: v_add_i32_e32 v15, vcc, v16, v15
912 ; CGP-NEXT: v_add_i32_e32 v13, vcc, v13, v15
913 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v7, v14
914 ; CGP-NEXT: v_addc_u32_e64 v14, s[4:5], v10, v13, vcc
915 ; CGP-NEXT: v_mul_lo_u32 v12, v12, v7
916 ; CGP-NEXT: v_mul_lo_u32 v15, v11, v14
917 ; CGP-NEXT: v_mul_lo_u32 v16, v11, v7
918 ; CGP-NEXT: v_mul_hi_u32 v11, v11, v7
919 ; CGP-NEXT: v_add_i32_e64 v10, s[4:5], v10, v13
920 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v12, v15
921 ; CGP-NEXT: v_mul_hi_u32 v13, v7, v16
922 ; CGP-NEXT: v_add_i32_e64 v11, s[4:5], v12, v11
923 ; CGP-NEXT: v_mul_lo_u32 v12, v14, v16
924 ; CGP-NEXT: v_mul_lo_u32 v15, v7, v11
925 ; CGP-NEXT: v_mul_hi_u32 v16, v14, v16
926 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v12, v15
927 ; CGP-NEXT: v_cndmask_b32_e64 v15, 0, 1, s[4:5]
928 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v12, v13
929 ; CGP-NEXT: v_cndmask_b32_e64 v12, 0, 1, s[4:5]
930 ; CGP-NEXT: v_mul_lo_u32 v13, v14, v11
931 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v15, v12
932 ; CGP-NEXT: v_mul_hi_u32 v15, v7, v11
933 ; CGP-NEXT: v_mul_hi_u32 v11, v14, v11
934 ; CGP-NEXT: v_add_i32_e64 v13, s[4:5], v13, v16
935 ; CGP-NEXT: v_cndmask_b32_e64 v16, 0, 1, s[4:5]
936 ; CGP-NEXT: v_add_i32_e64 v13, s[4:5], v13, v15
937 ; CGP-NEXT: v_cndmask_b32_e64 v15, 0, 1, s[4:5]
938 ; CGP-NEXT: v_add_i32_e64 v15, s[4:5], v16, v15
939 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v13, v12
940 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, 1, s[4:5]
941 ; CGP-NEXT: v_add_i32_e64 v13, s[4:5], v15, v13
942 ; CGP-NEXT: v_add_i32_e64 v11, s[4:5], v11, v13
943 ; CGP-NEXT: v_addc_u32_e32 v10, vcc, v10, v11, vcc
944 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v7, v12
945 ; CGP-NEXT: v_addc_u32_e32 v10, vcc, 0, v10, vcc
946 ; CGP-NEXT: v_mul_lo_u32 v11, v3, v7
947 ; CGP-NEXT: v_mul_lo_u32 v12, v8, v10
948 ; CGP-NEXT: v_mul_hi_u32 v13, v8, v7
949 ; CGP-NEXT: v_mul_hi_u32 v7, v3, v7
950 ; CGP-NEXT: v_add_i32_e32 v11, vcc, v11, v12
951 ; CGP-NEXT: v_cndmask_b32_e64 v12, 0, 1, vcc
952 ; CGP-NEXT: v_add_i32_e32 v11, vcc, v11, v13
953 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, 1, vcc
954 ; CGP-NEXT: v_mul_lo_u32 v13, v3, v10
955 ; CGP-NEXT: v_add_i32_e32 v11, vcc, v12, v11
956 ; CGP-NEXT: v_mul_hi_u32 v12, v8, v10
957 ; CGP-NEXT: v_mul_hi_u32 v10, v3, v10
958 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v13, v7
959 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, 1, vcc
960 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v7, v12
961 ; CGP-NEXT: v_cndmask_b32_e64 v12, 0, 1, vcc
962 ; CGP-NEXT: v_add_i32_e32 v12, vcc, v13, v12
963 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v7, v11
964 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, 1, vcc
965 ; CGP-NEXT: v_add_i32_e32 v11, vcc, v12, v11
966 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v10, v11
967 ; CGP-NEXT: v_mul_lo_u32 v11, v4, v7
968 ; CGP-NEXT: v_mul_lo_u32 v10, v5, v10
969 ; CGP-NEXT: v_mul_lo_u32 v12, v5, v7
970 ; CGP-NEXT: v_mul_hi_u32 v7, v5, v7
971 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v11, v10
972 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v10, v7
973 ; CGP-NEXT: v_sub_i32_e32 v8, vcc, v8, v12
974 ; CGP-NEXT: v_subb_u32_e64 v10, s[4:5], v3, v7, vcc
975 ; CGP-NEXT: v_sub_i32_e64 v3, s[4:5], v3, v7
976 ; CGP-NEXT: v_cmp_ge_u32_e64 s[4:5], v10, v4
977 ; CGP-NEXT: v_cndmask_b32_e64 v7, 0, -1, s[4:5]
978 ; CGP-NEXT: v_cmp_ge_u32_e64 s[4:5], v8, v5
979 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, -1, s[4:5]
980 ; CGP-NEXT: v_cmp_eq_u32_e64 s[4:5], v10, v4
981 ; CGP-NEXT: v_subb_u32_e32 v3, vcc, v3, v4, vcc
982 ; CGP-NEXT: v_cndmask_b32_e64 v7, v7, v11, s[4:5]
983 ; CGP-NEXT: v_sub_i32_e32 v11, vcc, v8, v5
984 ; CGP-NEXT: v_subbrev_u32_e64 v12, s[4:5], 0, v3, vcc
985 ; CGP-NEXT: v_cmp_ge_u32_e64 s[4:5], v12, v4
986 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, -1, s[4:5]
987 ; CGP-NEXT: v_cmp_ge_u32_e64 s[4:5], v11, v5
988 ; CGP-NEXT: v_subb_u32_e32 v3, vcc, v3, v4, vcc
989 ; CGP-NEXT: v_cndmask_b32_e64 v14, 0, -1, s[4:5]
990 ; CGP-NEXT: v_cmp_eq_u32_e64 s[4:5], v12, v4
991 ; CGP-NEXT: v_sub_i32_e32 v4, vcc, v11, v5
992 ; CGP-NEXT: v_cndmask_b32_e64 v13, v13, v14, s[4:5]
993 ; CGP-NEXT: v_subbrev_u32_e32 v3, vcc, 0, v3, vcc
994 ; CGP-NEXT: v_cmp_ne_u32_e32 vcc, 0, v13
995 ; CGP-NEXT: v_cndmask_b32_e32 v4, v11, v4, vcc
996 ; CGP-NEXT: v_cndmask_b32_e32 v3, v12, v3, vcc
997 ; CGP-NEXT: v_cmp_ne_u32_e32 vcc, 0, v7
998 ; CGP-NEXT: v_cndmask_b32_e32 v4, v8, v4, vcc
999 ; CGP-NEXT: v_cndmask_b32_e32 v3, v10, v3, vcc
1000 ; CGP-NEXT: v_xor_b32_e32 v4, v4, v9
1001 ; CGP-NEXT: v_xor_b32_e32 v3, v3, v9
1002 ; CGP-NEXT: v_sub_i32_e32 v4, vcc, v4, v9
1003 ; CGP-NEXT: v_subb_u32_e32 v5, vcc, v3, v9, vcc
1004 ; CGP-NEXT: BB2_6: ; %Flow
1005 ; CGP-NEXT: s_or_saveexec_b64 s[4:5], s[6:7]
1006 ; CGP-NEXT: s_xor_b64 exec, exec, s[4:5]
1007 ; CGP-NEXT: s_cbranch_execz BB2_8
1008 ; CGP-NEXT: ; %bb.7:
1009 ; CGP-NEXT: v_cvt_f32_u32_e32 v3, v6
1010 ; CGP-NEXT: v_sub_i32_e32 v4, vcc, 0, v6
1011 ; CGP-NEXT: v_mov_b32_e32 v5, 0
1012 ; CGP-NEXT: v_rcp_iflag_f32_e32 v3, v3
1013 ; CGP-NEXT: v_mul_f32_e32 v3, 0x4f7ffffe, v3
1014 ; CGP-NEXT: v_cvt_u32_f32_e32 v3, v3
1015 ; CGP-NEXT: v_mul_lo_u32 v4, v4, v3
1016 ; CGP-NEXT: v_mul_hi_u32 v4, v3, v4
1017 ; CGP-NEXT: v_add_i32_e32 v3, vcc, v3, v4
1018 ; CGP-NEXT: v_mul_hi_u32 v3, v2, v3
1019 ; CGP-NEXT: v_mul_lo_u32 v3, v3, v6
1020 ; CGP-NEXT: v_sub_i32_e32 v2, vcc, v2, v3
1021 ; CGP-NEXT: v_sub_i32_e32 v3, vcc, v2, v6
1022 ; CGP-NEXT: v_cmp_ge_u32_e32 vcc, v2, v6
1023 ; CGP-NEXT: v_cndmask_b32_e32 v2, v2, v3, vcc
1024 ; CGP-NEXT: v_sub_i32_e32 v3, vcc, v2, v6
1025 ; CGP-NEXT: v_cmp_ge_u32_e32 vcc, v2, v6
1026 ; CGP-NEXT: v_cndmask_b32_e32 v4, v2, v3, vcc
1027 ; CGP-NEXT: BB2_8:
1028 ; CGP-NEXT: s_or_b64 exec, exec, s[4:5]
1029 ; CGP-NEXT: v_mov_b32_e32 v2, v4
1030 ; CGP-NEXT: v_mov_b32_e32 v3, v5
1031 ; CGP-NEXT: s_setpc_b64 s[30:31]
1478 ; CGP-LABEL: v_srem_v2i64_pow2k_denom:
1479 ; CGP: ; %bb.0:
1480 ; CGP-NEXT: s_waitcnt vmcnt(0) expcnt(0) lgkmcnt(0)
1481 ; CGP-NEXT: v_cvt_f32_u32_e32 v4, 0x1000
1482 ; CGP-NEXT: v_cvt_f32_ubyte0_e32 v6, 0
1483 ; CGP-NEXT: s_movk_i32 s6, 0xf000
1484 ; CGP-NEXT: v_ashrrev_i32_e32 v5, 31, v1
1485 ; CGP-NEXT: v_mov_b32_e32 v7, v4
1486 ; CGP-NEXT: v_mac_f32_e32 v7, 0x4f800000, v6
1487 ; CGP-NEXT: v_rcp_iflag_f32_e32 v7, v7
1488 ; CGP-NEXT: v_add_i32_e32 v0, vcc, v0, v5
1489 ; CGP-NEXT: v_addc_u32_e32 v1, vcc, v1, v5, vcc
1490 ; CGP-NEXT: v_xor_b32_e32 v0, v0, v5
1491 ; CGP-NEXT: v_mul_f32_e32 v7, 0x5f7ffffc, v7
1492 ; CGP-NEXT: v_mul_f32_e32 v8, 0x2f800000, v7
1493 ; CGP-NEXT: v_trunc_f32_e32 v8, v8
1494 ; CGP-NEXT: v_mac_f32_e32 v7, 0xcf800000, v8
1495 ; CGP-NEXT: v_cvt_u32_f32_e32 v7, v7
1496 ; CGP-NEXT: v_cvt_u32_f32_e32 v8, v8
1497 ; CGP-NEXT: v_xor_b32_e32 v1, v1, v5
1498 ; CGP-NEXT: s_movk_i32 s7, 0x1000
1499 ; CGP-NEXT: v_mul_lo_u32 v9, -1, v7
1500 ; CGP-NEXT: v_mul_lo_u32 v10, s6, v8
1501 ; CGP-NEXT: v_mul_hi_u32 v12, s6, v7
1502 ; CGP-NEXT: v_mul_lo_u32 v11, s6, v7
1503 ; CGP-NEXT: v_mac_f32_e32 v4, 0x4f800000, v6
1504 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v9, v10
1505 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v9, v12
1506 ; CGP-NEXT: v_mul_lo_u32 v10, v8, v11
1507 ; CGP-NEXT: v_mul_lo_u32 v12, v7, v9
1508 ; CGP-NEXT: v_mul_hi_u32 v13, v7, v11
1509 ; CGP-NEXT: v_mul_hi_u32 v11, v8, v11
1510 ; CGP-NEXT: v_rcp_iflag_f32_e32 v4, v4
1511 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v10, v12
1512 ; CGP-NEXT: v_cndmask_b32_e64 v12, 0, 1, vcc
1513 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v10, v13
1514 ; CGP-NEXT: v_cndmask_b32_e64 v10, 0, 1, vcc
1515 ; CGP-NEXT: v_mul_lo_u32 v13, v8, v9
1516 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v12, v10
1517 ; CGP-NEXT: v_mul_hi_u32 v12, v7, v9
1518 ; CGP-NEXT: v_mul_hi_u32 v9, v8, v9
1519 ; CGP-NEXT: v_add_i32_e32 v11, vcc, v13, v11
1520 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, 1, vcc
1521 ; CGP-NEXT: v_add_i32_e32 v11, vcc, v11, v12
1522 ; CGP-NEXT: v_cndmask_b32_e64 v12, 0, 1, vcc
1523 ; CGP-NEXT: v_add_i32_e32 v12, vcc, v13, v12
1524 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v11, v10
1525 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, 1, vcc
1526 ; CGP-NEXT: v_add_i32_e32 v11, vcc, v12, v11
1527 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v9, v11
1528 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v7, v10
1529 ; CGP-NEXT: v_addc_u32_e64 v10, s[4:5], v8, v9, vcc
1530 ; CGP-NEXT: v_mul_lo_u32 v11, -1, v7
1531 ; CGP-NEXT: v_mul_lo_u32 v12, s6, v10
1532 ; CGP-NEXT: v_mul_hi_u32 v14, s6, v7
1533 ; CGP-NEXT: v_mul_lo_u32 v13, s6, v7
1534 ; CGP-NEXT: v_add_i32_e64 v8, s[4:5], v8, v9
1535 ; CGP-NEXT: v_add_i32_e64 v11, s[4:5], v11, v12
1536 ; CGP-NEXT: v_add_i32_e64 v11, s[4:5], v11, v14
1537 ; CGP-NEXT: v_mul_lo_u32 v12, v10, v13
1538 ; CGP-NEXT: v_mul_lo_u32 v14, v7, v11
1539 ; CGP-NEXT: v_mul_hi_u32 v9, v7, v13
1540 ; CGP-NEXT: v_mul_hi_u32 v13, v10, v13
1541 ; CGP-NEXT: v_mul_f32_e32 v4, 0x5f7ffffc, v4
1542 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v12, v14
1543 ; CGP-NEXT: v_cndmask_b32_e64 v14, 0, 1, s[4:5]
1544 ; CGP-NEXT: v_add_i32_e64 v9, s[4:5], v12, v9
1545 ; CGP-NEXT: v_cndmask_b32_e64 v9, 0, 1, s[4:5]
1546 ; CGP-NEXT: v_mul_lo_u32 v12, v10, v11
1547 ; CGP-NEXT: v_add_i32_e64 v9, s[4:5], v14, v9
1548 ; CGP-NEXT: v_mul_hi_u32 v14, v7, v11
1549 ; CGP-NEXT: v_mul_hi_u32 v10, v10, v11
1550 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v12, v13
1551 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, 1, s[4:5]
1552 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v12, v14
1553 ; CGP-NEXT: v_cndmask_b32_e64 v14, 0, 1, s[4:5]
1554 ; CGP-NEXT: v_add_i32_e64 v13, s[4:5], v13, v14
1555 ; CGP-NEXT: v_add_i32_e64 v9, s[4:5], v12, v9
1556 ; CGP-NEXT: v_cndmask_b32_e64 v12, 0, 1, s[4:5]
1557 ; CGP-NEXT: v_add_i32_e64 v11, s[4:5], v13, v12
1558 ; CGP-NEXT: v_add_i32_e64 v10, s[4:5], v10, v11
1559 ; CGP-NEXT: v_addc_u32_e32 v8, vcc, v8, v10, vcc
1560 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v7, v9
1561 ; CGP-NEXT: v_addc_u32_e32 v8, vcc, 0, v8, vcc
1562 ; CGP-NEXT: v_mul_lo_u32 v9, v1, v7
1563 ; CGP-NEXT: v_mul_lo_u32 v10, v0, v8
1564 ; CGP-NEXT: v_mul_hi_u32 v11, v0, v7
1565 ; CGP-NEXT: v_mul_hi_u32 v7, v1, v7
1566 ; CGP-NEXT: v_ashrrev_i32_e32 v6, 31, v3
1567 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v9, v10
1568 ; CGP-NEXT: v_cndmask_b32_e64 v10, 0, 1, vcc
1569 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v9, v11
1570 ; CGP-NEXT: v_cndmask_b32_e64 v9, 0, 1, vcc
1571 ; CGP-NEXT: v_mul_lo_u32 v11, v1, v8
1572 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v10, v9
1573 ; CGP-NEXT: v_mul_hi_u32 v10, v0, v8
1574 ; CGP-NEXT: v_mul_hi_u32 v8, v1, v8
1575 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v11, v7
1576 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, 1, vcc
1577 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v7, v10
1578 ; CGP-NEXT: v_cndmask_b32_e64 v10, 0, 1, vcc
1579 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v11, v10
1580 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v7, v9
1581 ; CGP-NEXT: v_cndmask_b32_e64 v9, 0, 1, vcc
1582 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v10, v9
1583 ; CGP-NEXT: v_add_i32_e32 v8, vcc, v8, v9
1584 ; CGP-NEXT: v_mul_lo_u32 v9, 0, v7
1585 ; CGP-NEXT: v_mul_lo_u32 v8, s7, v8
1586 ; CGP-NEXT: v_mul_lo_u32 v10, s7, v7
1587 ; CGP-NEXT: v_mul_hi_u32 v7, s7, v7
1588 ; CGP-NEXT: v_add_i32_e32 v8, vcc, v9, v8
1589 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v8, v7
1590 ; CGP-NEXT: v_sub_i32_e32 v0, vcc, v0, v10
1591 ; CGP-NEXT: v_subb_u32_e64 v8, s[4:5], v1, v7, vcc
1592 ; CGP-NEXT: v_sub_i32_e64 v1, s[4:5], v1, v7
1593 ; CGP-NEXT: v_cmp_le_u32_e64 s[4:5], 0, v8
1594 ; CGP-NEXT: v_cndmask_b32_e64 v7, 0, -1, s[4:5]
1595 ; CGP-NEXT: v_cmp_le_u32_e64 s[4:5], s7, v0
1596 ; CGP-NEXT: v_cndmask_b32_e64 v9, 0, -1, s[4:5]
1597 ; CGP-NEXT: v_cmp_eq_u32_e64 s[4:5], 0, v8
1598 ; CGP-NEXT: v_subbrev_u32_e32 v1, vcc, 0, v1, vcc
1599 ; CGP-NEXT: v_cndmask_b32_e64 v7, v7, v9, s[4:5]
1600 ; CGP-NEXT: v_subrev_i32_e32 v9, vcc, s7, v0
1601 ; CGP-NEXT: v_subbrev_u32_e32 v1, vcc, 0, v1, vcc
1602 ; CGP-NEXT: v_cmp_le_u32_e32 vcc, 0, v1
1603 ; CGP-NEXT: v_cndmask_b32_e64 v10, 0, -1, vcc
1604 ; CGP-NEXT: v_cmp_le_u32_e32 vcc, s7, v9
1605 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, -1, vcc
1606 ; CGP-NEXT: v_cmp_eq_u32_e32 vcc, 0, v1
1607 ; CGP-NEXT: v_cndmask_b32_e32 v10, v10, v11, vcc
1608 ; CGP-NEXT: v_subrev_i32_e32 v11, vcc, s7, v9
1609 ; CGP-NEXT: v_subbrev_u32_e32 v12, vcc, 0, v1, vcc
1610 ; CGP-NEXT: v_cmp_ne_u32_e32 vcc, 0, v10
1611 ; CGP-NEXT: v_cndmask_b32_e32 v9, v9, v11, vcc
1612 ; CGP-NEXT: v_cndmask_b32_e32 v1, v1, v12, vcc
1613 ; CGP-NEXT: v_cmp_ne_u32_e32 vcc, 0, v7
1614 ; CGP-NEXT: v_mul_f32_e32 v7, 0x2f800000, v4
1615 ; CGP-NEXT: v_trunc_f32_e32 v7, v7
1616 ; CGP-NEXT: v_mac_f32_e32 v4, 0xcf800000, v7
1617 ; CGP-NEXT: v_cvt_u32_f32_e32 v4, v4
1618 ; CGP-NEXT: v_cvt_u32_f32_e32 v7, v7
1619 ; CGP-NEXT: v_cndmask_b32_e32 v0, v0, v9, vcc
1620 ; CGP-NEXT: v_cndmask_b32_e32 v1, v8, v1, vcc
1621 ; CGP-NEXT: v_mul_lo_u32 v8, -1, v4
1622 ; CGP-NEXT: v_mul_lo_u32 v9, s6, v7
1623 ; CGP-NEXT: v_mul_hi_u32 v11, s6, v4
1624 ; CGP-NEXT: v_mul_lo_u32 v10, s6, v4
1625 ; CGP-NEXT: v_add_i32_e32 v2, vcc, v2, v6
1626 ; CGP-NEXT: v_addc_u32_e32 v3, vcc, v3, v6, vcc
1627 ; CGP-NEXT: v_add_i32_e32 v8, vcc, v8, v9
1628 ; CGP-NEXT: v_add_i32_e32 v8, vcc, v8, v11
1629 ; CGP-NEXT: v_mul_lo_u32 v9, v7, v10
1630 ; CGP-NEXT: v_mul_lo_u32 v11, v4, v8
1631 ; CGP-NEXT: v_mul_hi_u32 v12, v4, v10
1632 ; CGP-NEXT: v_mul_hi_u32 v10, v7, v10
1633 ; CGP-NEXT: v_xor_b32_e32 v0, v0, v5
1634 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v9, v11
1635 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, 1, vcc
1636 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v9, v12
1637 ; CGP-NEXT: v_cndmask_b32_e64 v9, 0, 1, vcc
1638 ; CGP-NEXT: v_mul_lo_u32 v12, v7, v8
1639 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v11, v9
1640 ; CGP-NEXT: v_mul_hi_u32 v11, v4, v8
1641 ; CGP-NEXT: v_mul_hi_u32 v8, v7, v8
1642 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v12, v10
1643 ; CGP-NEXT: v_cndmask_b32_e64 v12, 0, 1, vcc
1644 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v10, v11
1645 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, 1, vcc
1646 ; CGP-NEXT: v_add_i32_e32 v11, vcc, v12, v11
1647 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v10, v9
1648 ; CGP-NEXT: v_cndmask_b32_e64 v10, 0, 1, vcc
1649 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v11, v10
1650 ; CGP-NEXT: v_add_i32_e32 v8, vcc, v8, v10
1651 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v4, v9
1652 ; CGP-NEXT: v_addc_u32_e64 v9, s[4:5], v7, v8, vcc
1653 ; CGP-NEXT: v_mul_lo_u32 v10, -1, v4
1654 ; CGP-NEXT: v_mul_lo_u32 v11, s6, v9
1655 ; CGP-NEXT: v_mul_hi_u32 v13, s6, v4
1656 ; CGP-NEXT: v_mul_lo_u32 v12, s6, v4
1657 ; CGP-NEXT: v_add_i32_e64 v7, s[4:5], v7, v8
1658 ; CGP-NEXT: v_add_i32_e64 v10, s[4:5], v10, v11
1659 ; CGP-NEXT: v_add_i32_e64 v10, s[4:5], v10, v13
1660 ; CGP-NEXT: v_mul_lo_u32 v11, v9, v12
1661 ; CGP-NEXT: v_mul_lo_u32 v13, v4, v10
1662 ; CGP-NEXT: v_mul_hi_u32 v8, v4, v12
1663 ; CGP-NEXT: v_mul_hi_u32 v12, v9, v12
1664 ; CGP-NEXT: v_xor_b32_e32 v2, v2, v6
1665 ; CGP-NEXT: v_add_i32_e64 v11, s[4:5], v11, v13
1666 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, 1, s[4:5]
1667 ; CGP-NEXT: v_add_i32_e64 v8, s[4:5], v11, v8
1668 ; CGP-NEXT: v_cndmask_b32_e64 v8, 0, 1, s[4:5]
1669 ; CGP-NEXT: v_mul_lo_u32 v11, v9, v10
1670 ; CGP-NEXT: v_add_i32_e64 v8, s[4:5], v13, v8
1671 ; CGP-NEXT: v_mul_hi_u32 v13, v4, v10
1672 ; CGP-NEXT: v_mul_hi_u32 v9, v9, v10
1673 ; CGP-NEXT: v_add_i32_e64 v11, s[4:5], v11, v12
1674 ; CGP-NEXT: v_cndmask_b32_e64 v12, 0, 1, s[4:5]
1675 ; CGP-NEXT: v_add_i32_e64 v11, s[4:5], v11, v13
1676 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, 1, s[4:5]
1677 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v12, v13
1678 ; CGP-NEXT: v_add_i32_e64 v8, s[4:5], v11, v8
1679 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, 1, s[4:5]
1680 ; CGP-NEXT: v_add_i32_e64 v10, s[4:5], v12, v11
1681 ; CGP-NEXT: v_add_i32_e64 v9, s[4:5], v9, v10
1682 ; CGP-NEXT: v_addc_u32_e32 v7, vcc, v7, v9, vcc
1683 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v4, v8
1684 ; CGP-NEXT: v_addc_u32_e32 v7, vcc, 0, v7, vcc
1685 ; CGP-NEXT: v_xor_b32_e32 v3, v3, v6
1686 ; CGP-NEXT: v_xor_b32_e32 v1, v1, v5
1687 ; CGP-NEXT: v_sub_i32_e32 v0, vcc, v0, v5
1688 ; CGP-NEXT: v_mul_lo_u32 v8, v3, v4
1689 ; CGP-NEXT: v_mul_lo_u32 v9, v2, v7
1690 ; CGP-NEXT: v_subb_u32_e32 v1, vcc, v1, v5, vcc
1691 ; CGP-NEXT: v_mul_hi_u32 v5, v2, v4
1692 ; CGP-NEXT: v_mul_hi_u32 v4, v3, v4
1693 ; CGP-NEXT: v_add_i32_e32 v8, vcc, v8, v9
1694 ; CGP-NEXT: v_cndmask_b32_e64 v9, 0, 1, vcc
1695 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v8, v5
1696 ; CGP-NEXT: v_cndmask_b32_e64 v5, 0, 1, vcc
1697 ; CGP-NEXT: v_mul_lo_u32 v8, v3, v7
1698 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v9, v5
1699 ; CGP-NEXT: v_mul_hi_u32 v9, v2, v7
1700 ; CGP-NEXT: v_mul_hi_u32 v7, v3, v7
1701 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v8, v4
1702 ; CGP-NEXT: v_cndmask_b32_e64 v8, 0, 1, vcc
1703 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v4, v9
1704 ; CGP-NEXT: v_cndmask_b32_e64 v9, 0, 1, vcc
1705 ; CGP-NEXT: v_add_i32_e32 v8, vcc, v8, v9
1706 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v4, v5
1707 ; CGP-NEXT: v_cndmask_b32_e64 v5, 0, 1, vcc
1708 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v8, v5
1709 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v7, v5
1710 ; CGP-NEXT: v_mul_lo_u32 v7, 0, v4
1711 ; CGP-NEXT: v_mul_lo_u32 v5, s7, v5
1712 ; CGP-NEXT: v_mul_lo_u32 v8, s7, v4
1713 ; CGP-NEXT: v_mul_hi_u32 v4, s7, v4
1714 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v7, v5
1715 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v5, v4
1716 ; CGP-NEXT: v_sub_i32_e32 v2, vcc, v2, v8
1717 ; CGP-NEXT: v_subb_u32_e64 v5, s[4:5], v3, v4, vcc
1718 ; CGP-NEXT: v_sub_i32_e64 v3, s[4:5], v3, v4
1719 ; CGP-NEXT: v_cmp_le_u32_e64 s[4:5], 0, v5
1720 ; CGP-NEXT: v_cndmask_b32_e64 v4, 0, -1, s[4:5]
1721 ; CGP-NEXT: v_cmp_le_u32_e64 s[4:5], s7, v2
1722 ; CGP-NEXT: v_cndmask_b32_e64 v7, 0, -1, s[4:5]
1723 ; CGP-NEXT: v_cmp_eq_u32_e64 s[4:5], 0, v5
1724 ; CGP-NEXT: v_subbrev_u32_e32 v3, vcc, 0, v3, vcc
1725 ; CGP-NEXT: v_cndmask_b32_e64 v4, v4, v7, s[4:5]
1726 ; CGP-NEXT: v_subrev_i32_e32 v7, vcc, s7, v2
1727 ; CGP-NEXT: v_subbrev_u32_e32 v3, vcc, 0, v3, vcc
1728 ; CGP-NEXT: v_cmp_le_u32_e32 vcc, 0, v3
1729 ; CGP-NEXT: v_cndmask_b32_e64 v8, 0, -1, vcc
1730 ; CGP-NEXT: v_cmp_le_u32_e32 vcc, s7, v7
1731 ; CGP-NEXT: v_cndmask_b32_e64 v9, 0, -1, vcc
1732 ; CGP-NEXT: v_cmp_eq_u32_e32 vcc, 0, v3
1733 ; CGP-NEXT: v_cndmask_b32_e32 v8, v8, v9, vcc
1734 ; CGP-NEXT: v_subrev_i32_e32 v9, vcc, s7, v7
1735 ; CGP-NEXT: v_subbrev_u32_e32 v10, vcc, 0, v3, vcc
1736 ; CGP-NEXT: v_cmp_ne_u32_e32 vcc, 0, v8
1737 ; CGP-NEXT: v_cndmask_b32_e32 v7, v7, v9, vcc
1738 ; CGP-NEXT: v_cndmask_b32_e32 v3, v3, v10, vcc
1739 ; CGP-NEXT: v_cmp_ne_u32_e32 vcc, 0, v4
1740 ; CGP-NEXT: v_cndmask_b32_e32 v2, v2, v7, vcc
1741 ; CGP-NEXT: v_cndmask_b32_e32 v3, v5, v3, vcc
1742 ; CGP-NEXT: v_xor_b32_e32 v2, v2, v6
1743 ; CGP-NEXT: v_xor_b32_e32 v3, v3, v6
1744 ; CGP-NEXT: v_sub_i32_e32 v2, vcc, v2, v6
1745 ; CGP-NEXT: v_subb_u32_e32 v3, vcc, v3, v6, vcc
1746 ; CGP-NEXT: s_setpc_b64 s[30:31]
2193 ; CGP-LABEL: v_srem_v2i64_oddk_denom:
2194 ; CGP: ; %bb.0:
2195 ; CGP-NEXT: s_waitcnt vmcnt(0) expcnt(0) lgkmcnt(0)
2196 ; CGP-NEXT: v_cvt_f32_u32_e32 v4, 0x12d8fb
2197 ; CGP-NEXT: v_cvt_f32_ubyte0_e32 v6, 0
2198 ; CGP-NEXT: s_mov_b32 s6, 0xffed2705
2199 ; CGP-NEXT: v_ashrrev_i32_e32 v5, 31, v1
2200 ; CGP-NEXT: v_mov_b32_e32 v7, v4
2201 ; CGP-NEXT: v_mac_f32_e32 v7, 0x4f800000, v6
2202 ; CGP-NEXT: v_rcp_iflag_f32_e32 v7, v7
2203 ; CGP-NEXT: v_add_i32_e32 v0, vcc, v0, v5
2204 ; CGP-NEXT: v_addc_u32_e32 v1, vcc, v1, v5, vcc
2205 ; CGP-NEXT: v_xor_b32_e32 v0, v0, v5
2206 ; CGP-NEXT: v_mul_f32_e32 v7, 0x5f7ffffc, v7
2207 ; CGP-NEXT: v_mul_f32_e32 v8, 0x2f800000, v7
2208 ; CGP-NEXT: v_trunc_f32_e32 v8, v8
2209 ; CGP-NEXT: v_mac_f32_e32 v7, 0xcf800000, v8
2210 ; CGP-NEXT: v_cvt_u32_f32_e32 v7, v7
2211 ; CGP-NEXT: v_cvt_u32_f32_e32 v8, v8
2212 ; CGP-NEXT: v_xor_b32_e32 v1, v1, v5
2213 ; CGP-NEXT: s_mov_b32 s7, 0x12d8fb
2214 ; CGP-NEXT: v_mul_lo_u32 v9, -1, v7
2215 ; CGP-NEXT: v_mul_lo_u32 v10, s6, v8
2216 ; CGP-NEXT: v_mul_hi_u32 v12, s6, v7
2217 ; CGP-NEXT: v_mul_lo_u32 v11, s6, v7
2218 ; CGP-NEXT: v_mac_f32_e32 v4, 0x4f800000, v6
2219 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v9, v10
2220 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v9, v12
2221 ; CGP-NEXT: v_mul_lo_u32 v10, v8, v11
2222 ; CGP-NEXT: v_mul_lo_u32 v12, v7, v9
2223 ; CGP-NEXT: v_mul_hi_u32 v13, v7, v11
2224 ; CGP-NEXT: v_mul_hi_u32 v11, v8, v11
2225 ; CGP-NEXT: v_rcp_iflag_f32_e32 v4, v4
2226 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v10, v12
2227 ; CGP-NEXT: v_cndmask_b32_e64 v12, 0, 1, vcc
2228 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v10, v13
2229 ; CGP-NEXT: v_cndmask_b32_e64 v10, 0, 1, vcc
2230 ; CGP-NEXT: v_mul_lo_u32 v13, v8, v9
2231 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v12, v10
2232 ; CGP-NEXT: v_mul_hi_u32 v12, v7, v9
2233 ; CGP-NEXT: v_mul_hi_u32 v9, v8, v9
2234 ; CGP-NEXT: v_add_i32_e32 v11, vcc, v13, v11
2235 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, 1, vcc
2236 ; CGP-NEXT: v_add_i32_e32 v11, vcc, v11, v12
2237 ; CGP-NEXT: v_cndmask_b32_e64 v12, 0, 1, vcc
2238 ; CGP-NEXT: v_add_i32_e32 v12, vcc, v13, v12
2239 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v11, v10
2240 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, 1, vcc
2241 ; CGP-NEXT: v_add_i32_e32 v11, vcc, v12, v11
2242 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v9, v11
2243 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v7, v10
2244 ; CGP-NEXT: v_addc_u32_e64 v10, s[4:5], v8, v9, vcc
2245 ; CGP-NEXT: v_mul_lo_u32 v11, -1, v7
2246 ; CGP-NEXT: v_mul_lo_u32 v12, s6, v10
2247 ; CGP-NEXT: v_mul_hi_u32 v14, s6, v7
2248 ; CGP-NEXT: v_mul_lo_u32 v13, s6, v7
2249 ; CGP-NEXT: v_add_i32_e64 v8, s[4:5], v8, v9
2250 ; CGP-NEXT: v_add_i32_e64 v11, s[4:5], v11, v12
2251 ; CGP-NEXT: v_add_i32_e64 v11, s[4:5], v11, v14
2252 ; CGP-NEXT: v_mul_lo_u32 v12, v10, v13
2253 ; CGP-NEXT: v_mul_lo_u32 v14, v7, v11
2254 ; CGP-NEXT: v_mul_hi_u32 v9, v7, v13
2255 ; CGP-NEXT: v_mul_hi_u32 v13, v10, v13
2256 ; CGP-NEXT: v_mul_f32_e32 v4, 0x5f7ffffc, v4
2257 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v12, v14
2258 ; CGP-NEXT: v_cndmask_b32_e64 v14, 0, 1, s[4:5]
2259 ; CGP-NEXT: v_add_i32_e64 v9, s[4:5], v12, v9
2260 ; CGP-NEXT: v_cndmask_b32_e64 v9, 0, 1, s[4:5]
2261 ; CGP-NEXT: v_mul_lo_u32 v12, v10, v11
2262 ; CGP-NEXT: v_add_i32_e64 v9, s[4:5], v14, v9
2263 ; CGP-NEXT: v_mul_hi_u32 v14, v7, v11
2264 ; CGP-NEXT: v_mul_hi_u32 v10, v10, v11
2265 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v12, v13
2266 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, 1, s[4:5]
2267 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v12, v14
2268 ; CGP-NEXT: v_cndmask_b32_e64 v14, 0, 1, s[4:5]
2269 ; CGP-NEXT: v_add_i32_e64 v13, s[4:5], v13, v14
2270 ; CGP-NEXT: v_add_i32_e64 v9, s[4:5], v12, v9
2271 ; CGP-NEXT: v_cndmask_b32_e64 v12, 0, 1, s[4:5]
2272 ; CGP-NEXT: v_add_i32_e64 v11, s[4:5], v13, v12
2273 ; CGP-NEXT: v_add_i32_e64 v10, s[4:5], v10, v11
2274 ; CGP-NEXT: v_addc_u32_e32 v8, vcc, v8, v10, vcc
2275 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v7, v9
2276 ; CGP-NEXT: v_addc_u32_e32 v8, vcc, 0, v8, vcc
2277 ; CGP-NEXT: v_mul_lo_u32 v9, v1, v7
2278 ; CGP-NEXT: v_mul_lo_u32 v10, v0, v8
2279 ; CGP-NEXT: v_mul_hi_u32 v11, v0, v7
2280 ; CGP-NEXT: v_mul_hi_u32 v7, v1, v7
2281 ; CGP-NEXT: v_ashrrev_i32_e32 v6, 31, v3
2282 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v9, v10
2283 ; CGP-NEXT: v_cndmask_b32_e64 v10, 0, 1, vcc
2284 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v9, v11
2285 ; CGP-NEXT: v_cndmask_b32_e64 v9, 0, 1, vcc
2286 ; CGP-NEXT: v_mul_lo_u32 v11, v1, v8
2287 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v10, v9
2288 ; CGP-NEXT: v_mul_hi_u32 v10, v0, v8
2289 ; CGP-NEXT: v_mul_hi_u32 v8, v1, v8
2290 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v11, v7
2291 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, 1, vcc
2292 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v7, v10
2293 ; CGP-NEXT: v_cndmask_b32_e64 v10, 0, 1, vcc
2294 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v11, v10
2295 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v7, v9
2296 ; CGP-NEXT: v_cndmask_b32_e64 v9, 0, 1, vcc
2297 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v10, v9
2298 ; CGP-NEXT: v_add_i32_e32 v8, vcc, v8, v9
2299 ; CGP-NEXT: v_mul_lo_u32 v9, 0, v7
2300 ; CGP-NEXT: v_mul_lo_u32 v8, s7, v8
2301 ; CGP-NEXT: v_mul_lo_u32 v10, s7, v7
2302 ; CGP-NEXT: v_mul_hi_u32 v7, s7, v7
2303 ; CGP-NEXT: v_add_i32_e32 v8, vcc, v9, v8
2304 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v8, v7
2305 ; CGP-NEXT: v_sub_i32_e32 v0, vcc, v0, v10
2306 ; CGP-NEXT: v_subb_u32_e64 v8, s[4:5], v1, v7, vcc
2307 ; CGP-NEXT: v_sub_i32_e64 v1, s[4:5], v1, v7
2308 ; CGP-NEXT: v_cmp_le_u32_e64 s[4:5], 0, v8
2309 ; CGP-NEXT: v_cndmask_b32_e64 v7, 0, -1, s[4:5]
2310 ; CGP-NEXT: v_cmp_le_u32_e64 s[4:5], s7, v0
2311 ; CGP-NEXT: v_cndmask_b32_e64 v9, 0, -1, s[4:5]
2312 ; CGP-NEXT: v_cmp_eq_u32_e64 s[4:5], 0, v8
2313 ; CGP-NEXT: v_subbrev_u32_e32 v1, vcc, 0, v1, vcc
2314 ; CGP-NEXT: v_cndmask_b32_e64 v7, v7, v9, s[4:5]
2315 ; CGP-NEXT: v_subrev_i32_e32 v9, vcc, s7, v0
2316 ; CGP-NEXT: v_subbrev_u32_e32 v1, vcc, 0, v1, vcc
2317 ; CGP-NEXT: v_cmp_le_u32_e32 vcc, 0, v1
2318 ; CGP-NEXT: v_cndmask_b32_e64 v10, 0, -1, vcc
2319 ; CGP-NEXT: v_cmp_le_u32_e32 vcc, s7, v9
2320 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, -1, vcc
2321 ; CGP-NEXT: v_cmp_eq_u32_e32 vcc, 0, v1
2322 ; CGP-NEXT: v_cndmask_b32_e32 v10, v10, v11, vcc
2323 ; CGP-NEXT: v_subrev_i32_e32 v11, vcc, s7, v9
2324 ; CGP-NEXT: v_subbrev_u32_e32 v12, vcc, 0, v1, vcc
2325 ; CGP-NEXT: v_cmp_ne_u32_e32 vcc, 0, v10
2326 ; CGP-NEXT: v_cndmask_b32_e32 v9, v9, v11, vcc
2327 ; CGP-NEXT: v_cndmask_b32_e32 v1, v1, v12, vcc
2328 ; CGP-NEXT: v_cmp_ne_u32_e32 vcc, 0, v7
2329 ; CGP-NEXT: v_mul_f32_e32 v7, 0x2f800000, v4
2330 ; CGP-NEXT: v_trunc_f32_e32 v7, v7
2331 ; CGP-NEXT: v_mac_f32_e32 v4, 0xcf800000, v7
2332 ; CGP-NEXT: v_cvt_u32_f32_e32 v4, v4
2333 ; CGP-NEXT: v_cvt_u32_f32_e32 v7, v7
2334 ; CGP-NEXT: v_cndmask_b32_e32 v0, v0, v9, vcc
2335 ; CGP-NEXT: v_cndmask_b32_e32 v1, v8, v1, vcc
2336 ; CGP-NEXT: v_mul_lo_u32 v8, -1, v4
2337 ; CGP-NEXT: v_mul_lo_u32 v9, s6, v7
2338 ; CGP-NEXT: v_mul_hi_u32 v11, s6, v4
2339 ; CGP-NEXT: v_mul_lo_u32 v10, s6, v4
2340 ; CGP-NEXT: v_add_i32_e32 v2, vcc, v2, v6
2341 ; CGP-NEXT: v_addc_u32_e32 v3, vcc, v3, v6, vcc
2342 ; CGP-NEXT: v_add_i32_e32 v8, vcc, v8, v9
2343 ; CGP-NEXT: v_add_i32_e32 v8, vcc, v8, v11
2344 ; CGP-NEXT: v_mul_lo_u32 v9, v7, v10
2345 ; CGP-NEXT: v_mul_lo_u32 v11, v4, v8
2346 ; CGP-NEXT: v_mul_hi_u32 v12, v4, v10
2347 ; CGP-NEXT: v_mul_hi_u32 v10, v7, v10
2348 ; CGP-NEXT: v_xor_b32_e32 v0, v0, v5
2349 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v9, v11
2350 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, 1, vcc
2351 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v9, v12
2352 ; CGP-NEXT: v_cndmask_b32_e64 v9, 0, 1, vcc
2353 ; CGP-NEXT: v_mul_lo_u32 v12, v7, v8
2354 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v11, v9
2355 ; CGP-NEXT: v_mul_hi_u32 v11, v4, v8
2356 ; CGP-NEXT: v_mul_hi_u32 v8, v7, v8
2357 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v12, v10
2358 ; CGP-NEXT: v_cndmask_b32_e64 v12, 0, 1, vcc
2359 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v10, v11
2360 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, 1, vcc
2361 ; CGP-NEXT: v_add_i32_e32 v11, vcc, v12, v11
2362 ; CGP-NEXT: v_add_i32_e32 v9, vcc, v10, v9
2363 ; CGP-NEXT: v_cndmask_b32_e64 v10, 0, 1, vcc
2364 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v11, v10
2365 ; CGP-NEXT: v_add_i32_e32 v8, vcc, v8, v10
2366 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v4, v9
2367 ; CGP-NEXT: v_addc_u32_e64 v9, s[4:5], v7, v8, vcc
2368 ; CGP-NEXT: v_mul_lo_u32 v10, -1, v4
2369 ; CGP-NEXT: v_mul_lo_u32 v11, s6, v9
2370 ; CGP-NEXT: v_mul_hi_u32 v13, s6, v4
2371 ; CGP-NEXT: v_mul_lo_u32 v12, s6, v4
2372 ; CGP-NEXT: v_add_i32_e64 v7, s[4:5], v7, v8
2373 ; CGP-NEXT: v_add_i32_e64 v10, s[4:5], v10, v11
2374 ; CGP-NEXT: v_add_i32_e64 v10, s[4:5], v10, v13
2375 ; CGP-NEXT: v_mul_lo_u32 v11, v9, v12
2376 ; CGP-NEXT: v_mul_lo_u32 v13, v4, v10
2377 ; CGP-NEXT: v_mul_hi_u32 v8, v4, v12
2378 ; CGP-NEXT: v_mul_hi_u32 v12, v9, v12
2379 ; CGP-NEXT: v_xor_b32_e32 v2, v2, v6
2380 ; CGP-NEXT: v_add_i32_e64 v11, s[4:5], v11, v13
2381 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, 1, s[4:5]
2382 ; CGP-NEXT: v_add_i32_e64 v8, s[4:5], v11, v8
2383 ; CGP-NEXT: v_cndmask_b32_e64 v8, 0, 1, s[4:5]
2384 ; CGP-NEXT: v_mul_lo_u32 v11, v9, v10
2385 ; CGP-NEXT: v_add_i32_e64 v8, s[4:5], v13, v8
2386 ; CGP-NEXT: v_mul_hi_u32 v13, v4, v10
2387 ; CGP-NEXT: v_mul_hi_u32 v9, v9, v10
2388 ; CGP-NEXT: v_add_i32_e64 v11, s[4:5], v11, v12
2389 ; CGP-NEXT: v_cndmask_b32_e64 v12, 0, 1, s[4:5]
2390 ; CGP-NEXT: v_add_i32_e64 v11, s[4:5], v11, v13
2391 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, 1, s[4:5]
2392 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v12, v13
2393 ; CGP-NEXT: v_add_i32_e64 v8, s[4:5], v11, v8
2394 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, 1, s[4:5]
2395 ; CGP-NEXT: v_add_i32_e64 v10, s[4:5], v12, v11
2396 ; CGP-NEXT: v_add_i32_e64 v9, s[4:5], v9, v10
2397 ; CGP-NEXT: v_addc_u32_e32 v7, vcc, v7, v9, vcc
2398 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v4, v8
2399 ; CGP-NEXT: v_addc_u32_e32 v7, vcc, 0, v7, vcc
2400 ; CGP-NEXT: v_xor_b32_e32 v3, v3, v6
2401 ; CGP-NEXT: v_xor_b32_e32 v1, v1, v5
2402 ; CGP-NEXT: v_sub_i32_e32 v0, vcc, v0, v5
2403 ; CGP-NEXT: v_mul_lo_u32 v8, v3, v4
2404 ; CGP-NEXT: v_mul_lo_u32 v9, v2, v7
2405 ; CGP-NEXT: v_subb_u32_e32 v1, vcc, v1, v5, vcc
2406 ; CGP-NEXT: v_mul_hi_u32 v5, v2, v4
2407 ; CGP-NEXT: v_mul_hi_u32 v4, v3, v4
2408 ; CGP-NEXT: v_add_i32_e32 v8, vcc, v8, v9
2409 ; CGP-NEXT: v_cndmask_b32_e64 v9, 0, 1, vcc
2410 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v8, v5
2411 ; CGP-NEXT: v_cndmask_b32_e64 v5, 0, 1, vcc
2412 ; CGP-NEXT: v_mul_lo_u32 v8, v3, v7
2413 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v9, v5
2414 ; CGP-NEXT: v_mul_hi_u32 v9, v2, v7
2415 ; CGP-NEXT: v_mul_hi_u32 v7, v3, v7
2416 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v8, v4
2417 ; CGP-NEXT: v_cndmask_b32_e64 v8, 0, 1, vcc
2418 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v4, v9
2419 ; CGP-NEXT: v_cndmask_b32_e64 v9, 0, 1, vcc
2420 ; CGP-NEXT: v_add_i32_e32 v8, vcc, v8, v9
2421 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v4, v5
2422 ; CGP-NEXT: v_cndmask_b32_e64 v5, 0, 1, vcc
2423 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v8, v5
2424 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v7, v5
2425 ; CGP-NEXT: v_mul_lo_u32 v7, 0, v4
2426 ; CGP-NEXT: v_mul_lo_u32 v5, s7, v5
2427 ; CGP-NEXT: v_mul_lo_u32 v8, s7, v4
2428 ; CGP-NEXT: v_mul_hi_u32 v4, s7, v4
2429 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v7, v5
2430 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v5, v4
2431 ; CGP-NEXT: v_sub_i32_e32 v2, vcc, v2, v8
2432 ; CGP-NEXT: v_subb_u32_e64 v5, s[4:5], v3, v4, vcc
2433 ; CGP-NEXT: v_sub_i32_e64 v3, s[4:5], v3, v4
2434 ; CGP-NEXT: v_cmp_le_u32_e64 s[4:5], 0, v5
2435 ; CGP-NEXT: v_cndmask_b32_e64 v4, 0, -1, s[4:5]
2436 ; CGP-NEXT: v_cmp_le_u32_e64 s[4:5], s7, v2
2437 ; CGP-NEXT: v_cndmask_b32_e64 v7, 0, -1, s[4:5]
2438 ; CGP-NEXT: v_cmp_eq_u32_e64 s[4:5], 0, v5
2439 ; CGP-NEXT: v_subbrev_u32_e32 v3, vcc, 0, v3, vcc
2440 ; CGP-NEXT: v_cndmask_b32_e64 v4, v4, v7, s[4:5]
2441 ; CGP-NEXT: v_subrev_i32_e32 v7, vcc, s7, v2
2442 ; CGP-NEXT: v_subbrev_u32_e32 v3, vcc, 0, v3, vcc
2443 ; CGP-NEXT: v_cmp_le_u32_e32 vcc, 0, v3
2444 ; CGP-NEXT: v_cndmask_b32_e64 v8, 0, -1, vcc
2445 ; CGP-NEXT: v_cmp_le_u32_e32 vcc, s7, v7
2446 ; CGP-NEXT: v_cndmask_b32_e64 v9, 0, -1, vcc
2447 ; CGP-NEXT: v_cmp_eq_u32_e32 vcc, 0, v3
2448 ; CGP-NEXT: v_cndmask_b32_e32 v8, v8, v9, vcc
2449 ; CGP-NEXT: v_subrev_i32_e32 v9, vcc, s7, v7
2450 ; CGP-NEXT: v_subbrev_u32_e32 v10, vcc, 0, v3, vcc
2451 ; CGP-NEXT: v_cmp_ne_u32_e32 vcc, 0, v8
2452 ; CGP-NEXT: v_cndmask_b32_e32 v7, v7, v9, vcc
2453 ; CGP-NEXT: v_cndmask_b32_e32 v3, v3, v10, vcc
2454 ; CGP-NEXT: v_cmp_ne_u32_e32 vcc, 0, v4
2455 ; CGP-NEXT: v_cndmask_b32_e32 v2, v2, v7, vcc
2456 ; CGP-NEXT: v_cndmask_b32_e32 v3, v5, v3, vcc
2457 ; CGP-NEXT: v_xor_b32_e32 v2, v2, v6
2458 ; CGP-NEXT: v_xor_b32_e32 v3, v3, v6
2459 ; CGP-NEXT: v_sub_i32_e32 v2, vcc, v2, v6
2460 ; CGP-NEXT: v_subb_u32_e32 v3, vcc, v3, v6, vcc
2461 ; CGP-NEXT: s_setpc_b64 s[30:31]
2944 ; CGP-LABEL: v_srem_v2i64_pow2_shl_denom:
2945 ; CGP: ; %bb.0:
2946 ; CGP-NEXT: s_waitcnt vmcnt(0) expcnt(0) lgkmcnt(0)
2947 ; CGP-NEXT: s_movk_i32 s4, 0x1000
2948 ; CGP-NEXT: s_mov_b32 s5, 0
2949 ; CGP-NEXT: v_lshl_b64 v[10:11], s[4:5], v4
2950 ; CGP-NEXT: v_mov_b32_e32 v7, v1
2951 ; CGP-NEXT: v_mov_b32_e32 v5, v0
2952 ; CGP-NEXT: v_or_b32_e32 v1, v7, v11
2953 ; CGP-NEXT: v_mov_b32_e32 v0, 0
2954 ; CGP-NEXT: v_cmp_ne_u64_e32 vcc, 0, v[0:1]
2955 ; CGP-NEXT: v_lshl_b64 v[8:9], s[4:5], v6
2956 ; CGP-NEXT: ; implicit-def: $vgpr0_vgpr1
2957 ; CGP-NEXT: s_and_saveexec_b64 s[4:5], vcc
2958 ; CGP-NEXT: s_xor_b64 s[6:7], exec, s[4:5]
2959 ; CGP-NEXT: s_cbranch_execz BB8_2
2960 ; CGP-NEXT: ; %bb.1:
2961 ; CGP-NEXT: v_ashrrev_i32_e32 v0, 31, v11
2962 ; CGP-NEXT: v_add_i32_e32 v1, vcc, v10, v0
2963 ; CGP-NEXT: v_addc_u32_e32 v4, vcc, v11, v0, vcc
2964 ; CGP-NEXT: v_xor_b32_e32 v1, v1, v0
2965 ; CGP-NEXT: v_xor_b32_e32 v0, v4, v0
2966 ; CGP-NEXT: v_cvt_f32_u32_e32 v4, v1
2967 ; CGP-NEXT: v_cvt_f32_u32_e32 v6, v0
2968 ; CGP-NEXT: v_ashrrev_i32_e32 v11, 31, v7
2969 ; CGP-NEXT: v_mac_f32_e32 v4, 0x4f800000, v6
2970 ; CGP-NEXT: v_rcp_iflag_f32_e32 v4, v4
2971 ; CGP-NEXT: v_add_i32_e32 v6, vcc, v5, v11
2972 ; CGP-NEXT: v_addc_u32_e32 v7, vcc, v7, v11, vcc
2973 ; CGP-NEXT: v_sub_i32_e32 v13, vcc, 0, v1
2974 ; CGP-NEXT: v_mul_f32_e32 v4, 0x5f7ffffc, v4
2975 ; CGP-NEXT: v_mul_f32_e32 v12, 0x2f800000, v4
2976 ; CGP-NEXT: v_trunc_f32_e32 v12, v12
2977 ; CGP-NEXT: v_mac_f32_e32 v4, 0xcf800000, v12
2978 ; CGP-NEXT: v_cvt_u32_f32_e32 v4, v4
2979 ; CGP-NEXT: v_cvt_u32_f32_e32 v12, v12
2980 ; CGP-NEXT: v_subb_u32_e32 v14, vcc, 0, v0, vcc
2981 ; CGP-NEXT: v_xor_b32_e32 v6, v6, v11
2982 ; CGP-NEXT: v_mul_lo_u32 v15, v14, v4
2983 ; CGP-NEXT: v_mul_lo_u32 v16, v13, v12
2984 ; CGP-NEXT: v_mul_hi_u32 v18, v13, v4
2985 ; CGP-NEXT: v_mul_lo_u32 v17, v13, v4
2986 ; CGP-NEXT: v_xor_b32_e32 v7, v7, v11
2987 ; CGP-NEXT: v_add_i32_e32 v15, vcc, v15, v16
2988 ; CGP-NEXT: v_add_i32_e32 v15, vcc, v15, v18
2989 ; CGP-NEXT: v_mul_lo_u32 v16, v12, v17
2990 ; CGP-NEXT: v_mul_lo_u32 v18, v4, v15
2991 ; CGP-NEXT: v_mul_hi_u32 v19, v4, v17
2992 ; CGP-NEXT: v_mul_hi_u32 v17, v12, v17
2993 ; CGP-NEXT: v_add_i32_e32 v16, vcc, v16, v18
2994 ; CGP-NEXT: v_cndmask_b32_e64 v18, 0, 1, vcc
2995 ; CGP-NEXT: v_add_i32_e32 v16, vcc, v16, v19
2996 ; CGP-NEXT: v_cndmask_b32_e64 v16, 0, 1, vcc
2997 ; CGP-NEXT: v_mul_lo_u32 v19, v12, v15
2998 ; CGP-NEXT: v_add_i32_e32 v16, vcc, v18, v16
2999 ; CGP-NEXT: v_mul_hi_u32 v18, v4, v15
3000 ; CGP-NEXT: v_mul_hi_u32 v15, v12, v15
3001 ; CGP-NEXT: v_add_i32_e32 v17, vcc, v19, v17
3002 ; CGP-NEXT: v_cndmask_b32_e64 v19, 0, 1, vcc
3003 ; CGP-NEXT: v_add_i32_e32 v17, vcc, v17, v18
3004 ; CGP-NEXT: v_cndmask_b32_e64 v18, 0, 1, vcc
3005 ; CGP-NEXT: v_add_i32_e32 v18, vcc, v19, v18
3006 ; CGP-NEXT: v_add_i32_e32 v16, vcc, v17, v16
3007 ; CGP-NEXT: v_cndmask_b32_e64 v17, 0, 1, vcc
3008 ; CGP-NEXT: v_add_i32_e32 v17, vcc, v18, v17
3009 ; CGP-NEXT: v_add_i32_e32 v15, vcc, v15, v17
3010 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v4, v16
3011 ; CGP-NEXT: v_addc_u32_e64 v16, s[4:5], v12, v15, vcc
3012 ; CGP-NEXT: v_mul_lo_u32 v14, v14, v4
3013 ; CGP-NEXT: v_mul_lo_u32 v17, v13, v16
3014 ; CGP-NEXT: v_mul_lo_u32 v18, v13, v4
3015 ; CGP-NEXT: v_mul_hi_u32 v13, v13, v4
3016 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v12, v15
3017 ; CGP-NEXT: v_add_i32_e64 v14, s[4:5], v14, v17
3018 ; CGP-NEXT: v_mul_hi_u32 v15, v4, v18
3019 ; CGP-NEXT: v_add_i32_e64 v13, s[4:5], v14, v13
3020 ; CGP-NEXT: v_mul_lo_u32 v14, v16, v18
3021 ; CGP-NEXT: v_mul_lo_u32 v17, v4, v13
3022 ; CGP-NEXT: v_mul_hi_u32 v18, v16, v18
3023 ; CGP-NEXT: v_add_i32_e64 v14, s[4:5], v14, v17
3024 ; CGP-NEXT: v_cndmask_b32_e64 v17, 0, 1, s[4:5]
3025 ; CGP-NEXT: v_add_i32_e64 v14, s[4:5], v14, v15
3026 ; CGP-NEXT: v_cndmask_b32_e64 v14, 0, 1, s[4:5]
3027 ; CGP-NEXT: v_mul_lo_u32 v15, v16, v13
3028 ; CGP-NEXT: v_add_i32_e64 v14, s[4:5], v17, v14
3029 ; CGP-NEXT: v_mul_hi_u32 v17, v4, v13
3030 ; CGP-NEXT: v_mul_hi_u32 v13, v16, v13
3031 ; CGP-NEXT: v_add_i32_e64 v15, s[4:5], v15, v18
3032 ; CGP-NEXT: v_cndmask_b32_e64 v18, 0, 1, s[4:5]
3033 ; CGP-NEXT: v_add_i32_e64 v15, s[4:5], v15, v17
3034 ; CGP-NEXT: v_cndmask_b32_e64 v17, 0, 1, s[4:5]
3035 ; CGP-NEXT: v_add_i32_e64 v17, s[4:5], v18, v17
3036 ; CGP-NEXT: v_add_i32_e64 v14, s[4:5], v15, v14
3037 ; CGP-NEXT: v_cndmask_b32_e64 v15, 0, 1, s[4:5]
3038 ; CGP-NEXT: v_add_i32_e64 v15, s[4:5], v17, v15
3039 ; CGP-NEXT: v_add_i32_e64 v13, s[4:5], v13, v15
3040 ; CGP-NEXT: v_addc_u32_e32 v12, vcc, v12, v13, vcc
3041 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v4, v14
3042 ; CGP-NEXT: v_addc_u32_e32 v12, vcc, 0, v12, vcc
3043 ; CGP-NEXT: v_mul_lo_u32 v13, v7, v4
3044 ; CGP-NEXT: v_mul_lo_u32 v14, v6, v12
3045 ; CGP-NEXT: v_mul_hi_u32 v15, v6, v4
3046 ; CGP-NEXT: v_mul_hi_u32 v4, v7, v4
3047 ; CGP-NEXT: v_add_i32_e32 v13, vcc, v13, v14
3048 ; CGP-NEXT: v_cndmask_b32_e64 v14, 0, 1, vcc
3049 ; CGP-NEXT: v_add_i32_e32 v13, vcc, v13, v15
3050 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, 1, vcc
3051 ; CGP-NEXT: v_mul_lo_u32 v15, v7, v12
3052 ; CGP-NEXT: v_add_i32_e32 v13, vcc, v14, v13
3053 ; CGP-NEXT: v_mul_hi_u32 v14, v6, v12
3054 ; CGP-NEXT: v_mul_hi_u32 v12, v7, v12
3055 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v15, v4
3056 ; CGP-NEXT: v_cndmask_b32_e64 v15, 0, 1, vcc
3057 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v4, v14
3058 ; CGP-NEXT: v_cndmask_b32_e64 v14, 0, 1, vcc
3059 ; CGP-NEXT: v_add_i32_e32 v14, vcc, v15, v14
3060 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v4, v13
3061 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, 1, vcc
3062 ; CGP-NEXT: v_add_i32_e32 v13, vcc, v14, v13
3063 ; CGP-NEXT: v_add_i32_e32 v12, vcc, v12, v13
3064 ; CGP-NEXT: v_mul_lo_u32 v13, v0, v4
3065 ; CGP-NEXT: v_mul_lo_u32 v12, v1, v12
3066 ; CGP-NEXT: v_mul_lo_u32 v14, v1, v4
3067 ; CGP-NEXT: v_mul_hi_u32 v4, v1, v4
3068 ; CGP-NEXT: v_add_i32_e32 v12, vcc, v13, v12
3069 ; CGP-NEXT: v_add_i32_e32 v4, vcc, v12, v4
3070 ; CGP-NEXT: v_sub_i32_e32 v6, vcc, v6, v14
3071 ; CGP-NEXT: v_subb_u32_e64 v12, s[4:5], v7, v4, vcc
3072 ; CGP-NEXT: v_sub_i32_e64 v4, s[4:5], v7, v4
3073 ; CGP-NEXT: v_cmp_ge_u32_e64 s[4:5], v12, v0
3074 ; CGP-NEXT: v_cndmask_b32_e64 v7, 0, -1, s[4:5]
3075 ; CGP-NEXT: v_cmp_ge_u32_e64 s[4:5], v6, v1
3076 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, -1, s[4:5]
3077 ; CGP-NEXT: v_cmp_eq_u32_e64 s[4:5], v12, v0
3078 ; CGP-NEXT: v_subb_u32_e32 v4, vcc, v4, v0, vcc
3079 ; CGP-NEXT: v_cndmask_b32_e64 v7, v7, v13, s[4:5]
3080 ; CGP-NEXT: v_sub_i32_e32 v13, vcc, v6, v1
3081 ; CGP-NEXT: v_subbrev_u32_e64 v14, s[4:5], 0, v4, vcc
3082 ; CGP-NEXT: v_cmp_ge_u32_e64 s[4:5], v14, v0
3083 ; CGP-NEXT: v_cndmask_b32_e64 v15, 0, -1, s[4:5]
3084 ; CGP-NEXT: v_cmp_ge_u32_e64 s[4:5], v13, v1
3085 ; CGP-NEXT: v_cndmask_b32_e64 v16, 0, -1, s[4:5]
3086 ; CGP-NEXT: v_cmp_eq_u32_e64 s[4:5], v14, v0
3087 ; CGP-NEXT: v_subb_u32_e32 v0, vcc, v4, v0, vcc
3088 ; CGP-NEXT: v_sub_i32_e32 v1, vcc, v13, v1
3089 ; CGP-NEXT: v_cndmask_b32_e64 v15, v15, v16, s[4:5]
3090 ; CGP-NEXT: v_subbrev_u32_e32 v0, vcc, 0, v0, vcc
3091 ; CGP-NEXT: v_cmp_ne_u32_e32 vcc, 0, v15
3092 ; CGP-NEXT: v_cndmask_b32_e32 v1, v13, v1, vcc
3093 ; CGP-NEXT: v_cndmask_b32_e32 v0, v14, v0, vcc
3094 ; CGP-NEXT: v_cmp_ne_u32_e32 vcc, 0, v7
3095 ; CGP-NEXT: v_cndmask_b32_e32 v1, v6, v1, vcc
3096 ; CGP-NEXT: v_cndmask_b32_e32 v0, v12, v0, vcc
3097 ; CGP-NEXT: v_xor_b32_e32 v1, v1, v11
3098 ; CGP-NEXT: v_xor_b32_e32 v4, v0, v11
3099 ; CGP-NEXT: v_sub_i32_e32 v0, vcc, v1, v11
3100 ; CGP-NEXT: v_subb_u32_e32 v1, vcc, v4, v11, vcc
3101 ; CGP-NEXT: BB8_2: ; %Flow2
3102 ; CGP-NEXT: s_or_saveexec_b64 s[4:5], s[6:7]
3103 ; CGP-NEXT: s_xor_b64 exec, exec, s[4:5]
3104 ; CGP-NEXT: s_cbranch_execz BB8_4
3105 ; CGP-NEXT: ; %bb.3:
3106 ; CGP-NEXT: v_cvt_f32_u32_e32 v0, v10
3107 ; CGP-NEXT: v_sub_i32_e32 v1, vcc, 0, v10
3108 ; CGP-NEXT: v_rcp_iflag_f32_e32 v0, v0
3109 ; CGP-NEXT: v_mul_f32_e32 v0, 0x4f7ffffe, v0
3110 ; CGP-NEXT: v_cvt_u32_f32_e32 v0, v0
3111 ; CGP-NEXT: v_mul_lo_u32 v1, v1, v0
3112 ; CGP-NEXT: v_mul_hi_u32 v1, v0, v1
3113 ; CGP-NEXT: v_add_i32_e32 v0, vcc, v0, v1
3114 ; CGP-NEXT: v_mul_hi_u32 v0, v5, v0
3115 ; CGP-NEXT: v_mul_lo_u32 v0, v0, v10
3116 ; CGP-NEXT: v_sub_i32_e32 v0, vcc, v5, v0
3117 ; CGP-NEXT: v_sub_i32_e32 v1, vcc, v0, v10
3118 ; CGP-NEXT: v_cmp_ge_u32_e32 vcc, v0, v10
3119 ; CGP-NEXT: v_cndmask_b32_e32 v0, v0, v1, vcc
3120 ; CGP-NEXT: v_sub_i32_e32 v1, vcc, v0, v10
3121 ; CGP-NEXT: v_cmp_ge_u32_e32 vcc, v0, v10
3122 ; CGP-NEXT: v_cndmask_b32_e32 v0, v0, v1, vcc
3123 ; CGP-NEXT: v_mov_b32_e32 v1, 0
3124 ; CGP-NEXT: BB8_4:
3125 ; CGP-NEXT: s_or_b64 exec, exec, s[4:5]
3126 ; CGP-NEXT: v_or_b32_e32 v5, v3, v9
3127 ; CGP-NEXT: v_mov_b32_e32 v4, 0
3128 ; CGP-NEXT: v_cmp_ne_u64_e32 vcc, 0, v[4:5]
3129 ; CGP-NEXT: ; implicit-def: $vgpr4_vgpr5
3130 ; CGP-NEXT: s_and_saveexec_b64 s[4:5], vcc
3131 ; CGP-NEXT: s_xor_b64 s[6:7], exec, s[4:5]
3132 ; CGP-NEXT: s_cbranch_execz BB8_6
3133 ; CGP-NEXT: ; %bb.5:
3134 ; CGP-NEXT: v_ashrrev_i32_e32 v4, 31, v9
3135 ; CGP-NEXT: v_add_i32_e32 v5, vcc, v8, v4
3136 ; CGP-NEXT: v_addc_u32_e32 v6, vcc, v9, v4, vcc
3137 ; CGP-NEXT: v_xor_b32_e32 v5, v5, v4
3138 ; CGP-NEXT: v_xor_b32_e32 v4, v6, v4
3139 ; CGP-NEXT: v_cvt_f32_u32_e32 v6, v5
3140 ; CGP-NEXT: v_cvt_f32_u32_e32 v7, v4
3141 ; CGP-NEXT: v_ashrrev_i32_e32 v9, 31, v3
3142 ; CGP-NEXT: v_mac_f32_e32 v6, 0x4f800000, v7
3143 ; CGP-NEXT: v_rcp_iflag_f32_e32 v6, v6
3144 ; CGP-NEXT: v_add_i32_e32 v7, vcc, v2, v9
3145 ; CGP-NEXT: v_addc_u32_e32 v3, vcc, v3, v9, vcc
3146 ; CGP-NEXT: v_sub_i32_e32 v11, vcc, 0, v5
3147 ; CGP-NEXT: v_mul_f32_e32 v6, 0x5f7ffffc, v6
3148 ; CGP-NEXT: v_mul_f32_e32 v10, 0x2f800000, v6
3149 ; CGP-NEXT: v_trunc_f32_e32 v10, v10
3150 ; CGP-NEXT: v_mac_f32_e32 v6, 0xcf800000, v10
3151 ; CGP-NEXT: v_cvt_u32_f32_e32 v6, v6
3152 ; CGP-NEXT: v_cvt_u32_f32_e32 v10, v10
3153 ; CGP-NEXT: v_subb_u32_e32 v12, vcc, 0, v4, vcc
3154 ; CGP-NEXT: v_xor_b32_e32 v7, v7, v9
3155 ; CGP-NEXT: v_mul_lo_u32 v13, v12, v6
3156 ; CGP-NEXT: v_mul_lo_u32 v14, v11, v10
3157 ; CGP-NEXT: v_mul_hi_u32 v16, v11, v6
3158 ; CGP-NEXT: v_mul_lo_u32 v15, v11, v6
3159 ; CGP-NEXT: v_xor_b32_e32 v3, v3, v9
3160 ; CGP-NEXT: v_add_i32_e32 v13, vcc, v13, v14
3161 ; CGP-NEXT: v_add_i32_e32 v13, vcc, v13, v16
3162 ; CGP-NEXT: v_mul_lo_u32 v14, v10, v15
3163 ; CGP-NEXT: v_mul_lo_u32 v16, v6, v13
3164 ; CGP-NEXT: v_mul_hi_u32 v17, v6, v15
3165 ; CGP-NEXT: v_mul_hi_u32 v15, v10, v15
3166 ; CGP-NEXT: v_add_i32_e32 v14, vcc, v14, v16
3167 ; CGP-NEXT: v_cndmask_b32_e64 v16, 0, 1, vcc
3168 ; CGP-NEXT: v_add_i32_e32 v14, vcc, v14, v17
3169 ; CGP-NEXT: v_cndmask_b32_e64 v14, 0, 1, vcc
3170 ; CGP-NEXT: v_mul_lo_u32 v17, v10, v13
3171 ; CGP-NEXT: v_add_i32_e32 v14, vcc, v16, v14
3172 ; CGP-NEXT: v_mul_hi_u32 v16, v6, v13
3173 ; CGP-NEXT: v_mul_hi_u32 v13, v10, v13
3174 ; CGP-NEXT: v_add_i32_e32 v15, vcc, v17, v15
3175 ; CGP-NEXT: v_cndmask_b32_e64 v17, 0, 1, vcc
3176 ; CGP-NEXT: v_add_i32_e32 v15, vcc, v15, v16
3177 ; CGP-NEXT: v_cndmask_b32_e64 v16, 0, 1, vcc
3178 ; CGP-NEXT: v_add_i32_e32 v16, vcc, v17, v16
3179 ; CGP-NEXT: v_add_i32_e32 v14, vcc, v15, v14
3180 ; CGP-NEXT: v_cndmask_b32_e64 v15, 0, 1, vcc
3181 ; CGP-NEXT: v_add_i32_e32 v15, vcc, v16, v15
3182 ; CGP-NEXT: v_add_i32_e32 v13, vcc, v13, v15
3183 ; CGP-NEXT: v_add_i32_e32 v6, vcc, v6, v14
3184 ; CGP-NEXT: v_addc_u32_e64 v14, s[4:5], v10, v13, vcc
3185 ; CGP-NEXT: v_mul_lo_u32 v12, v12, v6
3186 ; CGP-NEXT: v_mul_lo_u32 v15, v11, v14
3187 ; CGP-NEXT: v_mul_lo_u32 v16, v11, v6
3188 ; CGP-NEXT: v_mul_hi_u32 v11, v11, v6
3189 ; CGP-NEXT: v_add_i32_e64 v10, s[4:5], v10, v13
3190 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v12, v15
3191 ; CGP-NEXT: v_mul_hi_u32 v13, v6, v16
3192 ; CGP-NEXT: v_add_i32_e64 v11, s[4:5], v12, v11
3193 ; CGP-NEXT: v_mul_lo_u32 v12, v14, v16
3194 ; CGP-NEXT: v_mul_lo_u32 v15, v6, v11
3195 ; CGP-NEXT: v_mul_hi_u32 v16, v14, v16
3196 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v12, v15
3197 ; CGP-NEXT: v_cndmask_b32_e64 v15, 0, 1, s[4:5]
3198 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v12, v13
3199 ; CGP-NEXT: v_cndmask_b32_e64 v12, 0, 1, s[4:5]
3200 ; CGP-NEXT: v_mul_lo_u32 v13, v14, v11
3201 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v15, v12
3202 ; CGP-NEXT: v_mul_hi_u32 v15, v6, v11
3203 ; CGP-NEXT: v_mul_hi_u32 v11, v14, v11
3204 ; CGP-NEXT: v_add_i32_e64 v13, s[4:5], v13, v16
3205 ; CGP-NEXT: v_cndmask_b32_e64 v16, 0, 1, s[4:5]
3206 ; CGP-NEXT: v_add_i32_e64 v13, s[4:5], v13, v15
3207 ; CGP-NEXT: v_cndmask_b32_e64 v15, 0, 1, s[4:5]
3208 ; CGP-NEXT: v_add_i32_e64 v15, s[4:5], v16, v15
3209 ; CGP-NEXT: v_add_i32_e64 v12, s[4:5], v13, v12
3210 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, 1, s[4:5]
3211 ; CGP-NEXT: v_add_i32_e64 v13, s[4:5], v15, v13
3212 ; CGP-NEXT: v_add_i32_e64 v11, s[4:5], v11, v13
3213 ; CGP-NEXT: v_addc_u32_e32 v10, vcc, v10, v11, vcc
3214 ; CGP-NEXT: v_add_i32_e32 v6, vcc, v6, v12
3215 ; CGP-NEXT: v_addc_u32_e32 v10, vcc, 0, v10, vcc
3216 ; CGP-NEXT: v_mul_lo_u32 v11, v3, v6
3217 ; CGP-NEXT: v_mul_lo_u32 v12, v7, v10
3218 ; CGP-NEXT: v_mul_hi_u32 v13, v7, v6
3219 ; CGP-NEXT: v_mul_hi_u32 v6, v3, v6
3220 ; CGP-NEXT: v_add_i32_e32 v11, vcc, v11, v12
3221 ; CGP-NEXT: v_cndmask_b32_e64 v12, 0, 1, vcc
3222 ; CGP-NEXT: v_add_i32_e32 v11, vcc, v11, v13
3223 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, 1, vcc
3224 ; CGP-NEXT: v_mul_lo_u32 v13, v3, v10
3225 ; CGP-NEXT: v_add_i32_e32 v11, vcc, v12, v11
3226 ; CGP-NEXT: v_mul_hi_u32 v12, v7, v10
3227 ; CGP-NEXT: v_mul_hi_u32 v10, v3, v10
3228 ; CGP-NEXT: v_add_i32_e32 v6, vcc, v13, v6
3229 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, 1, vcc
3230 ; CGP-NEXT: v_add_i32_e32 v6, vcc, v6, v12
3231 ; CGP-NEXT: v_cndmask_b32_e64 v12, 0, 1, vcc
3232 ; CGP-NEXT: v_add_i32_e32 v12, vcc, v13, v12
3233 ; CGP-NEXT: v_add_i32_e32 v6, vcc, v6, v11
3234 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, 1, vcc
3235 ; CGP-NEXT: v_add_i32_e32 v11, vcc, v12, v11
3236 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v10, v11
3237 ; CGP-NEXT: v_mul_lo_u32 v11, v4, v6
3238 ; CGP-NEXT: v_mul_lo_u32 v10, v5, v10
3239 ; CGP-NEXT: v_mul_lo_u32 v12, v5, v6
3240 ; CGP-NEXT: v_mul_hi_u32 v6, v5, v6
3241 ; CGP-NEXT: v_add_i32_e32 v10, vcc, v11, v10
3242 ; CGP-NEXT: v_add_i32_e32 v6, vcc, v10, v6
3243 ; CGP-NEXT: v_sub_i32_e32 v7, vcc, v7, v12
3244 ; CGP-NEXT: v_subb_u32_e64 v10, s[4:5], v3, v6, vcc
3245 ; CGP-NEXT: v_sub_i32_e64 v3, s[4:5], v3, v6
3246 ; CGP-NEXT: v_cmp_ge_u32_e64 s[4:5], v10, v4
3247 ; CGP-NEXT: v_cndmask_b32_e64 v6, 0, -1, s[4:5]
3248 ; CGP-NEXT: v_cmp_ge_u32_e64 s[4:5], v7, v5
3249 ; CGP-NEXT: v_cndmask_b32_e64 v11, 0, -1, s[4:5]
3250 ; CGP-NEXT: v_cmp_eq_u32_e64 s[4:5], v10, v4
3251 ; CGP-NEXT: v_subb_u32_e32 v3, vcc, v3, v4, vcc
3252 ; CGP-NEXT: v_cndmask_b32_e64 v6, v6, v11, s[4:5]
3253 ; CGP-NEXT: v_sub_i32_e32 v11, vcc, v7, v5
3254 ; CGP-NEXT: v_subbrev_u32_e64 v12, s[4:5], 0, v3, vcc
3255 ; CGP-NEXT: v_cmp_ge_u32_e64 s[4:5], v12, v4
3256 ; CGP-NEXT: v_cndmask_b32_e64 v13, 0, -1, s[4:5]
3257 ; CGP-NEXT: v_cmp_ge_u32_e64 s[4:5], v11, v5
3258 ; CGP-NEXT: v_subb_u32_e32 v3, vcc, v3, v4, vcc
3259 ; CGP-NEXT: v_cndmask_b32_e64 v14, 0, -1, s[4:5]
3260 ; CGP-NEXT: v_cmp_eq_u32_e64 s[4:5], v12, v4
3261 ; CGP-NEXT: v_sub_i32_e32 v4, vcc, v11, v5
3262 ; CGP-NEXT: v_cndmask_b32_e64 v13, v13, v14, s[4:5]
3263 ; CGP-NEXT: v_subbrev_u32_e32 v3, vcc, 0, v3, vcc
3264 ; CGP-NEXT: v_cmp_ne_u32_e32 vcc, 0, v13
3265 ; CGP-NEXT: v_cndmask_b32_e32 v4, v11, v4, vcc
3266 ; CGP-NEXT: v_cndmask_b32_e32 v3, v12, v3, vcc
3267 ; CGP-NEXT: v_cmp_ne_u32_e32 vcc, 0, v6
3268 ; CGP-NEXT: v_cndmask_b32_e32 v4, v7, v4, vcc
3269 ; CGP-NEXT: v_cndmask_b32_e32 v3, v10, v3, vcc
3270 ; CGP-NEXT: v_xor_b32_e32 v4, v4, v9
3271 ; CGP-NEXT: v_xor_b32_e32 v3, v3, v9
3272 ; CGP-NEXT: v_sub_i32_e32 v4, vcc, v4, v9
3273 ; CGP-NEXT: v_subb_u32_e32 v5, vcc, v3, v9, vcc
3274 ; CGP-NEXT: BB8_6: ; %Flow
3275 ; CGP-NEXT: s_or_saveexec_b64 s[4:5], s[6:7]
3276 ; CGP-NEXT: s_xor_b64 exec, exec, s[4:5]
3277 ; CGP-NEXT: s_cbranch_execz BB8_8
3278 ; CGP-NEXT: ; %bb.7:
3279 ; CGP-NEXT: v_cvt_f32_u32_e32 v3, v8
3280 ; CGP-NEXT: v_sub_i32_e32 v4, vcc, 0, v8
3281 ; CGP-NEXT: v_mov_b32_e32 v5, 0
3282 ; CGP-NEXT: v_rcp_iflag_f32_e32 v3, v3
3283 ; CGP-NEXT: v_mul_f32_e32 v3, 0x4f7ffffe, v3
3284 ; CGP-NEXT: v_cvt_u32_f32_e32 v3, v3
3285 ; CGP-NEXT: v_mul_lo_u32 v4, v4, v3
3286 ; CGP-NEXT: v_mul_hi_u32 v4, v3, v4
3287 ; CGP-NEXT: v_add_i32_e32 v3, vcc, v3, v4
3288 ; CGP-NEXT: v_mul_hi_u32 v3, v2, v3
3289 ; CGP-NEXT: v_mul_lo_u32 v3, v3, v8
3290 ; CGP-NEXT: v_sub_i32_e32 v2, vcc, v2, v3
3291 ; CGP-NEXT: v_sub_i32_e32 v3, vcc, v2, v8
3292 ; CGP-NEXT: v_cmp_ge_u32_e32 vcc, v2, v8
3293 ; CGP-NEXT: v_cndmask_b32_e32 v2, v2, v3, vcc
3294 ; CGP-NEXT: v_sub_i32_e32 v3, vcc, v2, v8
3295 ; CGP-NEXT: v_cmp_ge_u32_e32 vcc, v2, v8
3296 ; CGP-NEXT: v_cndmask_b32_e32 v4, v2, v3, vcc
3297 ; CGP-NEXT: BB8_8:
3298 ; CGP-NEXT: s_or_b64 exec, exec, s[4:5]
3299 ; CGP-NEXT: v_mov_b32_e32 v2, v4
3300 ; CGP-NEXT: v_mov_b32_e32 v3, v5
3301 ; CGP-NEXT: s_setpc_b64 s[30:31]
3334 ; CGP-LABEL: v_srem_i64_24bit:
3335 ; CGP: ; %bb.0:
3336 ; CGP-NEXT: s_waitcnt vmcnt(0) expcnt(0) lgkmcnt(0)
3337 ; CGP-NEXT: s_mov_b32 s4, 0xffffff
3338 ; CGP-NEXT: v_and_b32_e32 v1, s4, v2
3339 ; CGP-NEXT: v_cvt_f32_i32_e32 v2, v1
3340 ; CGP-NEXT: v_and_b32_e32 v0, s4, v0
3341 ; CGP-NEXT: v_cvt_f32_i32_e32 v3, v0
3342 ; CGP-NEXT: v_rcp_f32_e32 v4, v2
3343 ; CGP-NEXT: v_mul_f32_e32 v4, v3, v4
3344 ; CGP-NEXT: v_trunc_f32_e32 v4, v4
3345 ; CGP-NEXT: v_mad_f32 v3, -v4, v2, v3
3346 ; CGP-NEXT: v_cvt_i32_f32_e32 v4, v4
3347 ; CGP-NEXT: v_cmp_ge_f32_e64 s[4:5], |v3|, |v2|
3348 ; CGP-NEXT: v_cndmask_b32_e64 v2, 0, 1, s[4:5]
3349 ; CGP-NEXT: v_add_i32_e32 v2, vcc, v4, v2
3350 ; CGP-NEXT: v_mul_lo_u32 v1, v2, v1
3351 ; CGP-NEXT: v_sub_i32_e32 v0, vcc, v0, v1
3352 ; CGP-NEXT: v_bfe_i32 v0, v0, 0, 25
3353 ; CGP-NEXT: v_ashrrev_i32_e32 v1, 31, v0
3354 ; CGP-NEXT: s_setpc_b64 s[30:31]
3636 ; CGP-LABEL: v_srem_v2i64_24bit:
3637 ; CGP: ; %bb.0:
3638 ; CGP-NEXT: s_waitcnt vmcnt(0) expcnt(0) lgkmcnt(0)
3639 ; CGP-NEXT: s_mov_b32 s4, 0xffffff
3640 ; CGP-NEXT: v_and_b32_e32 v1, s4, v4
3641 ; CGP-NEXT: v_cvt_f32_i32_e32 v3, v1
3642 ; CGP-NEXT: v_and_b32_e32 v0, s4, v0
3643 ; CGP-NEXT: v_cvt_f32_i32_e32 v4, v0
3644 ; CGP-NEXT: v_and_b32_e32 v6, s4, v6
3645 ; CGP-NEXT: v_rcp_f32_e32 v5, v3
3646 ; CGP-NEXT: v_and_b32_e32 v2, s4, v2
3647 ; CGP-NEXT: v_mul_f32_e32 v5, v4, v5
3648 ; CGP-NEXT: v_trunc_f32_e32 v5, v5
3649 ; CGP-NEXT: v_mad_f32 v4, -v5, v3, v4
3650 ; CGP-NEXT: v_cvt_i32_f32_e32 v5, v5
3651 ; CGP-NEXT: v_cmp_ge_f32_e64 s[4:5], |v4|, |v3|
3652 ; CGP-NEXT: v_cvt_f32_i32_e32 v4, v6
3653 ; CGP-NEXT: v_cndmask_b32_e64 v3, 0, 1, s[4:5]
3654 ; CGP-NEXT: v_add_i32_e32 v3, vcc, v5, v3
3655 ; CGP-NEXT: v_mul_lo_u32 v1, v3, v1
3656 ; CGP-NEXT: v_cvt_f32_i32_e32 v3, v2
3657 ; CGP-NEXT: v_rcp_f32_e32 v5, v4
3658 ; CGP-NEXT: v_sub_i32_e32 v0, vcc, v0, v1
3659 ; CGP-NEXT: v_bfe_i32 v0, v0, 0, 25
3660 ; CGP-NEXT: v_mul_f32_e32 v1, v3, v5
3661 ; CGP-NEXT: v_trunc_f32_e32 v1, v1
3662 ; CGP-NEXT: v_mad_f32 v3, -v1, v4, v3
3663 ; CGP-NEXT: v_cvt_i32_f32_e32 v1, v1
3664 ; CGP-NEXT: v_cmp_ge_f32_e64 s[4:5], |v3|, |v4|
3665 ; CGP-NEXT: v_cndmask_b32_e64 v3, 0, 1, s[4:5]
3666 ; CGP-NEXT: v_add_i32_e32 v1, vcc, v1, v3
3667 ; CGP-NEXT: v_mul_lo_u32 v3, v1, v6
3668 ; CGP-NEXT: v_ashrrev_i32_e32 v1, 31, v0
3669 ; CGP-NEXT: v_sub_i32_e32 v2, vcc, v2, v3
3670 ; CGP-NEXT: v_bfe_i32 v2, v2, 0, 25
3671 ; CGP-NEXT: v_ashrrev_i32_e32 v3, 31, v2
3672 ; CGP-NEXT: s_setpc_b64 s[30:31]