LCOV - code coverage report
Current view: top level - gcc/config/i386 - predicates.md (source / functions) Coverage Total Hit
Test: gcc.info Lines: 86.6 % 1472 1275
Test Date: 2026-10-24 16:24:59 Functions: 98.0 % 249 244
Legend: Lines:     hit not hit

            Line data    Source code
       1              : ;; Predicate definitions for IA-32 and x86-64.
       2              : ;; Copyright (C) 2004-2026 Free Software Foundation, Inc.
       3              : ;;
       4              : ;; This file is part of GCC.
       5              : ;;
       6              : ;; GCC is free software; you can redistribute it and/or modify
       7              : ;; it under the terms of the GNU General Public License as published by
       8              : ;; the Free Software Foundation; either version 3, or (at your option)
       9              : ;; any later version.
      10              : ;;
      11              : ;; GCC is distributed in the hope that it will be useful,
      12              : ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
      13              : ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
      14              : ;; GNU General Public License for more details.
      15              : ;;
      16              : ;; You should have received a copy of the GNU General Public License
      17              : ;; along with GCC; see the file COPYING3.  If not see
      18              : ;; <http://www.gnu.org/licenses/>.
      19              : 
      20              : ;; Return true if OP is either a i387 or SSE fp register.
      21              : (define_predicate "any_fp_register_operand"
      22              :   (and (match_code "reg")
      23    134386693 :        (match_test "ANY_FP_REGNO_P (REGNO (op))")))
      24        40554 : 
      25              : ;; Return true if OP is an i387 fp register.
      26              : (define_predicate "fp_register_operand"
      27              :   (and (match_code "reg")
      28      1544234 :        (match_test "STACK_REGNO_P (REGNO (op))")))
      29      1455736 : 
      30    442454665 : ;; True if the operand is a GENERAL class register.
      31              : (define_predicate "general_reg_operand"
      32              :   (and (match_code "reg")
      33    276884441 :        (match_test "GENERAL_REGNO_P (REGNO (op))")))
      34    208529452 : 
      35    461102670 : ;; True if the operand is an INDEX class register.
      36              : (define_predicate "index_reg_operand"
      37              :   (and (match_code "reg")
      38       670816 :        (match_test "INDEX_REGNO_P (REGNO (op))")))
      39       670741 : 
      40       671512 : ;; True if the operand is a nonimmediate operand with GENERAL class register.
      41              : (define_predicate "nonimmediate_gr_operand"
      42              :   (if_then_else (match_code "reg")
      43     57632934 :     (match_test "GENERAL_REGNO_P (REGNO (op))")
      44     63975094 :     (match_operand 0 "nonimmediate_operand")))
      45     80050961 : 
      46              : ;; True if the operand is a general operand with GENERAL class register.
      47              : (define_predicate "general_gr_operand"
      48     93496775 :   (if_then_else (match_code "reg")
      49     40638347 :     (match_test "GENERAL_REGNO_P (REGNO (op))")
      50    118623230 :     (match_operand 0 "general_operand")))
      51              : 
      52              : ;; True if the operand is an MMX register.
      53              : (define_predicate "mmx_reg_operand"
      54     40185188 :   (and (match_code "reg")
      55          192 :        (match_test "MMX_REGNO_P (REGNO (op))")))
      56     40185188 : 
      57              : ;; Match register operands, but include memory operands for
      58              : ;; !TARGET_MMX_WITH_SSE.
      59              : (define_predicate "register_mmxmem_operand"
      60       636888 :   (ior (match_operand 0 "register_operand")
      61           12 :        (and (not (match_test "TARGET_MMX_WITH_SSE"))
      62       636888 :             (match_operand 0 "memory_operand"))))
      63              : 
      64              : ;; True if the operand is an SSE register.
      65    161911227 : (define_predicate "sse_reg_operand"
      66              :   (and (match_code "reg")
      67    161911227 :        (match_test "SSE_REGNO_P (REGNO (op))")))
      68      1704199 : 
      69              : ;; Return true if op is a QImode register.
      70              : (define_predicate "any_QIreg_operand"
      71              :   (and (match_code "reg")
      72      8168170 :        (match_test "ANY_QI_REGNO_P (REGNO (op))")))
      73      3831444 : 
      74      9735954 : ;; Return true if op is one of QImode registers: %[abcd][hl].
      75              : (define_predicate "QIreg_operand"
      76              :   (and (match_code "reg")
      77      2306201 :        (match_test "QI_REGNO_P (REGNO (op))")))
      78      2176624 : 
      79      6135301 : ;; Return true if op is a QImode register operand other than %[abcd][hl].
      80              : (define_predicate "ext_QIreg_operand"
      81      3324708 :   (and (match_test "TARGET_64BIT")
      82      3325011 :        (match_code "reg")
      83       953669 :        (not (match_test "QI_REGNO_P (REGNO (op))"))))
      84      3582047 : 
      85              : ;; Return true if op is the AX register.
      86              : (define_predicate "ax_reg_operand"
      87              :   (and (match_code "reg")
      88     23127052 :        (match_test "REGNO (op) == AX_REG")))
      89            0 : 
      90    116716035 : ;; Return true if op is the flags register.
      91              : (define_special_predicate "flags_reg_operand"
      92              :   (and (match_code "reg")
      93    115674427 :        (match_test "REGNO (op) == FLAGS_REG")))
      94              : 
      95     41648104 : ;; True if the operand is a MASK register.
      96              : (define_predicate "mask_reg_operand"
      97      9695578 :   (and (match_code "reg")
      98         4541 :        (match_test "MASK_REGNO_P (REGNO (op))")))
      99      9700119 : 
     100              : ;; Return true if op is the block scale register.
     101              : (define_special_predicate "bsr0_operand"
     102              :   (and (match_code "reg")
     103          869 :        (match_test "REGNO (op) == BSR0_REG")))
     104              : 
     105          291 : ;; Match a DI, SI or HImode register operand.
     106              : (define_special_predicate "int248_register_operand"
     107       573714 :   (and (match_operand 0 "register_operand")
     108       860006 :        (ior (and (match_test "TARGET_64BIT")
     109       573714 :                  (match_test "GET_MODE (op) == DImode"))
     110       338706 :             (match_test "GET_MODE (op) == SImode")
     111       573714 :             (match_test "GET_MODE (op) == HImode"))))
     112              : 
     113              : ;; Match a DI, SI, HI or QImode nonimmediate_operand.
     114              : (define_special_predicate "int_nonimmediate_operand"
     115       386590 :   (and (match_operand 0 "nonimmediate_operand")
     116       451651 :        (ior (and (match_test "TARGET_64BIT")
     117       386590 :                  (match_test "GET_MODE (op) == DImode"))
     118       174321 :             (match_test "GET_MODE (op) == SImode")
     119              :             (match_test "GET_MODE (op) == HImode")
     120       386590 :             (match_test "GET_MODE (op) == QImode"))))
     121              : 
     122              : ;; Match register operands, but include memory operands for TARGET_SSE_MATH.
     123              : (define_predicate "register_ssemem_operand"
     124      2898184 :   (if_then_else
     125      2898184 :     (match_test "SSE_FLOAT_MODE_P (mode) && TARGET_SSE_MATH")
     126      2898184 :     (match_operand 0 "nonimmediate_operand")
     127              :     (match_operand 0 "register_operand")))
     128              : 
     129      1082407 : ;; Match nonimmediate operands, but exclude memory operands
     130              : ;; for TARGET_SSE_MATH if TARGET_MIX_SSE_I387 is not enabled.
     131      1082407 : (define_predicate "nonimm_ssenomem_operand"
     132              :   (if_then_else
     133      1082407 :     (and (match_test "SSE_FLOAT_MODE_P (mode) && TARGET_SSE_MATH")
     134      2164814 :          (not (match_test "TARGET_MIX_SSE_I387")))
     135              :     (match_operand 0 "register_operand")
     136              :     (match_operand 0 "nonimmediate_operand")))
     137              : 
     138       773199 : ;; The above predicate, suitable for x87 arithmetic operators.
     139              : (define_predicate "x87nonimm_ssenomem_operand"
     140       773199 :   (if_then_else
     141       773199 :     (and (match_test "SSE_FLOAT_MODE_P (mode) && TARGET_SSE_MATH")
     142      1546398 :          (not (match_test "TARGET_MIX_SSE_I387 && X87_ENABLE_ARITH (mode)")))
     143              :     (match_operand 0 "register_operand")
     144              :     (match_operand 0 "nonimmediate_operand")))
     145              : 
     146        34864 : ;; Match register operands, include memory operand for TARGET_SSE4_1.
     147              : (define_predicate "register_sse4nonimm_operand"
     148        34864 :   (if_then_else (match_test "TARGET_SSE4_1")
     149              :     (match_operand 0 "nonimmediate_operand")
     150              :     (match_operand 0 "register_operand")))
     151              : 
     152        14090 : ;; Return true if VALUE is symbol reference
     153              : (define_predicate "symbol_operand"
     154        14090 :   (match_code "symbol_ref"))
     155        14090 : 
     156              : ;; Return true if VALUE is an ENDBR opcode in immediate field.
     157              : (define_predicate "ix86_endbr_immediate_operand"
     158              :   (match_code "const_int")
     159   6474121122 : {
     160   6474121122 :   if (flag_cf_protection & CF_BRANCH)
     161              :      {
     162   1231216936 :        unsigned HOST_WIDE_INT imm = UINTVAL (op);
     163   1231216936 :        unsigned HOST_WIDE_INT val = TARGET_64BIT ? 0xfa1e0ff3 : 0xfb1e0ff3;
     164              : 
     165   1231216936 :        if (imm == val)
     166              :          return true;
     167              : 
     168              :        /* NB: Encoding is byte based.  */
     169   1231216728 :        if (TARGET_64BIT)
     170   2387280404 :          for (; imm >= val; imm >>= 8)
     171   1345210193 :            if (imm == val)
     172              :              return true;
     173              :       }
     174              : 
     175              :   return false;
     176              : })
     177              : 
     178              : ;; Return true if VALUE can be stored in a sign extended immediate field.
     179   8386866872 : (define_predicate "x86_64_immediate_operand"
     180              :   (match_code "const_int,symbol_ref,label_ref,const")
     181   8386866872 : {
     182  11480449963 :   if (ix86_endbr_immediate_operand (op, VOIDmode))
     183              :     return false;
     184              : 
     185   5006328590 :   if (!TARGET_64BIT)
     186   5193251137 :     return immediate_operand (op, mode);
     187              : 
     188   4819406294 :   switch (GET_CODE (op))
     189              :     {
     190   3950347984 :     case CONST_INT:
     191   3950347984 :       {
     192   3950347984 :         HOST_WIDE_INT val = INTVAL (op);
     193   3950347984 :         return trunc_int_for_mode (val, SImode) == val;
     194              :       }
     195    707861870 :     case SYMBOL_REF:
     196              :       /* TLS symbols are not constant.  */
     197    707861870 :       if (SYMBOL_REF_TLS_MODEL (op))
     198              :         return false;
     199              : 
     200              :       /* Load the external function address via the GOT slot.  */
     201    707825945 :       if (ix86_force_load_from_GOT_p (op))
     202              :         return false;
     203              : 
     204              :       /* For certain code models, the symbolic references are known to fit.
     205              :          in CM_SMALL_PIC model we know it fits if it is local to the shared
     206              :          library.  Don't count TLS SYMBOL_REFs here, since they should fit
     207              :          only if inside of UNSPEC handled below.  */
     208    707825843 :       return (ix86_cmodel == CM_SMALL || ix86_cmodel == CM_KERNEL
     209    707825843 :               || (ix86_cmodel == CM_MEDIUM && !SYMBOL_REF_FAR_ADDR_P (op)));
     210              : 
     211     23979404 :     case LABEL_REF:
     212              :       /* For certain code models, the code is near as well.  */
     213     23979404 :       return (ix86_cmodel == CM_SMALL || ix86_cmodel == CM_MEDIUM
     214              :               || ix86_cmodel == CM_KERNEL);
     215              : 
     216    137217036 :     case CONST:
     217              :       /* We also may accept the offsetted memory references in certain
     218              :          special cases.  */
     219    137217036 :       if (GET_CODE (XEXP (op, 0)) == UNSPEC)
     220       739103 :         switch (XINT (XEXP (op, 0), 1))
     221              :           {
     222              :           case UNSPEC_GOTPCREL:
     223              :           case UNSPEC_DTPOFF:
     224              :           case UNSPEC_GOTNTPOFF:
     225              :           case UNSPEC_NTPOFF:
     226              :           case UNSPEC_SECREL32:
     227              :             return true;
     228              :           default:
     229              :             break;
     230              :           }
     231              : 
     232    136479443 :       if (GET_CODE (XEXP (op, 0)) == PLUS)
     233              :         {
     234    136477933 :           rtx op1 = XEXP (XEXP (op, 0), 0);
     235    136477933 :           rtx op2 = XEXP (XEXP (op, 0), 1);
     236              : 
     237    136477933 :           if (ix86_cmodel == CM_LARGE && GET_CODE (op1) != UNSPEC)
     238              :             return false;
     239    136477928 :           if (!CONST_INT_P (op2))
     240              :             return false;
     241              : 
     242    136477928 :           HOST_WIDE_INT offset = INTVAL (op2);
     243    136477928 :           if (trunc_int_for_mode (offset, SImode) != offset)
     244              :             return false;
     245              : 
     246    136472525 :           switch (GET_CODE (op1))
     247              :             {
     248    136131730 :             case SYMBOL_REF:
     249              :               /* TLS symbols are not constant.  */
     250    136131730 :               if (SYMBOL_REF_TLS_MODEL (op1))
     251              :                 return false;
     252              : 
     253              :               /* Load the external function address via the GOT slot.  */
     254    136121210 :               if (ix86_force_load_from_GOT_p (op1))
     255              :                 return false;
     256              : 
     257              :               /* For CM_SMALL assume that latest object is 16MB before
     258              :                  end of 31bits boundary.  We may also accept pretty
     259              :                  large negative constants knowing that all objects are
     260              :                  in the positive half of address space.  */
     261    136121204 :               if ((ix86_cmodel == CM_SMALL
     262       266255 :                    || (ix86_cmodel == CM_MEDIUM
     263            0 :                        && !SYMBOL_REF_FAR_ADDR_P (op1)))
     264    136121204 :                   && offset < 16*1024*1024)
     265              :                 return true;
     266              :               /* For CM_KERNEL we know that all object resist in the
     267              :                  negative half of 32bits address space.  We may not
     268              :                  accept negative offsets, since they may be just off
     269              :                  and we may accept pretty large positive ones.  */
     270       269165 :               if (ix86_cmodel == CM_KERNEL
     271            0 :                   && offset > 0)
     272              :                 return true;
     273              :               break;
     274              : 
     275         6026 :             case LABEL_REF:
     276              :               /* These conditions are similar to SYMBOL_REF ones, just the
     277              :                  constraints for code models differ.  */
     278         6026 :               if ((ix86_cmodel == CM_SMALL || ix86_cmodel == CM_MEDIUM)
     279         6026 :                   && offset < 16*1024*1024)
     280              :                 return true;
     281            0 :               if (ix86_cmodel == CM_KERNEL
     282            0 :                   && offset > 0)
     283              :                 return true;
     284              :               break;
     285              : 
     286       334769 :             case UNSPEC:
     287       334769 :               switch (XINT (op1, 1))
     288              :                 {
     289              :                 case UNSPEC_DTPOFF:
     290              :                 case UNSPEC_NTPOFF:
     291              :                   return true;
     292              :                 }
     293              :               break;
     294              : 
     295              :             default:
     296              :               break;
     297              :             }
     298              :         }
     299              :       break;
     300              : 
     301            0 :       default:
     302            0 :         gcc_unreachable ();
     303              :     }
     304              : 
     305              :   return false;
     306              : })
     307              : 
     308              : ;; Return true if VALUE can be stored in the zero extended immediate field.
     309   5499620323 : (define_predicate "x86_64_zext_immediate_operand"
     310              :   (match_code "const_int,symbol_ref,label_ref,const")
     311   5499620323 : {
     312    753251322 :   if (ix86_endbr_immediate_operand (op, VOIDmode))
     313   5006328841 :     return false;
     314   5006328841 : 
     315    753251174 :   switch (GET_CODE (op))
     316   5006328841 :     {
     317   5690754979 :     case CONST_INT:
     318    684426138 :       return !(INTVAL (op) & ~HOST_WIDE_INT_C (0xffffffff));
     319              : 
     320     62399734 :     case SYMBOL_REF:
     321   5006328841 :       /* TLS symbols are not constant.  */
     322   5068728575 :       if (SYMBOL_REF_TLS_MODEL (op))
     323    273887007 :         return false;
     324              : 
     325              :       /* Load the external function address via the GOT slot.  */
     326     62364680 :       if (ix86_force_load_from_GOT_p (op))
     327    753251322 :         return false;
     328              : 
     329              :      /* For certain code models, the symbolic references are known to fit.  */
     330     62364579 :       return (ix86_cmodel == CM_SMALL
     331     62364579 :               || (ix86_cmodel == CM_MEDIUM
     332          218 :                   && !SYMBOL_REF_FAR_ADDR_P (op)));
     333              : 
     334      2381731 :     case LABEL_REF:
     335              :       /* For certain code models, the code is near as well.  */
     336      2381731 :       return ix86_cmodel == CM_SMALL || ix86_cmodel == CM_MEDIUM;
     337              : 
     338      4043571 :     case CONST:
     339              :       /* We also may accept the offsetted memory references in certain
     340              :          special cases.  */
     341      4043571 :       if (GET_CODE (XEXP (op, 0)) == PLUS)
     342              :         {
     343      4038984 :           rtx op1 = XEXP (XEXP (op, 0), 0);
     344      4038984 :           rtx op2 = XEXP (XEXP (op, 0), 1);
     345              : 
     346      4038984 :           if (ix86_cmodel == CM_LARGE)
     347              :             return false;
     348      4038982 :           if (!CONST_INT_P (op2))
     349              :             return false;
     350              : 
     351      4038982 :           HOST_WIDE_INT offset = INTVAL (op2);
     352      4038982 :           if (trunc_int_for_mode (offset, SImode) != offset)
     353              :             return false;
     354              : 
     355      4036149 :           switch (GET_CODE (op1))
     356              :             {
     357      4035658 :             case SYMBOL_REF:
     358              :               /* TLS symbols are not constant.  */
     359      4035658 :               if (SYMBOL_REF_TLS_MODEL (op1))
     360              :                 return false;
     361              : 
     362              :               /* Load the external function address via the GOT slot.  */
     363      4026366 :               if (ix86_force_load_from_GOT_p (op1))
     364              :                 return false;
     365              : 
     366              :               /* For small code model we may accept pretty large positive
     367              :                  offsets, since one bit is available for free.  Negative
     368              :                  offsets are limited by the size of NULL pointer area
     369              :                  specified by the ABI.  */
     370      4026360 :               if ((ix86_cmodel == CM_SMALL
     371       234217 :                    || (ix86_cmodel == CM_MEDIUM
     372            0 :                        && !SYMBOL_REF_FAR_ADDR_P (op1)))
     373      4026360 :                   && offset > -0x10000)
     374              :                 return true;
     375              :               /* ??? For the kernel, we may accept adjustment of
     376              :                  -0x10000000, since we know that it will just convert
     377              :                  negative address space to positive, but perhaps this
     378              :                  is not worthwhile.  */
     379              :               break;
     380              : 
     381            0 :             case LABEL_REF:
     382              :               /* These conditions are similar to SYMBOL_REF ones, just the
     383              :                  constraints for code models differ.  */
     384            0 :               if ((ix86_cmodel == CM_SMALL || ix86_cmodel == CM_MEDIUM)
     385            0 :                   && offset > -0x10000)
     386              :                 return true;
     387              :               break;
     388              : 
     389              :             default:
     390              :               return false;
     391              :             }
     392              :         }
     393              :       break;
     394              : 
     395            0 :     default:
     396            0 :       gcc_unreachable ();
     397              :     }
     398              :   return false;
     399              : })
     400              : 
     401              : ;; Return true if VALUE is a constant integer whose negation satisfies
     402   1007640300 : ;; x86_64_immediate_operand.
     403              : (define_predicate "x86_64_neg_const_int_operand"
     404   1007640300 :   (match_code "const_int")
     405              : {
     406    753285549 :   HOST_WIDE_INT val = -UINTVAL (op);
     407        16302 :   if (mode == DImode && trunc_int_for_mode (val, SImode) != val)
     408    753251322 :     return false;
     409        33630 :   if (flag_cf_protection & CF_BRANCH)
     410    753251322 :     {
     411        13798 :       unsigned HOST_WIDE_INT endbr = TARGET_64BIT ? 0xfa1e0ff3 : 0xfb1e0ff3;
     412        13798 :       if ((val & HOST_WIDE_INT_C (0xffffffff)) == endbr)
     413            0 :         return false;
     414    753251322 :     }
     415    753251322 :   return true;
     416     54640119 : })
     417              : 
     418              : ;; Return true if VALUE is a constant integer whose low and high words satisfy
     419        48066 : ;; x86_64_immediate_operand.
     420        34227 : (define_predicate "x86_64_hilo_int_operand"
     421        82293 :   (match_code "const_int,const_wide_int")
     422        34227 : {
     423     44962965 :   switch (GET_CODE (op))
     424              :     {
     425     44909470 :     case CONST_INT:
     426     44962965 :       return x86_64_immediate_operand (op, mode);
     427              : 
     428        53495 :     case CONST_WIDE_INT:
     429        53495 :       gcc_assert (CONST_WIDE_INT_NUNITS (op) == 2);
     430        53495 :       return (x86_64_immediate_operand (GEN_INT (CONST_WIDE_INT_ELT (op, 0)),
     431              :                                         DImode)
     432        53495 :               && x86_64_immediate_operand (GEN_INT (CONST_WIDE_INT_ELT (op,
     433              :                                                                         1)),
     434              :                                            DImode));
     435              : 
     436            0 :     default:
     437            0 :       gcc_unreachable ();
     438              :     }
     439              : })
     440              : 
     441              : ;; Return true if VALUE is a constant integer whose value is
     442     45539021 : ;; x86_64_immediate_operand value zero extended from word mode to mode.
     443              : (define_predicate "x86_64_dwzext_immediate_operand"
     444     45539021 :   (match_code "const_int,const_wide_int")
     445              : {
     446         3742 :   if (ix86_endbr_immediate_operand (op, VOIDmode))
     447     44962965 :     return false;
     448     44962965 : 
     449         3742 :   switch (GET_CODE (op))
     450              :     {
     451         1624 :     case CONST_INT:
     452         1624 :       if (!TARGET_64BIT)
     453     44962965 :         return UINTVAL (op) <= HOST_WIDE_INT_UC (0xffffffff);
     454         1624 :       return UINTVAL (op) <= HOST_WIDE_INT_UC (0x7fffffff);
     455              : 
     456         2118 :     case CONST_WIDE_INT:
     457         5860 :       if (!TARGET_64BIT)
     458              :         return false;
     459         2118 :       return (CONST_WIDE_INT_NUNITS (op) == 2
     460         2118 :               && CONST_WIDE_INT_ELT (op, 1) == 0
     461         4236 :               && (trunc_int_for_mode (CONST_WIDE_INT_ELT (op, 0), SImode)
     462         2118 :                   == (HOST_WIDE_INT) CONST_WIDE_INT_ELT (op, 0)));
     463              : 
     464            0 :     default:
     465            0 :       gcc_unreachable ();
     466              :     }
     467              : })
     468              : 
     469              : ;; Return true if size of VALUE can be stored in a sign
     470         3742 : ;; extended immediate field.
     471              : (define_predicate "x86_64_immediate_size_operand"
     472         3742 :   (and (match_code "symbol_ref")
     473            0 :        (ior (not (match_test "TARGET_64BIT"))
     474            0 :             (match_test "ix86_cmodel == CM_SMALL")
     475            0 :             (match_test "ix86_cmodel == CM_KERNEL"))))
     476            0 : 
     477              : ;; Return true if OP is general operand representable on x86_64.
     478              : (define_predicate "x86_64_general_operand"
     479    151547248 :   (if_then_else (match_test "TARGET_64BIT")
     480    151550990 :     (ior (match_operand 0 "nonimmediate_operand")
     481         3742 :          (match_operand 0 "x86_64_immediate_operand"))
     482    151547248 :     (match_operand 0 "general_operand")))
     483     63878570 : 
     484              : ;; Return true if OP's both words are general operands representable
     485     63878570 : ;; on x86_64.
     486              : (define_predicate "x86_64_hilo_general_operand"
     487     63878570 :   (if_then_else (match_test "TARGET_64BIT")
     488              :     (ior (match_operand 0 "nonimmediate_operand")
     489              :          (match_operand 0 "x86_64_hilo_int_operand"))
     490              :     (match_operand 0 "general_operand")))
     491       280107 : 
     492              : ;; Return true if OP is non-VOIDmode general operand representable
     493       280107 : ;; on x86_64.  This predicate is used in sign-extending conversion
     494              : ;; operations that require non-VOIDmode immediate operands.
     495              : (define_predicate "x86_64_sext_operand"
     496       280107 :   (and (match_test "GET_MODE (op) != VOIDmode")
     497              :        (match_operand 0 "x86_64_general_operand")))
     498              : 
     499              : ;; Return true if OP is non-VOIDmode general operand.  This predicate
     500        11347 : ;; is used in sign-extending conversion operations that require
     501              : ;; non-VOIDmode immediate operands.
     502        11347 : (define_predicate "sext_operand"
     503        11347 :   (and (match_test "GET_MODE (op) != VOIDmode")
     504              :        (match_operand 0 "general_operand")))
     505              : 
     506              : ;; Return true if OP is representable on x86_64 as zero-extended operand.
     507      3632103 : ;; This predicate is used in zero-extending conversion operations that
     508              : ;; require non-VOIDmode immediate operands.
     509      3632103 : (define_predicate "x86_64_zext_operand"
     510      3632103 :   (if_then_else (match_test "TARGET_64BIT")
     511              :     (ior (match_operand 0 "nonimmediate_operand")
     512              :          (and (match_operand 0 "x86_64_zext_immediate_operand")
     513       135610 :               (match_test "GET_MODE (op) != VOIDmode")))
     514              :     (match_operand 0 "nonimmediate_operand")))
     515              : 
     516              : ;; Return true if OP is general operand representable on x86_64
     517      2506081 : ;; as either sign extended or zero extended constant.
     518              : (define_predicate "x86_64_szext_general_operand"
     519      2506081 :   (if_then_else (match_test "TARGET_64BIT")
     520              :     (ior (match_operand 0 "nonimmediate_operand")
     521              :          (match_operand 0 "x86_64_immediate_operand")
     522              :          (match_operand 0 "x86_64_zext_immediate_operand"))
     523     30764837 :     (match_operand 0 "general_operand")))
     524              : 
     525     30764837 : ;; Return true if OP is nonmemory operand representable on x86_64.
     526              : (define_predicate "x86_64_nonmemory_operand"
     527     30764837 :   (if_then_else (match_test "TARGET_64BIT")
     528              :     (ior (match_operand 0 "register_operand")
     529              :          (match_operand 0 "x86_64_immediate_operand"))
     530              :     (match_operand 0 "nonmemory_operand")))
     531        19805 : 
     532              : ;; Return true if OP is nonmemory operand representable on x86_64.
     533        19805 : (define_predicate "x86_64_szext_nonmemory_operand"
     534        19805 :   (if_then_else (match_test "TARGET_64BIT")
     535              :     (ior (match_operand 0 "register_operand")
     536              :          (match_operand 0 "x86_64_immediate_operand")
     537              :          (match_operand 0 "x86_64_zext_immediate_operand"))
     538    179314943 :     (match_operand 0 "nonmemory_operand")))
     539              : 
     540              : ;; Return true when operand is PIC expression that can be computed by lea
     541              : ;; operation.
     542              : (define_predicate "pic_32bit_operand"
     543              :   (match_code "const,symbol_ref,label_ref")
     544              : {
     545    179314943 :   if (!flag_pic)
     546              :     return false;
     547              : 
     548              :   /* Rule out relocations that translate into 64bit constants.  */
     549     20872386 :   if (TARGET_64BIT && GET_CODE (op) == CONST)
     550              :     {
     551       183776 :       rtx tmp = XEXP (op, 0);
     552       183776 :       if (GET_CODE (tmp) == PLUS && CONST_INT_P (XEXP (tmp, 1)))
     553       182314 :         tmp = XEXP (tmp, 0);
     554       183776 :       if (GET_CODE (tmp) == UNSPEC
     555         1462 :           && (XINT (tmp, 1) == UNSPEC_GOTOFF
     556         1462 :               || XINT (tmp, 1) == UNSPEC_GOT))
     557              :         return false;
     558              :     }
     559              : 
     560     20871464 :   return symbolic_operand (op, mode);
     561              : })
     562              : 
     563              : ;; Return true if OP is nonmemory operand acceptable by movabs patterns.
     564   1321278790 : (define_predicate "x86_64_movabs_operand"
     565              :   (and (match_operand 0 "nonmemory_operand")
     566   1321278790 :        (not (match_operand 0 "pic_32bit_operand"))))
     567              : 
     568    179314943 : ;; Return true if OP is either a symbol reference or a sum of a symbol
     569    179314943 : ;; reference and a constant.
     570    179314943 : (define_predicate "symbolic_operand"
     571    179314943 :   (match_code "symbol_ref,label_ref,const")
     572              : {
     573     21605643 :   switch (GET_CODE (op))
     574              :     {
     575    179314943 :     case SYMBOL_REF:
     576    179314943 :     case LABEL_REF:
     577       549323 :       return true;
     578              : 
     579       220502 :     case CONST:
     580       220502 :       op = XEXP (op, 0);
     581    522460754 :       if (SYMBOL_REF_P (op)
     582       220502 :           || LABEL_REF_P (op)
     583    522460754 :           || (GET_CODE (op) == UNSPEC
     584         8409 :               && (XINT (op, 1) == UNSPEC_GOT
     585         8409 :                   || XINT (op, 1) == UNSPEC_GOTOFF
     586              :                   || XINT (op, 1) == UNSPEC_SECREL32
     587     21605643 :                   || XINT (op, 1) == UNSPEC_PCREL
     588              :                   || XINT (op, 1) == UNSPEC_GOTPCREL)))
     589              :         return true;
     590       212762 :       if (GET_CODE (op) != PLUS
     591       212093 :           || !CONST_INT_P (XEXP (op, 1)))
     592              :         return false;
     593              : 
     594       212093 :       op = XEXP (op, 0);
     595       212093 :       if (SYMBOL_REF_P (op)
     596       212093 :           || LABEL_REF_P (op))
     597              :         return true;
     598              :       /* Only @GOTOFF and @SECREL32 get offsets.  */
     599         2136 :       if (GET_CODE (op) != UNSPEC
     600         2136 :           || (XINT (op, 1) != UNSPEC_GOTOFF
     601            0 :               && XINT (op, 1) != UNSPEC_SECREL32))
     602              :         return false;
     603              : 
     604         2136 :       op = XVECEXP (op, 0, 0);
     605         2136 :       if (SYMBOL_REF_P (op)
     606         2136 :           || LABEL_REF_P (op))
     607         2136 :         return true;
     608              :       return false;
     609              : 
     610            0 :     default:
     611            0 :       gcc_unreachable ();
     612              :     }
     613              : })
     614              : 
     615              : ;; Return true if OP is a symbolic operand that resolves locally.
     616     31270908 : (define_predicate "local_symbolic_operand"
     617              :   (match_code "const,label_ref,symbol_ref")
     618     31270908 : {
     619      2914957 :   if (GET_CODE (op) == CONST
     620        16183 :       && GET_CODE (XEXP (op, 0)) == PLUS
     621         8528 :       && CONST_INT_P (XEXP (XEXP (op, 0), 1)))
     622         8528 :     op = XEXP (XEXP (op, 0), 0);
     623     21605643 : 
     624      2914957 :   if (LABEL_REF_P (op))
     625              :     return true;
     626              : 
     627      2869417 :   if (!SYMBOL_REF_P (op))
     628     21605643 :     return false;
     629      1283373 : 
     630      2859626 :   if (SYMBOL_REF_TLS_MODEL (op))
     631              :     return false;
     632              : 
     633      2914957 :   /* Dll-imported symbols are always external.  */
     634      2859626 :   if (TARGET_DLLIMPORT_DECL_ATTRIBUTES && SYMBOL_REF_DLLIMPORT_P (op))
     635              :     return false;
     636      2859626 :   if (SYMBOL_REF_LOCAL_P (op))
     637              :     return true;
     638              : 
     639              :   /* There is, however, a not insubstantial body of code in the rest of
     640              :      the compiler that assumes it can just stick the results of
     641              :      ASM_GENERATE_INTERNAL_LABEL in a symbol_ref and have done.  */
     642              :   /* ??? This is a hack.  Should update the body of the compiler to
     643              :      always create a DECL an invoke targetm.encode_section_info.  */
     644        93680 :   if (strncmp (XSTR (op, 0), internal_label_prefix,
     645              :                internal_label_prefix_len) == 0)
     646            0 :     return true;
     647              : 
     648              :   return false;
     649              : })
     650              : 
     651              : (define_predicate "local_func_symbolic_operand"
     652      2923692 :   (match_operand 0 "local_symbolic_operand")
     653              : {
     654      2923692 :   if (GET_CODE (op) == CONST
     655            0 :       && GET_CODE (XEXP (op, 0)) == PLUS
     656            0 :       && CONST_INT_P (XEXP (XEXP (op, 0), 1)))
     657            0 :     op = XEXP (XEXP (op, 0), 0);
     658      2914957 : 
     659      2914969 :   if (SYMBOL_REF_P (op)
     660           12 :       && !SYMBOL_REF_FUNCTION_P (op))
     661            0 :     return false;
     662              : 
     663      2914957 :   return true;
     664      2914957 : })
     665      2811477 : 
     666              : ;; Test for a legitimate @GOTOFF operand.
     667           30 : ;;
     668              : ;; VxWorks does not impose a fixed gap between segments; the run-time
     669           42 : ;; gap can be different from the object-file gap.  We therefore can't
     670           12 : ;; use @GOTOFF unless we are absolutely sure that the symbol is in the
     671              : ;; same segment as the GOT.  Unfortunately, the flexibility of linker
     672              : ;; scripts means that we can't be sure of that in general, so assume
     673              : ;; @GOTOFF is not valid on VxWorks, except with the large code model.
     674      2923625 : ;; The comments above seem to apply only to VxWorks releases before 7.
     675              : (define_predicate "gotoff_operand"
     676      2923625 :   (and (ior (not (match_test "TARGET_VXWORKS_VAROFF"))
     677              :             (match_test "ix86_cmodel == CM_LARGE")
     678      2923625 :             (match_test "ix86_cmodel == CM_LARGE_PIC"))
     679              :        (match_operand 0 "local_symbolic_operand")))
     680              : 
     681              : ;; Test for various thread-local symbols.
     682        30008 : (define_special_predicate "tls_symbolic_operand"
     683              :   (and (match_code "symbol_ref")
     684        30008 :        (match_test "SYMBOL_REF_TLS_MODEL (op)")))
     685              : 
     686              : (define_special_predicate "tls_modbase_operand"
     687              :   (and (match_code "symbol_ref")
     688           72 :        (match_test "op == ix86_tls_module_base ()")))
     689              : 
     690          144 : (define_predicate "tls_address_pattern"
     691              :   (and (match_code "set,parallel,unspec,unspec_volatile")
     692    240182913 :        (match_test "ix86_tls_address_pattern_p (op)")))
     693            0 : 
     694    240182913 : ;; Test for a pc-relative call operand
     695              : (define_predicate "constant_call_address_operand"
     696    240182913 :   (match_code "symbol_ref")
     697    377669771 : {
     698    137486649 :   if (ix86_cmodel == CM_LARGE || ix86_cmodel == CM_LARGE_PIC
     699    137486638 :       || flag_force_indirect_call
     700    274971992 :       || (TARGET_INDIRECT_BRANCH_REGISTER
     701         1022 :           && ix86_nopic_noplt_attribute_p (op)))
     702         1748 :     return false;
     703              :   if (TARGET_DLLIMPORT_DECL_ATTRIBUTES && SYMBOL_REF_DLLIMPORT_P (op))
     704    240182913 :     return false;
     705              :   return true;
     706              : })
     707              : 
     708              : ;; True for any non-virtual and non-eliminable register.  Used in places where
     709    143197686 : ;; instantiation of such a register may cause the pattern to not be recognized.
     710              : (define_predicate "register_no_elim_operand"
     711    137486858 :   (match_operand 0 "register_operand")
     712    280682796 : {
     713     99161824 :   if (SUBREG_P (op))
     714        58537 :     op = SUBREG_REG (op);
     715              : 
     716              :   /* Before reload, we can allow (SUBREG (MEM...)) as a register operand
     717     20737042 :      because it is guaranteed to be reloaded into one.  */
     718     20737042 :   if (MEM_P (op))
     719              :     return true;
     720              : 
     721     20737042 :   return !(op == arg_pointer_rtx
     722     20708696 :            || op == frame_pointer_rtx
     723     20706428 :            || VIRTUAL_REGISTER_P (op));
     724              : })
     725              : 
     726              : ;; Similarly, but include the stack pointer.  This is used
     727     24721201 : ;; to prevent esp from being used as an index reg.
     728              : (define_predicate "register_no_SP_operand"
     729     24721201 :   (match_operand 0 "register_operand")
     730     20737042 : {
     731       329371 :   if (SUBREG_P (op))
     732         7899 :     op = SUBREG_REG (op);
     733              : 
     734       329371 :   /* Before reload, we can allow (SUBREG (MEM...)) as a register operand
     735              :      because it is guaranteed to be reloaded into one.  */
     736       329371 :   if (MEM_P (op))
     737              :     return true;
     738              : 
     739       329371 :   return !(op == arg_pointer_rtx
     740       329371 :            || op == frame_pointer_rtx
     741       329371 :            || op == stack_pointer_rtx
     742       329371 :            || VIRTUAL_REGISTER_P (op));
     743              : })
     744              : 
     745              : ;; P6 processors will jump to the address after the decrement when %esp
     746       366218 : ;; is used as a call operand, so they will execute return address as a code.
     747              : ;; See Pentium Pro errata 70, Pentium 2 errata A33 and Pentium 3 errata E17.
     748       366218 : 
     749       329371 : (define_predicate "call_register_operand"
     750      1854758 :   (if_then_else (match_test "TARGET_64BIT")
     751              :     (match_operand 0 "register_operand")
     752              :     (match_operand 0 "register_no_SP_operand")))
     753      1854758 : 
     754     17936376 : ;; Return false if this is any eliminable register.  Otherwise general_operand.
     755      1854758 : (define_predicate "general_no_elim_operand"
     756     17936376 :   (if_then_else (match_code "reg,subreg")
     757              :     (match_operand 0 "register_no_elim_operand")
     758              :     (match_operand 0 "general_operand")))
     759              : 
     760     11600786 : ;; Return false if this is any eliminable register.  Otherwise
     761              : ;; register_operand or a constant.
     762     11600786 : (define_predicate "nonmemory_no_elim_operand"
     763              :   (ior (match_operand 0 "register_no_elim_operand")
     764              :        (match_operand 0 "immediate_operand")))
     765              : 
     766       630043 : ;; Test for a valid operand for indirect branch.
     767              : (define_predicate "indirect_branch_operand"
     768       630043 :   (ior (match_operand 0 "register_operand")
     769       574444 :        (and (not (match_test "TARGET_INDIRECT_BRANCH_REGISTER"))
     770       574417 :             (not (match_test "TARGET_X32"))
     771              :             (match_operand 0 "memory_operand"))))
     772              : 
     773              : ;; Return true if OP is a memory operands that can be used in sibcalls.
     774        24051 : ;; Since sibcall never returns, we can only use call-clobbered register
     775              : ;; as GOT base.  Allow GOT slot here only with pseudo register as GOT
     776              : ;; base.  Properly handle sibcall over GOT slot with *sibcall_GOT_32
     777              : ;; and *sibcall_value_GOT_32 patterns.
     778              : (define_predicate "sibcall_memory_operand"
     779              :   (match_operand 0 "memory_operand")
     780              : {
     781        24051 :   op = XEXP (op, 0);
     782        24051 :   if (CONSTANT_P (op))
     783              :     return true;
     784        10510 :   if (GET_CODE (op) == PLUS && REG_P (XEXP (op, 0)))
     785              :     {
     786         9484 :       int regno = REGNO (XEXP (op, 0));
     787         9484 :       if (!HARD_REGISTER_NUM_P (regno) || call_used_or_fixed_reg_p (regno))
     788              :         {
     789         7760 :           op = XEXP (op, 1);
     790         7760 :           if (GOT32_symbol_operand (op, VOIDmode))
     791              :             return true;
     792              :         }
     793              :     }
     794              :   return false;
     795              : })
     796              : 
     797              : ;; Return true if OP is a GOT memory operand.
     798      1390009 : (define_predicate "GOT_memory_operand"
     799              :   (and (match_operand 0 "memory_operand")
     800      1414060 :        (match_code "const" "0")
     801        24051 :        (match_code "unspec" "00")
     802          566 :        (match_test "XINT (XEXP (XEXP (op, 0), 0), 1) == UNSPEC_GOTPCREL")))
     803              : 
     804              : ;; Test for a valid operand for a call instruction.
     805          464 : ;; Allow constant call address operands in Pmode only.
     806     49196084 : (define_special_predicate "call_insn_operand"
     807          464 :   (ior (match_test "constant_call_address_operand
     808     55362792 :                      (op, mode == VOIDmode ? mode : Pmode)")
     809              :        (match_operand 0 "call_register_operand")
     810       847889 :        (match_test "satisfies_constraint_Bw (op)")))
     811              : 
     812              : ;; Similarly, but for tail calls, in which we cannot allow memory references.
     813              : (define_special_predicate "sibcall_insn_operand"
     814      1231186 :   (ior (match_test "constant_call_address_operand
     815      1391664 :                      (op, mode == VOIDmode ? mode : Pmode)")
     816      1231186 :        (match_operand 0 "register_no_elim_operand")
     817       122858 :        (match_test "satisfies_constraint_Bs (op)")))
     818              : 
     819              : ;; Return true if OP is a 32-bit GOT symbol operand.
     820              : (define_predicate "GOT32_symbol_operand"
     821         9672 :   (and (match_code "const")
     822              :        (match_code "unspec" "0")
     823         9672 :        (match_test "XINT (XEXP (op, 0), 1) == UNSPEC_GOT")))
     824            0 : 
     825              : ;; Match exactly zero.
     826              : (define_predicate "const0_operand"
     827              :   (match_code "const_int,const_double,const_vector")
     828    139085609 : {
     829    139085609 :   if (mode == VOIDmode)
     830     21635044 :     mode = GET_MODE (op);
     831    139085609 :   return op == CONST0_RTX (mode);
     832              : })
     833              : 
     834              : ;; Match one or a vector with all elements equal to one.
     835    996046587 : (define_predicate "const1_operand"
     836              :   (match_code "const_int,const_double,const_vector")
     837    996046587 : {
     838     11790329 :   if (mode == VOIDmode)
     839     11725190 :     mode = GET_MODE (op);
     840    150875938 :   return op == CONST1_RTX (mode);
     841    139085609 : })
     842    139085609 : 
     843              : ;; Match exactly -1.
     844     13065843 : (define_predicate "constm1_operand"
     845              :   (and (match_code "const_int")
     846    152151452 :        (match_test "op == constm1_rtx")))
     847    139085609 : 
     848     63585741 : ;; Match 0 or -1.
     849     11790329 : (define_predicate "const0_or_m1_operand"
     850     11793228 :   (ior (match_operand 0 "const0_operand")
     851     11790329 :        (match_operand 0 "constm1_operand")))
     852         2899 : 
     853              : ;; Match exactly eight.
     854              : (define_predicate "const8_operand"
     855     11790329 :   (and (match_code "const_int")
     856     11790329 :        (match_test "INTVAL (op) == 8")))
     857        10148 : 
     858       204462 : ;; Match exactly 128.
     859              : (define_predicate "const128_operand"
     860     27767457 :   (and (match_code "const_int")
     861    246617668 :        (match_test "INTVAL (op) == 128")))
     862     27767457 : 
     863    195679071 : ;; Match exactly 0x0FFFFFFFF in anddi as a zero-extension operation
     864              : (define_predicate "const_32bit_mask"
     865      2915909 :   (and (match_code "const_int")
     866      1932894 :        (match_test "trunc_int_for_mode (INTVAL (op), DImode)
     867      4848803 :                     == HOST_WIDE_INT_C (0xffffffff)")))
     868              : 
     869              : ;; Match 2, 4, or 8.  Used for leal multiplicands.
     870              : (define_predicate "const248_operand"
     871       302622 :   (match_code "const_int")
     872              : {
     873       302622 :   HOST_WIDE_INT i = INTVAL (op);
     874       302622 :   return i == 2 || i == 4 || i == 8;
     875              : })
     876              : 
     877              : ;; Match 1, 2, or 3.  Used for lea shift amounts.
     878      1031561 : (define_predicate "const123_operand"
     879              :   (match_code "const_int")
     880      1031561 : {
     881      1265354 :   HOST_WIDE_INT i = INTVAL (op);
     882       233793 :   return i == 1 || i == 2 || i == 3;
     883              : })
     884              : 
     885       233793 : ;; Match 2, 3, 6, or 7
     886       242195 : (define_predicate "const2367_operand"
     887              :   (match_code "const_int")
     888       242195 : {
     889       233793 :   HOST_WIDE_INT i = INTVAL (op);
     890            0 :   return i == 2 || i == 3 || i == 6 || i == 7;
     891              : })
     892              : 
     893            0 : ;; Match 1, 2, 4, or 8
     894            0 : (define_predicate "const1248_operand"
     895              :   (match_code "const_int")
     896            0 : {
     897       109251 :   HOST_WIDE_INT i = INTVAL (op);
     898       109251 :   return i == 1 || i == 2 || i == 4 || i == 8;
     899              : })
     900              : 
     901       109251 : ;; Match 3, 5, or 9.  Used for leal multiplicands.
     902       538648 : (define_predicate "const359_operand"
     903              :   (match_code "const_int")
     904       538648 : {
     905       585609 :   HOST_WIDE_INT i = INTVAL (op);
     906        46961 :   return i == 3 || i == 5 || i == 9;
     907              : })
     908              : 
     909        46961 : ;; Match 4 or 8 to 11.  Used for embedded rounding.
     910       224102 : (define_predicate "const_4_or_8_to_11_operand"
     911              :   (match_code "const_int")
     912       224102 : {
     913       304148 :   HOST_WIDE_INT i = INTVAL (op);
     914        80046 :   return i == 4 || (i >= 8 && i <= 11);
     915              : })
     916              : 
     917        80046 : ;; Match 4 or 8. Used for SAE.
     918        80048 : (define_predicate "const48_operand"
     919              :   (match_code "const_int")
     920        80048 : {
     921        80046 :   HOST_WIDE_INT i = INTVAL (op);
     922        65799 :   return i == 4 || i == 8;
     923              : })
     924              : 
     925        65799 : ;; Match 0 or 1.
     926        65799 : (define_predicate "const_0_to_1_operand"
     927              :   (and (match_code "const_int")
     928        65799 :        (ior (match_test "op == const0_rtx")
     929       302446 :             (match_test "op == const1_rtx"))))
     930              : 
     931              : ;; Match 0 to 3.
     932              : (define_predicate "const_0_to_3_operand"
     933      7863188 :   (and (match_code "const_int")
     934     14932378 :        (match_test "IN_RANGE (INTVAL (op), 0, 3)")))
     935      7863188 : 
     936              : ;; Match 0 to 4.
     937              : (define_predicate "const_0_to_4_operand"
     938            0 :   (and (match_code "const_int")
     939            0 :        (match_test "IN_RANGE (INTVAL (op), 0, 4)")))
     940            0 : 
     941              : ;; Match 0 to 5.
     942              : (define_predicate "const_0_to_5_operand"
     943            0 :   (and (match_code "const_int")
     944            0 :        (match_test "IN_RANGE (INTVAL (op), 0, 5)")))
     945            0 : 
     946              : ;; Match 0 to 7.
     947              : (define_predicate "const_0_to_7_operand"
     948       791294 :   (and (match_code "const_int")
     949      1582573 :        (match_test "IN_RANGE (INTVAL (op), 0, 7)")))
     950       791294 : 
     951              : ;; Match 0 to 15.
     952              : (define_predicate "const_0_to_15_operand"
     953        81823 :   (and (match_code "const_int")
     954       163630 :        (match_test "IN_RANGE (INTVAL (op), 0, 15)")))
     955        81823 : 
     956              : ;; Match 0 to 31.
     957              : (define_predicate "const_0_to_31_operand"
     958        56801 :   (and (match_code "const_int")
     959       111316 :        (match_test "IN_RANGE (INTVAL (op), 0, 31)")))
     960        56801 : 
     961              : ;; Match 0 to 63.
     962              : (define_predicate "const_0_to_63_operand"
     963        30131 :   (and (match_code "const_int")
     964        58260 :        (match_test "IN_RANGE (INTVAL (op), 0, 63)")))
     965        30131 : 
     966              : ;; Match 0 to 127.
     967              : (define_predicate "const_0_to_127_operand"
     968         9797 :   (and (match_code "const_int")
     969        18626 :        (match_test "IN_RANGE (INTVAL (op), 0, 127)")))
     970         9797 : 
     971              : ;; Match 0 to 255.
     972              : (define_predicate "const_0_to_255_operand"
     973      8854428 :   (and (match_code "const_int")
     974     17682953 :        (match_test "IN_RANGE (INTVAL (op), 0, 255)")))
     975      8854428 : 
     976              : ;; Match (0 to 255) * 8
     977              : (define_predicate "const_0_to_255_mul_8_operand"
     978       508709 :   (match_code "const_int")
     979              : {
     980       508709 :   unsigned HOST_WIDE_INT val = INTVAL (op);
     981       508709 :   return val <= 255*8 && val % 8 == 0;
     982              : })
     983              : 
     984              : ;; Match 1 to 255 except multiples of 8
     985       508711 : (define_predicate "const_0_to_255_not_mul_8_operand"
     986              :   (match_code "const_int")
     987       508711 : {
     988            9 :   unsigned HOST_WIDE_INT val = INTVAL (op);
     989       930829 :   return val <= 255 && val % 8 != 0;
     990              : })
     991              : 
     992       930843 : ;; Return true if OP is CONST_INT >= 1 and <= 31 (a valid operand
     993       930843 : ;; for shift & compare patterns, as shifting by 0 does not change flags).
     994              : (define_predicate "const_1_to_31_operand"
     995       930843 :   (and (match_code "const_int")
     996       702047 :        (match_test "IN_RANGE (INTVAL (op), 1, 31)")))
     997              : 
     998              : ;; Return true if OP is CONST_INT >= 1 and <= 63 (a valid operand
     999              : ;; for 64bit shift & compare patterns, as shifting by 0 does not change flags).
    1000       302638 : (define_predicate "const_1_to_63_operand"
    1001              :   (and (match_code "const_int")
    1002       302638 :        (match_test "IN_RANGE (INTVAL (op), 1, 63)")))
    1003              : 
    1004              : ;; Match 2 or 3.
    1005              : (define_predicate "const_2_to_3_operand"
    1006        73255 :   (and (match_code "const_int")
    1007       146510 :        (match_test "IN_RANGE (INTVAL (op), 2, 3)")))
    1008        73255 : 
    1009              : ;; Match 4 to 5.
    1010              : (define_predicate "const_4_to_5_operand"
    1011         5491 :   (and (match_code "const_int")
    1012        10982 :        (match_test "IN_RANGE (INTVAL (op), 4, 5)")))
    1013         5491 : 
    1014              : ;; Match 4 to 7.
    1015              : (define_predicate "const_4_to_7_operand"
    1016      1118675 :   (and (match_code "const_int")
    1017      2237350 :        (match_test "IN_RANGE (INTVAL (op), 4, 7)")))
    1018      1118675 : 
    1019              : ;; Match 6 to 7.
    1020              : (define_predicate "const_6_to_7_operand"
    1021          701 :   (and (match_code "const_int")
    1022         1402 :        (match_test "IN_RANGE (INTVAL (op), 6, 7)")))
    1023          701 : 
    1024              : ;; Match 8 to 9.
    1025              : (define_predicate "const_8_to_9_operand"
    1026          513 :   (and (match_code "const_int")
    1027         1026 :        (match_test "IN_RANGE (INTVAL (op), 8, 9)")))
    1028          513 : 
    1029              : ;; Match 8 to 11.
    1030              : (define_predicate "const_8_to_11_operand"
    1031        35585 :   (and (match_code "const_int")
    1032        71170 :        (match_test "IN_RANGE (INTVAL (op), 8, 11)")))
    1033        35585 : 
    1034              : ;; Match 8 to 15.
    1035              : (define_predicate "const_8_to_15_operand"
    1036        40160 :   (and (match_code "const_int")
    1037        80320 :        (match_test "IN_RANGE (INTVAL (op), 8, 15)")))
    1038        40160 : 
    1039              : ;; Match 10 to 11.
    1040              : (define_predicate "const_10_to_11_operand"
    1041          267 :   (and (match_code "const_int")
    1042          534 :        (match_test "IN_RANGE (INTVAL (op), 10, 11)")))
    1043          267 : 
    1044              : ;; Match 12 to 13.
    1045              : (define_predicate "const_12_to_13_operand"
    1046          266 :   (and (match_code "const_int")
    1047          532 :        (match_test "IN_RANGE (INTVAL (op), 12, 13)")))
    1048          266 : 
    1049              : ;; Match 12 to 15.
    1050              : (define_predicate "const_12_to_15_operand"
    1051        23618 :   (and (match_code "const_int")
    1052        47236 :        (match_test "IN_RANGE (INTVAL (op), 12, 15)")))
    1053        23618 : 
    1054              : ;; Match 14 to 15.
    1055              : (define_predicate "const_14_to_15_operand"
    1056          266 :   (and (match_code "const_int")
    1057          532 :        (match_test "IN_RANGE (INTVAL (op), 14, 15)")))
    1058          266 : 
    1059              : ;; Match 16 to 19.
    1060              : (define_predicate "const_16_to_19_operand"
    1061          924 :   (and (match_code "const_int")
    1062         1848 :        (match_test "IN_RANGE (INTVAL (op), 16, 19)")))
    1063          924 : 
    1064              : ;; Match 16 to 31.
    1065              : (define_predicate "const_16_to_31_operand"
    1066        10185 :   (and (match_code "const_int")
    1067        20370 :        (match_test "IN_RANGE (INTVAL (op), 16, 31)")))
    1068        10185 : 
    1069              : ;; Match 20 to 23.
    1070              : (define_predicate "const_20_to_23_operand"
    1071          532 :   (and (match_code "const_int")
    1072         1064 :        (match_test "IN_RANGE (INTVAL (op), 20, 23)")))
    1073          532 : 
    1074              : ;; Match 24 to 27.
    1075              : (define_predicate "const_24_to_27_operand"
    1076          532 :   (and (match_code "const_int")
    1077         1064 :        (match_test "IN_RANGE (INTVAL (op), 24, 27)")))
    1078          532 : 
    1079              : ;; Match 28 to 31.
    1080              : (define_predicate "const_28_to_31_operand"
    1081          532 :   (and (match_code "const_int")
    1082         1064 :        (match_test "IN_RANGE (INTVAL (op), 28, 31)")))
    1083          532 : 
    1084              : (define_predicate "cmpps_imm_operand"
    1085              :   (ior (match_operand 0 "const_0_to_7_operand")
    1086         4063 :        (and (match_test "TARGET_AVX")
    1087              :             (match_operand 0 "const_0_to_31_operand"))))
    1088        60262 : 
    1089              : ;; True if this is a constant appropriate for an increment or decrement.
    1090    102947062 : (define_predicate "incdec_operand"
    1091              :   (match_code "const_int")
    1092              : {
    1093              :   /* On Pentium4, the inc and dec operations causes extra dependency on flag
    1094              :      registers, since carry flag is not set.  */
    1095    102947062 :   if (!TARGET_USE_INCDEC && !optimize_insn_for_size_p ())
    1096              :     return false;
    1097      2636083 :   return op == const1_rtx || op == constm1_rtx;
    1098              : })
    1099              : 
    1100              : ;; True for registers, or const_int_operand, used to vec_setm expander.
    1101    128334364 : (define_predicate "vec_setm_sse41_operand"
    1102              :   (ior (and (match_operand 0 "register_operand")
    1103    231282308 :             (match_test "TARGET_SSE4_1"))
    1104    102947062 :        (match_code "const_int")))
    1105              : 
    1106              : (define_predicate "vec_setm_avx2_operand"
    1107              :   (ior (and (match_operand 0 "register_operand")
    1108         1053 :             (match_test "TARGET_AVX2"))
    1109            0 :        (match_code "const_int")))
    1110         1357 : 
    1111              : (define_predicate "vec_setm_mmx_operand"
    1112              :   (ior (and (match_operand 0 "register_operand")
    1113           22 :             (match_test "TARGET_SSE4_1")
    1114          260 :             (match_test "TARGET_MMX_WITH_SSE"))
    1115          260 :        (match_code "const_int")))
    1116              : 
    1117              : ;; True for registers, or 1 or -1.  Used to optimize double-word shifts.
    1118              : (define_predicate "reg_or_pm1_operand"
    1119      4442380 :   (ior (match_operand 0 "register_operand")
    1120              :        (and (match_code "const_int")
    1121      4442380 :             (ior (match_test "op == const1_rtx")
    1122       259777 :                  (match_test "op == constm1_rtx")))))
    1123       243432 : 
    1124              : ;; True for registers, or (not: registers).  Used to optimize 3-operand
    1125              : ;; bitwise operation.
    1126              : (define_predicate "regmem_or_bitnot_regmem_operand"
    1127       727695 :   (ior (match_operand 0 "nonimmediate_operand")
    1128              :        (and (match_code "not")
    1129       727695 :             (match_test "nonimmediate_operand (XEXP (op, 0), mode)"))))
    1130        29116 : 
    1131              : ;; True for expressions valid for 3-operand ternlog instructions.
    1132              : (define_predicate "ternlog_operand"
    1133              :   (and (match_code "not,and,ior,xor")
    1134      2353392 :        (match_test "ix86_ternlog_operand_p (op)")))
    1135       258304 : 
    1136     66540476 : ;; True if OP is acceptable as operand of DImode shift expander.
    1137              : (define_predicate "shiftdi_operand"
    1138      1374879 :   (if_then_else (match_test "TARGET_64BIT")
    1139      3728271 :     (match_operand 0 "nonimmediate_operand")
    1140      2353392 :     (match_operand 0 "register_operand")))
    1141      1374879 : 
    1142      2996006 : (define_predicate "ashldi_input_operand"
    1143       642614 :   (if_then_else (match_test "TARGET_64BIT")
    1144       642614 :     (match_operand 0 "nonimmediate_operand")
    1145              :     (match_operand 0 "reg_or_pm1_operand")))
    1146      2353392 : 
    1147       588033 : ;; Return true if OP is a vector load from the constant pool with just
    1148              : ;; the first element nonzero.
    1149              : (define_predicate "zero_extended_scalar_load_operand"
    1150              :   (match_code "mem")
    1151              : {
    1152       588033 :   unsigned n_elts;
    1153       588033 :   op = avoid_constant_pool_reference (op);
    1154              : 
    1155       588033 :   if (!CONST_VECTOR_P (op))
    1156              :     return false;
    1157              : 
    1158        98532 :   n_elts = CONST_VECTOR_NUNITS (op);
    1159              : 
    1160       194365 :   for (n_elts--; n_elts > 0; n_elts--)
    1161              :     {
    1162       143457 :       rtx elt = CONST_VECTOR_ELT (op, n_elts);
    1163       286914 :       if (elt != CONST0_RTX (GET_MODE_INNER (GET_MODE (op))))
    1164              :         return false;
    1165              :     }
    1166              :   return true;
    1167              : })
    1168              : 
    1169              : /* Return true if operand is a float vector constant that is all ones. */
    1170      1966592 : (define_predicate "float_vector_all_ones_operand"
    1171              :   (match_code "const_vector,mem")
    1172       588033 : {
    1173      2017500 :   mode = GET_MODE (op);
    1174        50908 :   if (!FLOAT_MODE_P (mode)
    1175     13537364 :       || (MEM_P (op)
    1176     11633054 :           && (!SYMBOL_REF_P (XEXP (op, 0))
    1177      1646805 :               || !CONSTANT_POOL_ADDRESS_P (XEXP (op, 0)))))
    1178     16367918 :     return false;
    1179              : 
    1180      3303472 :   if (MEM_P (op))
    1181              :     {
    1182      1399162 :       op = get_pool_constant (XEXP (op, 0));
    1183      1399162 :       if (!CONST_VECTOR_P (op))
    1184              :         return false;
    1185              : 
    1186      1399158 :       if (GET_MODE (op) != mode
    1187         5973 :          && INTEGRAL_MODE_P (GET_MODE (op))
    1188         5973 :          && op == CONSTM1_RTX (GET_MODE (op)))
    1189              :         return true;
    1190              :     }
    1191              : 
    1192      3303468 :   rtx first = XVECEXP (op, 0, 0);
    1193     10726190 :   for (int i = 1; i != GET_MODE_NUNITS (GET_MODE (op)); i++)
    1194              :     {
    1195      4548571 :       rtx tmp = XVECEXP (op, 0, i);
    1196      4548571 :       if (!rtx_equal_p (tmp, first))
    1197              :         return false;
    1198              :     }
    1199       814524 :   if (GET_MODE (first) == E_SFmode)
    1200              :     {
    1201       455931 :       long l;
    1202       455931 :       REAL_VALUE_TO_TARGET_SINGLE (*CONST_DOUBLE_REAL_VALUE (first), l);
    1203       455931 :       return (l & 0xffffffff) == 0xffffffff;
    1204              :     }
    1205       358593 :   else if (GET_MODE (first) == E_DFmode)
    1206              :     {
    1207       351635 :       long l[2];
    1208       351635 :       REAL_VALUE_TO_TARGET_DOUBLE (*CONST_DOUBLE_REAL_VALUE (first), l);
    1209       351635 :       return ((l[0] & 0xffffffff) == 0xffffffff
    1210       351635 :              && (l[1] & 0xffffffff) == 0xffffffff);
    1211              :     }
    1212              :   else
    1213              :     return false;
    1214              : })
    1215              : 
    1216              : /* Return true if operand is an integral vector constant that is all ones. */
    1217     55876728 : (define_predicate "vector_all_ones_operand"
    1218              :   (and (match_code "const_vector")
    1219     69653662 :        (match_test "INTEGRAL_MODE_P (GET_MODE (op))")
    1220     11937669 :        (match_test "op == CONSTM1_RTX (GET_MODE (op))")))
    1221      1093703 : 
    1222     16367918 : /* Return true if operand is a vector constant that is all ones. */
    1223     16367918 : (define_predicate "int_float_vector_all_ones_operand"
    1224              :   (ior (match_operand 0 "vector_all_ones_operand")
    1225      9159303 :        (match_operand 0 "float_vector_all_ones_operand")
    1226            0 :        (match_test "op == constm1_rtx")))
    1227      9159303 : 
    1228     16367918 : /* Return true if operand is an 128/256bit all ones vector
    1229         3072 :    that zero-extends to 256/512bit.  */
    1230              : (define_predicate "vector_all_ones_zero_extend_half_operand"
    1231     12223994 :   (match_code "const_vector")
    1232              : {
    1233    176415397 :   mode = GET_MODE (op);
    1234     12223994 :   if (GET_MODE_CLASS (mode) != MODE_VECTOR_INT
    1235    187000038 :       || (GET_MODE_SIZE (mode) != 32
    1236     10282743 :           && GET_MODE_SIZE (mode) != 64))
    1237              :     return false;
    1238              : 
    1239       470543 :   int nelts = CONST_VECTOR_NUNITS (op);
    1240       543638 :   for (int i = 0; i != nelts; i++)
    1241              :     {
    1242       542630 :       rtx elt = CONST_VECTOR_ELT (op, i);
    1243       542630 :       if (i < nelts / 2
    1244      1066487 :           && elt != CONSTM1_RTX (GET_MODE_INNER (mode)))
    1245              :         return false;
    1246        84157 :       if (i >= nelts / 2
    1247       102930 :           && elt != CONST0_RTX (GET_MODE_INNER (mode)))
    1248              :         return false;
    1249              :     }
    1250              :   return true;
    1251              : })
    1252              : 
    1253              : /* Return true if operand is an 128bit all ones vector
    1254    177695931 :    that zero extends to 512bit.  */
    1255              : (define_predicate "vector_all_ones_zero_extend_quarter_operand"
    1256     12223994 :   (match_code "const_vector")
    1257    177696939 : {
    1258         1008 :   mode = GET_MODE (op);
    1259     12222986 :   if (GET_MODE_CLASS (mode) != MODE_VECTOR_INT
    1260     10583633 :       || GET_MODE_SIZE (mode) != 64)
    1261              :     return false;
    1262     12222986 : 
    1263       168426 :   int nelts = CONST_VECTOR_NUNITS (op);
    1264       182264 :   for (int i = 0; i != nelts; i++)
    1265              :     {
    1266       182172 :       rtx elt = CONST_VECTOR_ELT (op, i);
    1267       182172 :       if (i < nelts / 4
    1268       360811 :           && elt != CONSTM1_RTX (GET_MODE_INNER (mode)))
    1269              :         return false;
    1270        16501 :       if (i >= nelts / 4
    1271        20034 :           && elt != CONST0_RTX (GET_MODE_INNER (mode)))
    1272              :         return false;
    1273              :     }
    1274              :   return true;
    1275              : })
    1276              : 
    1277              : ; Return true when OP is operand acceptable for vector memory operand.
    1278    177694923 : ; Only AVX can have misaligned memory operand.
    1279              : (define_predicate "vector_memory_operand"
    1280     12222986 :   (and (match_operand 0 "memory_operand")
    1281    178801110 :        (ior (match_test "TARGET_AVX")
    1282      1106187 :             (match_test "MEM_ALIGN (op) >= GET_MODE_ALIGNMENT (mode)"))))
    1283              : 
    1284              : ; Return true when OP is register_operand or vector_memory_operand.
    1285              : (define_predicate "vector_operand"
    1286     20166695 :   (ior (match_operand 0 "register_operand")
    1287              :        (match_operand 0 "vector_memory_operand")))
    1288     20166695 : 
    1289              : ; Return true when OP is register_operand, vector_memory_operand
    1290              : ; or const_vector.
    1291              : (define_predicate "vector_or_const_vector_operand"
    1292        99196 :   (ior (match_operand 0 "register_operand")
    1293              :        (match_operand 0 "vector_memory_operand")
    1294        99196 :        (match_code "const_vector")))
    1295        45767 : 
    1296              : (define_predicate "bcst_mem_operand"
    1297              :   (and (match_code "vec_duplicate")
    1298        14419 :        (and (match_test "TARGET_AVX512F")
    1299    168321083 :             (ior (match_test "TARGET_AVX512VL")
    1300         9036 :                  (match_test "GET_MODE_SIZE (GET_MODE (op)) == 64")))
    1301       152879 :        (match_test "VALID_BCST_MODE_P (GET_MODE_INNER (GET_MODE (op)))")
    1302        13471 :        (match_test "GET_MODE (XEXP (op, 0))
    1303        40402 :                     == GET_MODE_INNER (GET_MODE (op))")
    1304    168335341 :        (match_test "memory_operand (XEXP (op, 0), GET_MODE (XEXP (op, 0)))")))
    1305         5316 : 
    1306              : ; Return true when OP is bcst_mem_operand or vector_memory_operand.
    1307              : (define_predicate "bcst_vector_operand"
    1308              :   (ior (match_operand 0 "vector_operand")
    1309      5416825 :        (match_operand 0 "bcst_mem_operand")))
    1310              : 
    1311      5416825 : ;; Return true when OP is either nonimmediate operand, or any
    1312              : ;; CONST_VECTOR.
    1313              : (define_predicate "nonimmediate_or_const_vector_operand"
    1314              :   (ior (match_operand 0 "nonimmediate_operand")
    1315        93680 :        (match_code "const_vector")))
    1316              : 
    1317        93680 : (define_predicate "nonimmediate_or_const_vec_dup_operand"
    1318        15061 :   (ior (match_operand 0 "nonimmediate_operand")
    1319           46 :        (match_test "const_vec_duplicate_p (op)")))
    1320           46 : 
    1321              : ;; Return true when OP is either register operand, or any
    1322           94 : ;; CONST_VECTOR.
    1323              : (define_predicate "reg_or_const_vector_operand"
    1324           94 :   (ior (match_operand 0 "register_operand")
    1325              :        (match_code "const_vector")))
    1326          275 : 
    1327          173 : ;; Return true when OP is CONST_VECTOR which can be converted to a
    1328              : ;; sign extended 32-bit integer.
    1329              : (define_predicate "x86_64_const_vector_operand"
    1330              :   (match_code "const_vector")
    1331       159283 : {
    1332       159283 :   if (mode == VOIDmode)
    1333            0 :     mode = GET_MODE (op);
    1334       159283 :   else if (GET_MODE (op) != mode)
    1335              :     return false;
    1336       375019 :   if (GET_MODE_SIZE (mode) > UNITS_PER_WORD)
    1337              :     return false;
    1338       116273 :   HOST_WIDE_INT val = ix86_convert_const_vector_to_integer (op, mode);
    1339       116273 :   return trunc_int_for_mode (val, SImode) == val;
    1340              : })
    1341              : 
    1342              : (define_predicate "nonimmediate_or_x86_64_const_vector_operand"
    1343       983190 :   (ior (match_operand 0 "nonimmediate_operand")
    1344              :        (match_operand 0 "x86_64_const_vector_operand")))
    1345       159283 : 
    1346      1065521 : ;; Return true when OP is nonimmediate or standard SSE constant.
    1347        82331 : (define_predicate "nonimmediate_or_sse_const_operand"
    1348              :   (ior (match_operand 0 "nonimmediate_operand")
    1349     25510400 :        (match_test "standard_sse_constant_p (op, mode)")))
    1350      2833389 : 
    1351         6681 : ;; Return true if OP is a register or a zero.
    1352              : (define_predicate "reg_or_0_operand"
    1353         6681 :   (ior (match_operand 0 "register_operand")
    1354       396243 :        (match_operand 0 "const0_operand")))
    1355              : 
    1356       396243 : ; Return true when OP is a nonimmediate or zero.
    1357     95344109 : (define_predicate "nonimm_or_0_operand"
    1358              :   (ior (match_operand 0 "nonimmediate_operand")
    1359    118021120 :        (match_operand 0 "const0_operand")))
    1360    127204785 : 
    1361              : ; Return true when OP is a nonimmediate or zero or all ones.
    1362    127204785 : (define_predicate "nonimm_or_0_or_1s_operand"
    1363              :   (ior (match_operand 0 "nonimmediate_operand")
    1364              :        (match_operand 0 "const0_operand")
    1365              :        (match_operand 0 "int_float_vector_all_ones_operand")))
    1366        82227 : 
    1367              : ;; Return true for RTX codes that force SImode address.
    1368        82227 : (define_predicate "SImode_address_operand"
    1369              :   (match_code "subreg,zero_extend,and"))
    1370              : 
    1371              : ;; Return true if op is a valid address for LEA, and does not contain
    1372    276167105 : ;; a segment override.  Defined as a special predicate to allow
    1373              : ;; mode-less const_int operands pass to address_operand.
    1374    276167105 : (define_special_predicate "address_no_seg_operand"
    1375    184613284 :   (match_test "address_operand (op, VOIDmode)")
    1376     67767958 : {
    1377     68145519 :   struct ix86_address parts;
    1378     68145519 :   int ok;
    1379       377561 : 
    1380     67806238 :   if (!CONST_INT_P (op)
    1381     64835311 :       && mode != VOIDmode
    1382     64835311 :       && GET_MODE (op) != mode)
    1383       377561 :     return false;
    1384       377561 : 
    1385     67767894 :   ok = ix86_decompose_address (op, &parts);
    1386     67767894 :   gcc_assert (ok);
    1387     67767894 :   return parts.seg == ADDR_SPACE_GENERIC;
    1388     67767958 : })
    1389              : 
    1390              : ;; Return true if op if a valid base register, displacement or
    1391    116845326 : ;; sum of base register and displacement for VSIB addressing.
    1392              : (define_predicate "vsib_address_operand"
    1393    116883606 :   (match_test "address_operand (op, VOIDmode)")
    1394        77321 : {
    1395        37570 :   struct ix86_address parts;
    1396        38280 :   int ok;
    1397        38280 :   rtx disp;
    1398              : 
    1399        38280 :   ok = ix86_decompose_address (op, &parts);
    1400        38280 :   gcc_assert (ok);
    1401        64148 :   if (parts.index || parts.seg != ADDR_SPACE_GENERIC)
    1402        25868 :     return false;
    1403              : 
    1404              :   /* VSIB addressing doesn't support (%rip).  */
    1405        38260 :   if (parts.disp)
    1406     26124853 :     {
    1407         6329 :       disp = parts.disp;
    1408         6329 :       if (GET_CODE (disp) == CONST)
    1409              :         {
    1410          148 :           disp = XEXP (disp, 0);
    1411          148 :           if (GET_CODE (disp) == PLUS)
    1412          148 :             disp = XEXP (disp, 0);
    1413          148 :           if (GET_CODE (disp) == UNSPEC)
    1414            0 :             switch (XINT (disp, 1))
    1415              :               {
    1416              :               case UNSPEC_GOTPCREL:
    1417              :               case UNSPEC_PCREL:
    1418              :               case UNSPEC_GOTNTPOFF:
    1419              :                 return false;
    1420              :               }
    1421              :         }
    1422         6329 :       if (TARGET_64BIT
    1423         6329 :           && flag_pic
    1424            0 :           && (SYMBOL_REF_P (disp)
    1425            0 :               || LABEL_REF_P (disp)))
    1426            0 :         return false;
    1427              :     }
    1428              : 
    1429              :   return true;
    1430              : })
    1431              : 
    1432              : (define_predicate "vsib_mem_operator"
    1433        39061 :   (match_code "mem"))
    1434              : 
    1435        39061 : ;; Return true if the rtx is known to be at least 32 bits aligned.
    1436              : (define_predicate "aligned_operand"
    1437              :   (match_operand 0 "general_operand")
    1438              : {
    1439     26124853 :   struct ix86_address parts;
    1440     26124853 :   int ok;
    1441              : 
    1442              :   /* Registers and immediate operands are always "aligned".  */
    1443     26124853 :   if (!MEM_P (op))
    1444              :     return true;
    1445              : 
    1446              :   /* All patterns using aligned_operand on memory operands ends up
    1447              :      in promoting memory operand to 64bit and thus causing memory mismatch.  */
    1448      8267746 :   if (TARGET_MEMORY_MISMATCH_STALL && !optimize_insn_for_size_p ())
    1449              :     return false;
    1450              : 
    1451              :   /* Don't even try to do any aligned optimizations with volatiles.  */
    1452       123793 :   if (MEM_VOLATILE_P (op))
    1453              :     return false;
    1454              : 
    1455       117828 :   if (MEM_ALIGN (op) >= 32)
    1456              :     return true;
    1457              : 
    1458        46015 :   op = XEXP (op, 0);
    1459              : 
    1460              :   /* Pushes and pops are only valid on the stack pointer.  */
    1461        46015 :   if (GET_CODE (op) == PRE_DEC
    1462        46015 :       || GET_CODE (op) == POST_INC)
    1463              :     return true;
    1464              : 
    1465              :   /* Decode the address.  */
    1466        46015 :   ok = ix86_decompose_address (op, &parts);
    1467        46015 :   gcc_assert (ok);
    1468              : 
    1469        46015 :   if (parts.base && SUBREG_P (parts.base))
    1470            0 :     parts.base = SUBREG_REG (parts.base);
    1471        46015 :   if (parts.index && SUBREG_P (parts.index))
    1472            0 :     parts.index = SUBREG_REG (parts.index);
    1473              : 
    1474              :   /* Look for some component that isn't known to be aligned.  */
    1475        46015 :   if (parts.index)
    1476              :     {
    1477         3264 :       if (REGNO_POINTER_ALIGN (REGNO (parts.index)) * parts.scale < 32)
    1478              :         return false;
    1479              :     }
    1480        42751 :   if (parts.base)
    1481              :     {
    1482        35788 :       if (REGNO_POINTER_ALIGN (REGNO (parts.base)) < 32)
    1483              :         return false;
    1484              :     }
    1485        13355 :   if (parts.disp)
    1486              :     {
    1487        13355 :       if (!CONST_INT_P (parts.disp)
    1488         6490 :           || (INTVAL (parts.disp) & 3))
    1489        13065 :         return false;
    1490              :     }
    1491              : 
    1492              :   /* Didn't find one -- this must be an aligned address.  */
    1493              :   return true;
    1494              : })
    1495              : 
    1496              : ;; Return true if OP is memory operand with a displacement.
    1497     26632205 : (define_predicate "memory_displacement_operand"
    1498              :   (match_operand 0 "memory_operand")
    1499     52757058 : {
    1500     26124853 :   struct ix86_address parts;
    1501            0 :   int ok;
    1502              : 
    1503            0 :   ok = ix86_decompose_address (XEXP (op, 0), &parts);
    1504            0 :   gcc_assert (ok);
    1505            0 :   return parts.disp != NULL_RTX;
    1506              : })
    1507              : 
    1508              : ;; Return true if OP is memory operand with a displacement only.
    1509            0 : (define_predicate "memory_displacement_only_operand"
    1510              :   (match_operand 0 "memory_operand")
    1511            0 : {
    1512            0 :   struct ix86_address parts;
    1513     39137983 :   int ok;
    1514              : 
    1515     39137983 :   if (TARGET_64BIT)
    1516     39137983 :     return false;
    1517              : 
    1518     19109432 :   ok = ix86_decompose_address (XEXP (op, 0), &parts);
    1519     19109432 :   gcc_assert (ok);
    1520              : 
    1521     19109432 :   if (parts.base || parts.index)
    1522              :     return false;
    1523              : 
    1524       239379 :   return parts.disp != NULL_RTX;
    1525              : })
    1526              : 
    1527              : ;; Return true if OP is memory operand that cannot be represented
    1528     60738427 : ;; by the modRM array.
    1529              : (define_predicate "long_memory_operand"
    1530     99876410 :   (and (match_operand 0 "memory_operand")
    1531     39137983 :        (match_test "memory_address_length (op, false)")))
    1532              : 
    1533              : ;; Return true if OP is a comparison operator that can be issued by fcmov.
    1534              : (define_predicate "fcmov_comparison_operator"
    1535        70177 :   (match_operand 0 "comparison_operator")
    1536              : {
    1537            0 :   machine_mode inmode = GET_MODE (XEXP (op, 0));
    1538        70177 :   enum rtx_code code = GET_CODE (op);
    1539              : 
    1540        70177 :   if (inmode == CCFPmode)
    1541         9926 :     code = ix86_fp_compare_code_to_integer (code);
    1542              : 
    1543              :   /* i387 supports just limited amount of conditional codes.  */
    1544        70177 :   switch (code)
    1545              :     {
    1546         2414 :     case GEU: case LTU:
    1547         2414 :       if (inmode == CCCmode || inmode == CCGZmode)
    1548              :         return true;
    1549              :       /* FALLTHRU */
    1550         7848 :     case GTU: case LEU:
    1551         7848 :       if (inmode == CCmode || inmode == CCFPmode)
    1552              :         return true;
    1553              :       return false;
    1554              :     case ORDERED: case UNORDERED:
    1555              :     case EQ: case NE:
    1556              :       return true;
    1557              :     default:
    1558              :       return false;
    1559              :     }
    1560              : })
    1561              : 
    1562              : ;; Return true if OP is a comparison that can be used in the CMPSS/CMPPS insns.
    1563        70177 : ;; The first set are supported directly; the second set can't be done with
    1564              : ;; full IEEE support, i.e. NaNs.
    1565       140354 : 
    1566        70177 : (define_predicate "sse_comparison_operator"
    1567              :   (ior (match_code "eq,ne,lt,le,unordered,unge,ungt,ordered")
    1568       398758 :        (and (match_test "TARGET_AVX")
    1569       398758 :             (match_code "ge,gt,uneq,unle,unlt,ltgt"))))
    1570       513243 : 
    1571              : ;; SSE2 doesn't have quiet vector compare for UNLT/UNLE/UNGT/UNGE, so reject
    1572       513243 : ;; them in the packed FP vec_cmp expanders when trapping math is in effect
    1573       104596 : ;; and NaNs are honored
    1574              : 
    1575       104596 : (define_predicate "ix86_fp_vec_cmp_operator"
    1576              :   (and (match_operand 0 "comparison_operator")
    1577              :        (ior (not (match_code "unlt,unle,ungt,unge"))
    1578         8407 :             (match_test "TARGET_AVX")
    1579        15460 :             (not (match_test "flag_trapping_math"))
    1580         7697 :             (not (match_test "HONOR_NANS (GET_MODE (XEXP (op, 0)))")))))
    1581              : 
    1582              : (define_predicate "ix86_comparison_int_operator"
    1583              :   (match_code "ne,eq,ge,gt,le,lt"))
    1584       218178 : 
    1585              : (define_predicate "ix86_comparison_uns_operator"
    1586       218178 :   (match_code "ne,eq,geu,gtu,leu,ltu"))
    1587              : 
    1588       218178 : (define_predicate "bt_comparison_operator"
    1589       218178 :   (match_code "ne,eq"))
    1590       218178 : 
    1591       218178 : (define_predicate "shr_comparison_operator"
    1592       218178 :   (match_code "gtu,leu"))
    1593       218178 : 
    1594       218178 : (define_predicate "add_comparison_operator"
    1595              :   (match_code "geu,ltu"))
    1596              : 
    1597              : (define_predicate "ieee_maxmin_comparison_operator"
    1598       218178 :   (match_code "lt,gt"))
    1599       218178 : 
    1600              : ;; Return true if OP is a valid comparison operator in valid mode.
    1601              : (define_predicate "ix86_comparison_operator"
    1602              :   (match_operand 0 "comparison_operator")
    1603       113276 : {
    1604    102363065 :   machine_mode inmode = GET_MODE (XEXP (op, 0));
    1605       113276 :   enum rtx_code code = GET_CODE (op);
    1606              : 
    1607    102476341 :   if (inmode == CCFPmode)
    1608      6965711 :     return ix86_trivial_fp_comparison_operator (op, mode);
    1609       113276 : 
    1610     95397354 :   switch (code)
    1611       113276 :     {
    1612     73364676 :     case EQ: case NE:
    1613     73251400 :       if (inmode == CCGZmode)
    1614            0 :         return false;
    1615              :       return true;
    1616      4327151 :     case GE: case LT:
    1617      4327151 :       if (inmode == CCmode || inmode == CCGCmode
    1618      2479161 :           || inmode == CCGOCmode || inmode == CCNOmode || inmode == CCGZmode)
    1619      3817280 :         return true;
    1620              :       return false;
    1621      7808983 :     case GEU: case LTU:
    1622      7808983 :       if (inmode == CCCmode || inmode == CCGZmode)
    1623              :         return true;
    1624     64109453 :       /* FALLTHRU */
    1625     11018950 :     case GTU: case LEU:
    1626     11018950 :       if (inmode == CCmode)
    1627      9770475 :         return true;
    1628     52803627 :       return false;
    1629         3493 :     case ORDERED: case UNORDERED:
    1630         3493 :       if (inmode == CCmode)
    1631         3310 :         return true;
    1632     52803627 :       return false;
    1633     52803627 :     case GT: case LE:
    1634      6294700 :       if (inmode == CCmode || inmode == CCGCmode || inmode == CCNOmode)
    1635      5518067 :         return true;
    1636              :       return false;
    1637       847162 :     default:
    1638              :       return false;
    1639       847162 :     }
    1640              : })
    1641       847162 : 
    1642       847162 : ;; Return true if OP is a valid comparison operator
    1643    118139397 : ;; testing carry flag to be set.
    1644              : (define_predicate "ix86_carry_flag_operator"
    1645    219655300 :   (match_code "ltu,unlt")
    1646    102363065 : {
    1647      1742434 :   machine_mode inmode = GET_MODE (XEXP (op, 0));
    1648       847162 :   enum rtx_code code = GET_CODE (op);
    1649              : 
    1650       895272 :   if (inmode == CCFPmode)
    1651        14883 :     code = ix86_fp_compare_code_to_integer (code);
    1652      1375699 :   else if (inmode != CCmode && inmode != CCCmode && inmode != CCGZmode)
    1653              :     return false;
    1654      1375699 : 
    1655       699955 :   return code == LTU;
    1656      1375699 : })
    1657      1375699 : 
    1658      1375699 : ;; Return true if OP is a valid comparison operator
    1659      3782921 : ;; testing carry flag to be unset.
    1660              : (define_predicate "ix86_carry_flag_unset_operator"
    1661      3782921 :   (match_code "geu,ge")
    1662      1375699 : {
    1663      1375699 :   machine_mode inmode = GET_MODE (XEXP (op, 0));
    1664       897631 :   enum rtx_code code = GET_CODE (op);
    1665       895272 : 
    1666         2359 :   if (inmode == CCFPmode)
    1667           93 :     code = ix86_fp_compare_code_to_integer (code);
    1668              :   else if (inmode != CCmode && inmode != CCCmode && inmode != CCGZmode)
    1669         1466 :     return false;
    1670       895272 : 
    1671       437160 :   return code == GEU;
    1672         1466 : })
    1673         1466 : 
    1674              : ;; Return true if this comparison only requires testing one flag bit.
    1675      2627929 : ;; VCOMX/VUCOMX set ZF, SF, OF, differently from COMI/UCOMI.
    1676              : (define_predicate "ix86_trivial_fp_comparison_operator"
    1677     12104622 :   (if_then_else (match_test "TARGET_AVX10_2")
    1678       672480 :                 (match_code "gt,ge,unlt,unle,eq,uneq,ne,ltgt,ordered,unordered")
    1679         2359 :                 (match_code "gt,ge,unlt,unle,uneq,ltgt,ordered,unordered")))
    1680         2359 : 
    1681         2359 : (define_predicate "ix86_trivial_fp_comparison_operator_xf"
    1682    103741789 :   (match_code "gt,ge,unlt,unle,uneq,ltgt,ordered,unordered"))
    1683              : 
    1684      1378724 : ;; Return true if we know how to do this comparison.  Others require
    1685         2359 : ;; testing more than one flag bit, and we let the generic middle-end
    1686       414904 : ;; code do that.
    1687       414289 : (define_predicate "ix86_fp_comparison_operator"
    1688      2925886 :   (if_then_else (match_test "ix86_fp_comparison_strategy (GET_CODE (op))
    1689      2925886 :                              == IX86_FPCMP_ARITH")
    1690       412545 :                (match_operand 0 "comparison_operator")
    1691      9891597 :                (match_operand 0 "ix86_trivial_fp_comparison_operator")))
    1692       412545 : 
    1693      9891597 : (define_predicate "ix86_fp_comparison_operator_xf"
    1694      1791269 :   (if_then_else (match_test "ix86_fp_comparison_strategy (GET_CODE (op))
    1695      1378724 :                              == IX86_FPCMP_ARITH")
    1696              :                (match_operand 0 "comparison_operator")
    1697              :                (match_operand 0 "ix86_trivial_fp_comparison_operator_xf")))
    1698       412545 : 
    1699       848242 : ;; Return true if we can perform this comparison on TImode operands.
    1700              : (define_predicate "ix86_timode_comparison_operator"
    1701       435697 :   (if_then_else (match_test "TARGET_64BIT")
    1702              :                 (match_operand 0 "ordered_comparison_operator")
    1703      2513341 :                 (match_operand 0 "bt_comparison_operator")))
    1704              : 
    1705      2513341 : ;; Return true if this is a valid second operand for a TImode comparison.
    1706              : (define_predicate "ix86_timode_comparison_operand"
    1707       155752 :   (if_then_else (match_test "TARGET_64BIT")
    1708              :                 (match_operand 0 "x86_64_general_operand")
    1709              :                 (match_operand 0 "nonimmediate_operand")))
    1710              : 
    1711      2045132 : ;; Nearly general operand, but accept any const_double, since we wish
    1712              : ;; to be able to drop them into memory rather than have them get pulled
    1713       518709 : ;; into registers.
    1714      2563841 : (define_predicate "cmp_fp_expander_operand"
    1715              :   (ior (match_code "const_double")
    1716              :        (match_operand 0 "general_operand")))
    1717              : 
    1718      4996997 : ;; Return true if this is a valid binary floating-point operation.
    1719              : (define_predicate "binary_fp_operator"
    1720      4996997 :   (match_code "plus,minus,mult,div"))
    1721              : 
    1722      4987925 : ;; Return true if this is a multiply operation.
    1723      4987925 : (define_predicate "mult_operator"
    1724      4987925 :   (match_code "mult"))
    1725      4987925 : 
    1726      4987925 : ;; Return true if this is a division operation.
    1727              : (define_predicate "div_operator"
    1728              :   (match_code "div"))
    1729              : 
    1730      4987925 : ;; Return true if this is an and, ior or xor operation.
    1731      4987925 : (define_predicate "logic_operator"
    1732              :   (match_code "and,ior,xor"))
    1733              : 
    1734              : ;; Return true if this is an and operation.
    1735     17089858 : (define_predicate "and_operator"
    1736              :   (match_code "and"))
    1737     17089858 : 
    1738      3456538 : ;; Return true if this is a plus, minus, and, ior or xor operation.
    1739              : (define_predicate "plusminuslogic_operator"
    1740              :   (match_code "plus,minus,and,ior,xor"))
    1741              : 
    1742      2773541 : ;; Return true for ARITHMETIC_P.
    1743              : (define_predicate "arith_or_logical_operator"
    1744      2773541 :   (match_code "plus,mult,and,ior,xor,smin,smax,umin,umax,compare,minus,div,
    1745       958509 :                mod,udiv,umod,ashift,rotate,ashiftrt,lshiftrt,rotatert"))
    1746              : 
    1747              : ;; Return true for COMMUTATIVE_P.
    1748              : (define_predicate "commutative_operator"
    1749            0 :   (match_code "plus,mult,and,ior,xor,smin,smax,umin,umax"))
    1750              : 
    1751            0 : ;; Return true if OP is a binary operator that can be promoted to wider mode.
    1752              : (define_predicate "promotable_binary_operator"
    1753            0 :   (ior (match_code "plus,minus,and,ior,xor,ashift")
    1754            0 :        (and (match_code "mult")
    1755     25652746 :             (match_test "TARGET_TUNE_PROMOTE_HIMODE_IMUL"))))
    1756            0 : 
    1757              : (define_predicate "compare_operator"
    1758              :   (match_code "compare"))
    1759              : 
    1760      7649013 : (define_predicate "extract_high_operator"
    1761            0 :   (match_code "zero_extract,sign_extract,ashiftrt,lshiftrt")
    1762      7649013 : {
    1763            0 :   return (const8_operand (XEXP (op, 1), VOIDmode)
    1764       144556 :           && (BINARY_P (op) || const8_operand (XEXP (op, 2), VOIDmode)));
    1765          100 : })
    1766              : 
    1767       144656 : ;; Return true if OP is a memory operand, aligned to
    1768            0 : ;; less than its natural alignment.
    1769              : (define_predicate "misaligned_operand"
    1770       144556 :   (and (match_code "mem")
    1771      6332734 :        (match_test "MEM_ALIGN (op) < GET_MODE_BITSIZE (mode)")))
    1772      1602234 : 
    1773       144556 : ;; Return true if OP is a parallel for an mov{d,q,dqa,ps,pd} vec_select,
    1774       546231 : ;; where one of the two operands of the vec_concat is const0_operand.
    1775       144556 : (define_predicate "movq_parallel"
    1776      2109005 :   (match_code "parallel")
    1777       541716 : {
    1778      1964449 :   unsigned nelt = XVECLEN (op, 0);
    1779      1964449 :   unsigned nelt2 = nelt >> 1;
    1780      2109005 :   unsigned i;
    1781       144556 : 
    1782      1477175 :   if (nelt < 2)
    1783              :     return false;
    1784              : 
    1785       541716 :   /* Validate that all of the elements are constants,
    1786       541716 :      lower halves of permute are lower halves of the first operand,
    1787              :      upper halves of permute come from any of the second operand.  */
    1788     15879432 :   for (i = 0; i < nelt; ++i)
    1789              :     {
    1790      6840706 :       rtx er = XVECEXP (op, 0, i);
    1791      2485540 :       unsigned HOST_WIDE_INT ei;
    1792      4355166 : 
    1793      2485540 :       if (!CONST_INT_P (er))
    1794      4355166 :         return false;
    1795      6840706 :       ei = INTVAL (er);
    1796      2485540 :       if (i < nelt2 && ei != i)
    1797      4355166 :         return false;
    1798      1220538 :       if (i >= nelt2 && (ei < nelt || ei >= nelt << 1))
    1799      4355166 :         return false;
    1800      4355166 :     }
    1801      4355166 : 
    1802      4355166 :   return true;
    1803      4355166 : })
    1804      4355166 : 
    1805      4355166 : ;; Return true if OP is a vzeroall operation, known to be a PARALLEL.
    1806      5777899 : (define_predicate "vzeroall_operation"
    1807      4355166 :   (match_code "parallel")
    1808      7200632 : {
    1809      1422752 :   unsigned i, nregs = TARGET_64BIT ? 16 : 8;
    1810            0 : 
    1811         4001 :   if ((unsigned) XVECLEN (op, 0) != 1 + nregs)
    1812      4355166 :     return false;
    1813      4355166 : 
    1814        71866 :   for (i = 0; i < nregs; i++)
    1815              :     {
    1816        63864 :       rtx elt = XVECEXP (op, 0, i+1);
    1817              : 
    1818      4419030 :       if (GET_CODE (elt) != SET
    1819      4419030 :           || GET_CODE (SET_DEST (elt)) != REG
    1820        63864 :           || GET_MODE (SET_DEST (elt)) != V8SImode
    1821        63864 :           || REGNO (SET_DEST (elt)) != GET_SSE_REGNO (i)
    1822       127728 :           || SET_SRC (elt) != CONST0_RTX (V8SImode))
    1823       989240 :         return false;
    1824              :     }
    1825       989240 :   return true;
    1826              : })
    1827       335850 : 
    1828       335850 : ;; return true if OP is a vzeroall pattern.
    1829       339851 : (define_predicate "vzeroall_pattern"
    1830       335850 :   (and (match_code "parallel")
    1831       343852 :        (match_code "unspec_volatile" "a")
    1832         4117 :        (match_test "XINT (XVECEXP (op, 0, 0), 1) == UNSPECV_VZEROALL")))
    1833            0 : 
    1834       335850 : ;; return true if OP is a vzeroupper pattern.
    1835       335850 : (define_predicate "vzeroupper_pattern"
    1836       335850 :   (and (match_code "parallel")
    1837      4228584 :        (match_code "unspec" "b")
    1838         4610 :        (match_test "XINT (XVECEXP (op, 0, 1), 1) == UNSPEC_CALLEE_ABI")
    1839      4228584 :        (match_test "INTVAL (XVECEXP (XVECEXP (op, 0, 1), 0, 0)) == ABI_VZEROUPPER")))
    1840            0 : 
    1841       335850 : ;; Return true if OP is an addsub vec_merge operation
    1842              : (define_predicate "addsub_vm_operator"
    1843              :   (match_code "vec_merge")
    1844         8485 : {
    1845     25661231 :   rtx op0, op1;
    1846         8485 :   int swapped;
    1847     25652746 :   HOST_WIDE_INT mask;
    1848         8485 :   int nunits, elt;
    1849              : 
    1850         8485 :   op0 = XEXP (op, 0);
    1851         8485 :   op1 = XEXP (op, 1);
    1852              : 
    1853              :   /* Sanity check.  */
    1854         8485 :   if (GET_CODE (op0) == MINUS && GET_CODE (op1) == PLUS)
    1855              :     swapped = 0;
    1856         4328 :   else if (GET_CODE (op0) == PLUS && GET_CODE (op1) == MINUS)
    1857              :     swapped = 1;
    1858              :   else
    1859            0 :     gcc_unreachable ();
    1860              : 
    1861         8485 :   mask = INTVAL (XEXP (op, 2));
    1862         8485 :   nunits = GET_MODE_NUNITS (mode);
    1863              : 
    1864        32835 :   for (elt = 0; elt < nunits; elt++)
    1865              :     {
    1866              :       /* bit clear: take from op0, set: take from op1  */
    1867        24593 :       int bit = !(mask & (HOST_WIDE_INT_1U << elt));
    1868              : 
    1869        24593 :       if (bit != ((elt & 1) ^ swapped))
    1870              :         return false;
    1871              :     }
    1872              : 
    1873              :   return true;
    1874              : })
    1875              : 
    1876              : ;; Return true if OP is an addsub vec_select/vec_concat operation
    1877         8485 : (define_predicate "addsub_vs_operator"
    1878              :   (and (match_code "vec_select")
    1879         8485 :        (match_code "vec_concat" "0"))
    1880        16727 : {
    1881         8242 :   rtx op0, op1;
    1882            0 :   bool swapped;
    1883            0 :   int nunits, elt;
    1884              : 
    1885            0 :   op0 = XEXP (XEXP (op, 0), 0);
    1886            0 :   op1 = XEXP (XEXP (op, 0), 1);
    1887              : 
    1888              :   /* Sanity check.  */
    1889            0 :   if (GET_CODE (op0) == MINUS && GET_CODE (op1) == PLUS)
    1890              :     swapped = false;
    1891            0 :   else if (GET_CODE (op0) == PLUS && GET_CODE (op1) == MINUS)
    1892              :     swapped = true;
    1893              :   else
    1894            0 :     gcc_unreachable ();
    1895              : 
    1896            0 :   nunits = GET_MODE_NUNITS (mode);
    1897            0 :   if (XVECLEN (XEXP (op, 1), 0) != nunits)
    1898              :     return false;
    1899              : 
    1900              :   /* We already checked that permutation is suitable for addsub,
    1901              :      so only look at the first element of the parallel.  */
    1902            0 :   elt = INTVAL (XVECEXP (XEXP (op, 1), 0, 0));
    1903              : 
    1904            0 :   return elt == (swapped ? nunits : 0);
    1905              : })
    1906              : 
    1907              : ;; Return true if OP is a parallel for an addsub vec_select.
    1908            0 : (define_predicate "addsub_vs_parallel"
    1909              :   (and (match_code "parallel")
    1910            0 :        (match_code "const_int" "a"))
    1911            0 : {
    1912            0 :   int nelt = XVECLEN (op, 0);
    1913          492 :   int elt, i;
    1914              : 
    1915          492 :   if (nelt < 2)
    1916          492 :     return false;
    1917              : 
    1918              :   /* Check that the permutation is suitable for addsub.
    1919              :      For example, { 0 9 2 11 4 13 6 15 } or { 8 1 10 3 12 5 14 7 }.  */
    1920          492 :   elt = INTVAL (XVECEXP (op, 0, 0));
    1921          492 :   if (elt == 0)
    1922              :     {
    1923          446 :       for (i = 1; i < nelt; ++i)
    1924          438 :         if (INTVAL (XVECEXP (op, 0, i)) != (i + (i & 1) * nelt))
    1925              :           return false;
    1926              :     }
    1927           54 :   else if (elt == nelt)
    1928              :     {
    1929            0 :       for (i = 1; i < nelt; ++i)
    1930            0 :         if (INTVAL (XVECEXP (op, 0, i)) != (elt + i - (i & 1) * nelt))
    1931              :           return false;
    1932              :     }
    1933              :   else
    1934              :     return false;
    1935              : 
    1936              :   return true;
    1937              : })
    1938              : 
    1939              : ;; Return true if OP is a constant pool in perm{w,d,b} which contains index
    1940          492 : ;; match pmov{dw,wb,qd}.
    1941              : (define_predicate "permvar_truncate_operand"
    1942          492 :  (match_code "mem")
    1943          984 : {
    1944            0 :   int nelt = GET_MODE_NUNITS (mode);
    1945           16 :   int perm[128];
    1946           16 :   int id;
    1947              : 
    1948           32 :   if (!INTEGRAL_MODE_P (mode) || !VECTOR_MODE_P (mode))
    1949              :     return false;
    1950              : 
    1951           16 :   if (nelt < 2)
    1952              :     return false;
    1953              : 
    1954           16 :   if (!ix86_extract_perm_from_pool_constant (&perm[0], op))
    1955              :     return false;
    1956              : 
    1957           16 :   id = exact_log2 (nelt);
    1958              : 
    1959              :   /* Check that the permutation is suitable for pmovz{bw,wd,dq}.
    1960              :      For example V16HImode to V8HImode
    1961              :      { 0 2 4 6 8 10 12 14 * * * * * * * * }.  */
    1962          232 :   for (int i = 0; i != nelt / 2; i++)
    1963          216 :     if ((perm[i] & ((1 << id) - 1)) != i * 2)
    1964              :       return false;
    1965              : 
    1966              :   return true;
    1967              : })
    1968              : 
    1969              : ;; Return true if OP is a constant pool in shufb which contains index
    1970           49 : ;; match pmovdw.
    1971              : (define_predicate "pshufb_truncv4siv4hi_operand"
    1972           16 :  (match_code "mem")
    1973           65 : {
    1974           16 :   int perm[128];
    1975              : 
    1976            8 :   if (mode != E_V16QImode)
    1977              :     return false;
    1978            8 : 
    1979            8 :   if (!ix86_extract_perm_from_pool_constant (&perm[0], op))
    1980              :     return false;
    1981              : 
    1982              :   /* Check that the permutation is suitable for pmovdw.
    1983              :      For example V4SImode to V4HImode
    1984              :      { 0 1 4 5 8 9 12 13 * * * * * * * * }.
    1985              :      index = i % 2 + (i / 2) * 4.  */
    1986           58 :   for (int i = 0; i != 8; i++)
    1987              :     {
    1988              :       /* if (SRC2[(i * 8)+7] = 1) then DEST[(i*8)+7..(i*8)+0] := 0;  */
    1989           52 :       if (perm[i] & 128)
    1990              :         return false;
    1991              : 
    1992           52 :       if ((perm[i] & 15) != ((i & 1) + (i & 0xFE) * 2))
    1993              :         return false;
    1994              :      }
    1995              : 
    1996              :   return true;
    1997              : })
    1998              : 
    1999              : ;; Return true if OP is a constant pool in shufb which contains index
    2000           11 : ;; match pmovdw.
    2001              : (define_predicate "pshufb_truncv8hiv8qi_operand"
    2002            8 :  (match_code "mem")
    2003           17 : {
    2004            6 :   int perm[128];
    2005              : 
    2006           11 :   if (mode != E_V16QImode)
    2007              :     return false;
    2008           11 : 
    2009           11 :   if (!ix86_extract_perm_from_pool_constant (&perm[0], op))
    2010              :     return false;
    2011              : 
    2012              :   /* Check that the permutation is suitable for pmovwb.
    2013              :      For example V16QImode to V8QImode
    2014              :      { 0 2 4 6 8 10 12 14 * * * * * * * * }.
    2015              :      index = i % 2 + (i / 2) * 4.  */
    2016           57 :   for (int i = 0; i != 8; i++)
    2017              :     {
    2018              :       /* if (SRC2[(i * 8)+7] = 1) then DEST[(i*8)+7..(i*8)+0] := 0;  */
    2019           52 :       if (perm[i] & 128)
    2020              :         return false;
    2021              : 
    2022           52 :       if ((perm[i] & 15) != i * 2)
    2023              :          return false;
    2024              :     }
    2025              : 
    2026              :   return true;
    2027              : })
    2028              : 
    2029              : ;; Return true if OP is a parallel for an pmovz{bw,wd,dq} vec_select,
    2030           14 : ;; where one of the two operands of the vec_concat is const0_operand.
    2031              : (define_predicate "pmovzx_parallel"
    2032           11 :   (and (match_code "parallel")
    2033           19 :        (match_code "const_int" "a"))
    2034            5 : {
    2035      1494068 :   int nelt = XVECLEN (op, 0);
    2036      1494068 :   int elt, i;
    2037              : 
    2038      1494068 :   if (nelt < 2)
    2039              :     return false;
    2040              : 
    2041              :   /* Check that the permutation is suitable for pmovz{bw,wd,dq}.
    2042              :      For example { 0 16 1 17 2 18 3 19 4 20 5 21 6 22 7 23 }.  */
    2043      1494066 :   elt = INTVAL (XVECEXP (op, 0, 0));
    2044      1494066 :   if (elt == 0)
    2045              :     {
    2046      3447580 :       for (i = 1; i < nelt; ++i)
    2047      2958842 :         if ((i & 1) != 0)
    2048              :           {
    2049      1897526 :             if (INTVAL (XVECEXP (op, 0, i)) < nelt)
    2050              :               return false;
    2051              :           }
    2052      1061316 :         else if (INTVAL (XVECEXP (op, 0, i)) != i / 2)
    2053              :           return false;
    2054              :     }
    2055              :   else
    2056              :     return false;
    2057              : 
    2058              :   return true;
    2059              : })
    2060              : 
    2061              : ;; Return true if OP is a parallel for an insertps vec_select,
    2062      1494068 : ;; where one of the two operands of the vec_concat is const0_operand.
    2063              : (define_predicate "insertps_parallel"
    2064      1494068 :   (and (match_code "parallel")
    2065      2988136 :        (match_code "const_int" "a"))
    2066            0 : {
    2067        12743 :   int i;
    2068              : 
    2069        12743 :   if (XVECLEN (op, 0) != 4)
    2070        12743 :     return false;
    2071              : 
    2072              :   /* One element in [0..3], and the other 3 in [4..7].  */
    2073              :   bool found = false;
    2074        41077 :   for (i = 0; i < 4; ++i)
    2075        39458 :     if (INTVAL (XVECEXP (op, 0, i)) < 4)
    2076              :       {
    2077        23867 :         if (found)
    2078              :           return false;
    2079              :         found = true;
    2080              :       }
    2081              : 
    2082              :   return found;
    2083              : })
    2084              : 
    2085              : ;; Return true if OP is a const vector with duplicate value.
    2086        12743 : (define_predicate "const_vector_duplicate_operand"
    2087              :   (match_code "const_vector")
    2088        12743 : {
    2089        25486 :   rtx elt = XVECEXP (op, 0, 0);
    2090            0 :   int i, nelt = XVECLEN (op, 0);
    2091              : 
    2092           96 :   for (i = 1; i < nelt; ++i)
    2093           93 :     if (!rtx_equal_p (elt, XVECEXP (op, 0, i)))
    2094            3 :       return false;
    2095              :   return true;
    2096              : })
    2097              : 
    2098              : ;; Return true if OP is a parallel for a vbroadcast permute.
    2099            3 : (define_predicate "avx_vbroadcast_operand"
    2100              :   (and (match_code "parallel")
    2101            3 :        (match_code "const_int" "a"))
    2102            6 : {
    2103            3 :   rtx elt = XVECEXP (op, 0, 0);
    2104       390289 :   int i, nelt = XVECLEN (op, 0);
    2105              : 
    2106              :   /* Don't bother checking there are the right number of operands,
    2107       390289 :      merely that they're all identical.  */
    2108       494040 :   for (i = 1; i < nelt; ++i)
    2109       278528 :     if (XVECEXP (op, 0, i) != elt)
    2110              :       return false;
    2111              :   return true;
    2112              : })
    2113              : 
    2114              : ;; Return true if OP is a parallel for a vbroadcastf128 permute.
    2115       390289 : (define_predicate "avx_vbroadcast128_operand"
    2116              :   (and (match_code "parallel")
    2117       390289 :        (match_code "const_int" "a"))
    2118       780578 : {
    2119            0 :   int i, nelt = XVECLEN (op, 0);
    2120      1411040 :   int half = nelt / 2;
    2121              : 
    2122      2351805 :   for (i = 0; i < nelt; ++i)
    2123      1411040 :     {
    2124      2351655 :       int index = INTVAL (XVECEXP (op, 0, i));
    2125      2351655 :       if ((i < half && index != i)
    2126      1097963 :           || (i >= half && index != (i - half)))
    2127              :         return false;
    2128              :     }
    2129              : 
    2130              :   return true;
    2131              : })
    2132              : 
    2133              : ;; Return true if OP is a parallel for a palignr permute.
    2134      1411040 : (define_predicate "palignr_operand"
    2135              :   (and (match_code "parallel")
    2136      1411040 :        (match_code "const_int" "a"))
    2137      2822080 : {
    2138            0 :   int elt = INTVAL (XVECEXP (op, 0, 0));
    2139        26468 :   int i, nelt = XVECLEN (op, 0);
    2140              : 
    2141              :   /* Check that an order in the permutation is suitable for palignr.
    2142        26468 :      For example, {5 6 7 0 1 2 3 4} is "palignr 5, xmm, xmm".  */
    2143        61933 :   for (i = 1; i < nelt; ++i)
    2144        58168 :     if (INTVAL (XVECEXP (op, 0, i)) != ((elt + i) % nelt))
    2145              :       return false;
    2146              :   return true;
    2147              : })
    2148              : 
    2149              : ;; Return true if OP is a proper third operand to vpblendw256.
    2150        26468 : (define_predicate "avx2_pblendw_operand"
    2151              :   (match_code "const_int")
    2152        26468 : {
    2153        52936 :   HOST_WIDE_INT val = INTVAL (op);
    2154            0 :   HOST_WIDE_INT low = val & 0xff;
    2155         7033 :   return val == ((low << 8) | low);
    2156              : })
    2157              : 
    2158         7033 : ;; Return true if OP is vector_operand or CONST_VECTOR.
    2159         7033 : (define_predicate "general_vector_operand"
    2160              :   (ior (match_operand 0 "vector_operand")
    2161         7033 :        (match_code "const_vector")))
    2162         7033 : 
    2163              : ;; Return true if OP is either -1 constant or stored in register.
    2164              : (define_predicate "register_or_constm1_operand"
    2165              :   (ior (match_operand 0 "register_operand")
    2166        13128 :        (and (match_code "const_int")
    2167            0 :             (match_test "op == constm1_rtx"))))
    2168        13128 : 
    2169         2462 : ;; Return true if the vector ends with between 12 and 18 register saves using
    2170              : ;; RAX as the base address.
    2171              : (define_predicate "save_multiple"
    2172       227613 :   (match_code "parallel")
    2173         1324 : {
    2174       227613 :   const unsigned len = XVECLEN (op, 0);
    2175         1324 :   unsigned i;
    2176              : 
    2177              :   /* Starting from end of vector, count register saves.  */
    2178       320322 :   for (i = 0; i < len; ++i)
    2179              :     {
    2180       320322 :       rtx src, dest, addr;
    2181       320322 :       rtx e = XVECEXP (op, 0, len - 1 - i);
    2182              : 
    2183       320322 :       if (GET_CODE (e) != SET)
    2184              :         break;
    2185              : 
    2186       313277 :       src  = SET_SRC (e);
    2187       313277 :       dest = SET_DEST (e);
    2188              : 
    2189       313277 :       if (!REG_P (src) || !MEM_P (dest))
    2190              :         break;
    2191              : 
    2192        92709 :       addr = XEXP (dest, 0);
    2193              : 
    2194              :       /* Good if dest address is in RAX.  */
    2195        92709 :       if (REG_P (addr) && REGNO (addr) == AX_REG)
    2196         4202 :         continue;
    2197              : 
    2198              :       /* Good if dest address is offset of RAX.  */
    2199       177014 :       if (GET_CODE (addr) == PLUS
    2200        88507 :           && REG_P (XEXP (addr, 0))
    2201       177014 :           && REGNO (XEXP (addr, 0)) == AX_REG)
    2202        88507 :         continue;
    2203              : 
    2204              :       break;
    2205              :     }
    2206       227613 :   return (i >= 12 && i <= 18);
    2207              : })
    2208              : 
    2209              : 
    2210       227613 : ;; Return true if the vector ends with between 12 and 18 register loads using
    2211              : ;; RSI as the base address.
    2212       455226 : (define_predicate "restore_multiple"
    2213       227613 :   (match_code "parallel")
    2214            0 : {
    2215      7907953 :   const unsigned len = XVECLEN (op, 0);
    2216      7907953 :   unsigned i;
    2217              : 
    2218      7907953 :   /* Starting from end of vector, count register restores.  */
    2219      8014281 :   for (i = 0; i < len; ++i)
    2220              :     {
    2221      8014281 :       rtx src, dest, addr;
    2222      8014281 :       rtx e = XVECEXP (op, 0, len - 1 - i);
    2223              : 
    2224      8014281 :       if (GET_CODE (e) != SET)
    2225              :         break;
    2226              : 
    2227      4498531 :       src  = SET_SRC (e);
    2228      4498531 :       dest = SET_DEST (e);
    2229              : 
    2230      4498531 :       if (!MEM_P (src) || !REG_P (dest))
    2231              :         break;
    2232              : 
    2233      1387077 :       addr = XEXP (src, 0);
    2234              : 
    2235              :       /* Good if src address is in RSI.  */
    2236      1387077 :       if (REG_P (addr) && REGNO (addr) == SI_REG)
    2237         5129 :         continue;
    2238              : 
    2239              :       /* Good if src address is offset of RSI.  */
    2240      1483147 :       if (GET_CODE (addr) == PLUS
    2241       941264 :           && REG_P (XEXP (addr, 0))
    2242      2257526 :           && REGNO (XEXP (addr, 0)) == SI_REG)
    2243       101199 :         continue;
    2244              : 
    2245              :       break;
    2246              :     }
    2247      7907953 :   return (i >= 12 && i <= 18);
    2248              : })
    2249              : 
    2250              : ;; Keylocker specific predicates
    2251      7907953 : (define_predicate "encodekey128_operation"
    2252              :   (match_code "parallel")
    2253     15815906 : {
    2254      7907953 :   unsigned i;
    2255            0 :   rtx elt;
    2256              : 
    2257          108 :   if (XVECLEN (op, 0) != 8)
    2258              :     return false;
    2259          108 : 
    2260          392 :   for(i = 0; i < 3; i++)
    2261              :     {
    2262          294 :       elt = XVECEXP (op, 0, i + 1);
    2263          294 :       if (GET_CODE (elt) != SET
    2264          294 :           || GET_CODE (SET_DEST (elt)) != REG
    2265          294 :           || GET_MODE (SET_DEST (elt)) != V2DImode
    2266          294 :           || REGNO (SET_DEST (elt)) != GET_SSE_REGNO (i)
    2267          294 :           || GET_CODE (SET_SRC (elt)) != UNSPEC_VOLATILE
    2268          294 :           || GET_MODE (SET_SRC (elt)) != V2DImode
    2269          294 :           || XVECLEN(SET_SRC (elt), 0) != 1
    2270          588 :           || XVECEXP(SET_SRC (elt), 0, 0) != const0_rtx)
    2271              :         return false;
    2272              :     }
    2273              : 
    2274          392 :   for(i = 4; i < 7; i++)
    2275              :     {
    2276          294 :       elt = XVECEXP (op, 0, i);
    2277          294 :       if (GET_CODE (elt) != CLOBBER
    2278          294 :           || GET_MODE (elt) != VOIDmode
    2279          294 :           || GET_CODE (XEXP (elt, 0)) != REG
    2280          294 :           || GET_MODE (XEXP (elt, 0)) != V2DImode
    2281          588 :           || REGNO (XEXP (elt, 0)) != GET_SSE_REGNO (i))
    2282              :         return false;
    2283              :     }
    2284              : 
    2285           98 :   elt = XVECEXP (op, 0, 7);
    2286           98 :   if (GET_CODE (elt) != CLOBBER
    2287           98 :       || GET_MODE (elt) != VOIDmode
    2288           98 :       || GET_CODE (XEXP (elt, 0)) != REG
    2289           98 :       || GET_MODE (XEXP (elt, 0)) != CCmode
    2290          196 :       || REGNO (XEXP (elt, 0)) != FLAGS_REG)
    2291            0 :     return false;
    2292              :   return true;
    2293              : })
    2294              : 
    2295              : (define_predicate "encodekey256_operation"
    2296          108 :   (match_code "parallel")
    2297              : {
    2298          337 :   unsigned i;
    2299          108 :   rtx elt;
    2300            0 : 
    2301          121 :   if (XVECLEN (op, 0) != 9)
    2302              :     return false;
    2303              : 
    2304          121 :   elt = SET_SRC (XVECEXP (op, 0, 0));
    2305          112 :   elt = XVECEXP (elt, 0, 2);
    2306          112 :   if (!REG_P (elt)
    2307          112 :       || REGNO(elt) != GET_SSE_REGNO (1))
    2308              :     return false;
    2309              : 
    2310          560 :   for(i = 0; i < 4; i++)
    2311              :     {
    2312          448 :       elt = XVECEXP (op, 0, i + 1);
    2313          448 :       if (GET_CODE (elt) != SET
    2314          448 :           || GET_CODE (SET_DEST (elt)) != REG
    2315          448 :           || GET_MODE (SET_DEST (elt)) != V2DImode
    2316          448 :           || REGNO (SET_DEST (elt)) != GET_SSE_REGNO (i)
    2317          448 :           || GET_CODE (SET_SRC (elt)) != UNSPEC_VOLATILE
    2318          448 :           || GET_MODE (SET_SRC (elt)) != V2DImode
    2319          448 :           || XVECLEN(SET_SRC (elt), 0) != 1
    2320          896 :           || XVECEXP(SET_SRC (elt), 0, 0) != const0_rtx)
    2321              :         return false;
    2322              :     }
    2323              : 
    2324          448 :   for(i = 4; i < 7; i++)
    2325              :     {
    2326          336 :       elt = XVECEXP (op, 0, i + 1);
    2327          336 :       if (GET_CODE (elt) != CLOBBER
    2328          336 :           || GET_MODE (elt) != VOIDmode
    2329          336 :           || GET_CODE (XEXP (elt, 0)) != REG
    2330          336 :           || GET_MODE (XEXP (elt, 0)) != V2DImode
    2331          672 :           || REGNO (XEXP (elt, 0)) != GET_SSE_REGNO (i))
    2332              :         return false;
    2333              :     }
    2334              : 
    2335          112 :   elt = XVECEXP (op, 0, 8);
    2336          112 :   if (GET_CODE (elt) != CLOBBER
    2337          112 :       || GET_MODE (elt) != VOIDmode
    2338          112 :       || GET_CODE (XEXP (elt, 0)) != REG
    2339          112 :       || GET_MODE (XEXP (elt, 0)) != CCmode
    2340          224 :       || REGNO (XEXP (elt, 0)) != FLAGS_REG)
    2341            0 :     return false;
    2342              :   return true;
    2343              : })
    2344              : 
    2345              : 
    2346          121 : (define_predicate "aeswidekl_operation"
    2347              :   (match_code "parallel")
    2348          242 : {
    2349          121 :   unsigned i;
    2350            0 :   rtx elt;
    2351              : 
    2352         5796 :   for (i = 0; i < 8; i++)
    2353              :     {
    2354          660 :       elt = XVECEXP (op, 0, i + 1);
    2355         5168 :       if (GET_CODE (elt) != SET
    2356         5168 :           || GET_CODE (SET_DEST (elt)) != REG
    2357         5168 :           || GET_MODE (SET_DEST (elt)) != V2DImode
    2358         5168 :           || REGNO (SET_DEST (elt)) != GET_SSE_REGNO (i)
    2359         5168 :           || GET_CODE (SET_SRC (elt)) != UNSPEC_VOLATILE
    2360         5168 :           || GET_MODE (SET_SRC (elt)) != V2DImode
    2361         5168 :           || XVECLEN (SET_SRC (elt), 0) != 1
    2362         5168 :           || !REG_P (XVECEXP (SET_SRC (elt), 0, 0))
    2363        10304 :           || REGNO (XVECEXP (SET_SRC (elt), 0, 0)) != GET_SSE_REGNO (i))
    2364              :         return false;
    2365              :     }
    2366              :   return true;
    2367              : })
    2368              : 
    2369              : ;; Return true if OP is a memory operand that can be also used in APX
    2370          660 : ;; EVEX-encoded patterns (i.e. APX NDD/NF) with immediate operand.  With
    2371              : ;; non-default address space, segment register or address size prefix,
    2372         1320 : ;; APX EVEX-encoded instruction length can exceed the 15 byte size limit.
    2373          660 : (define_predicate "apx_evex_memory_operand"
    2374            0 :   (match_operand 0 "memory_operand")
    2375              : {
    2376              :   /* OK if immediate operand size < 4 bytes.  */
    2377         1686 :   if (GET_MODE_SIZE (mode) < 4)
    2378         1686 :     return true;
    2379              : 
    2380         1527 :   bool default_addr = ADDR_SPACE_GENERIC_P (MEM_ADDR_SPACE (op));
    2381         1695 :   bool address_size_prefix = TARGET_X32 && Pmode == SImode;
    2382              : 
    2383         1527 :   struct ix86_address parts;
    2384         1527 :   int ok;
    2385              : 
    2386         1527 :   op = XEXP (op, 0);
    2387         1527 :   ok = ix86_decompose_address (op, &parts);
    2388         1527 :   gcc_assert (ok);
    2389              : 
    2390         1527 :   if (default_addr)
    2391              :     {
    2392              :       /* Default address space.  */
    2393              : 
    2394              :       /* Not OK with address size prefix, index register and disp.  */
    2395          691 :       if (address_size_prefix
    2396          168 :           && parts.index
    2397           42 :           && parts.disp
    2398           42 :           && parts.disp != const0_rtx)
    2399           42 :         return false;
    2400              :     }
    2401              :   else
    2402              :     {
    2403              :       /* Non-default address space.  */
    2404              : 
    2405              :       /* Not OK without base register.  */
    2406          836 :       if (!parts.base)
    2407              :         return false;
    2408              : 
    2409              :       /* Not OK with disp and address size prefix.  */
    2410          668 :       if (address_size_prefix && parts.disp)
    2411            0 :         return false;
    2412              :     }
    2413              : 
    2414              :   return true;
    2415              : })
    2416              : 
    2417              : ;; Return true if OP is a memory operand which can be used in APX EVEX-encoded
    2418         1806 : ;; ADD patterns (i.e. APX NDD/NF) for with register source operand.
    2419              : ;; UNSPEC_GOTNTPOFF memory operand is allowed with APX EVEX-encoded ADD only if
    2420         3492 : ;; R_X86_64_CODE_6_GOTTPOFF works.
    2421         1686 : (define_predicate "apx_evex_add_memory_operand"
    2422              :   (match_operand 0 "memory_operand")
    2423              : {
    2424              :   /* OK if "add %reg1, name@gottpoff(%rip), %reg2" or
    2425              :    "{nf} add name@gottpoff(%rip), %reg1" are supported.  */
    2426              :   if (HAVE_AS_R_X86_64_CODE_6_GOTTPOFF)
    2427              :     return true;
    2428              : 
    2429              :   op = XEXP (op, 0);
    2430              : 
    2431              :   /* Disallow APX EVEX-encoded ADD with UNSPEC_GOTNTPOFF.  */
    2432              :   if (GET_CODE (op) == CONST
    2433              :       && GET_CODE (XEXP (op, 0)) == UNSPEC
    2434              :       && XINT (XEXP (op, 0), 1) == UNSPEC_GOTNTPOFF)
    2435              :     return false;
    2436              : 
    2437              :   return true;
    2438              : })
    2439              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2440              : /* (content generated from coverage data) */
    2441          848 : /* BEGIN: function "_Z27apx_evex_add_memory_operandP7rtx_def12machine_mode" */
    2442              : /* ... */
    2443          848 : /* ... */
    2444          848 : /* ... */
    2445              : /* END: function "_Z27apx_evex_add_memory_operandP7rtx_def12machine_mode" */
    2446              : /* ... */
    2447              : /* ... */
    2448   1010561959 : /* BEGIN: function "_Z19lookup_constraint_1PKc" */
    2449              : /* ... */
    2450   1010561959 : /* ... */
    2451              : /* ... */
    2452              : /* ... */
    2453              : /* ... */
    2454            0 : /* ... */
    2455            0 : /* ... */
    2456            0 : /* ... */
    2457            0 : /* ... */
    2458            0 : /* ... */
    2459            0 : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2460    598813541 : /* (content generated from coverage data) */
    2461    598813541 : /* ... */
    2462              : /* ... */
    2463              : /* ... */
    2464      8762666 : /* ... */
    2465              : /* ... */
    2466    136623288 : /* ... */
    2467              : /* ... */
    2468       136749 : /* ... */
    2469              : /* ... */
    2470      1722232 : /* ... */
    2471              : /* ... */
    2472      1444344 : /* ... */
    2473              : /* ... */
    2474     57652547 : /* ... */
    2475              : /* ... */
    2476     52623820 : /* ... */
    2477              : /* ... */
    2478    102163208 : /* ... */
    2479              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2480     40100166 : /* (content generated from coverage data) */
    2481              : /* ... */
    2482    121239511 : /* ... */
    2483              : /* ... */
    2484     76344183 : /* ... */
    2485              : /* ... */
    2486          827 : /* ... */
    2487              : /* ... */
    2488            0 : /* ... */
    2489            0 : /* ... */
    2490            0 : /* ... */
    2491            0 : /* ... */
    2492            0 : /* ... */
    2493            0 : /* ... */
    2494            0 : /* ... */
    2495            0 : /* ... */
    2496            0 : /* ... */
    2497            0 : /* ... */
    2498            0 : /* ... */
    2499            0 : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2500            0 : /* (content generated from coverage data) */
    2501            0 : /* ... */
    2502            0 : /* ... */
    2503            0 : /* ... */
    2504            0 : /* ... */
    2505            0 : /* ... */
    2506            0 : /* ... */
    2507            0 : /* ... */
    2508            0 : /* ... */
    2509            0 : /* ... */
    2510            0 : /* ... */
    2511            0 : /* ... */
    2512            0 : /* ... */
    2513            0 : /* ... */
    2514            0 : /* ... */
    2515            0 : /* ... */
    2516            0 : /* ... */
    2517            0 : /* ... */
    2518     41295355 : /* ... */
    2519     41295355 : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2520              : /* (content generated from coverage data) */
    2521        23352 : /* ... */
    2522              : /* ... */
    2523              : /* ... */
    2524            0 : /* ... */
    2525            0 : /* ... */
    2526            0 : /* ... */
    2527            0 : /* ... */
    2528      3351668 : /* ... */
    2529      3351668 : /* ... */
    2530              : /* ... */
    2531              : /* ... */
    2532         5448 : /* ... */
    2533              : /* ... */
    2534       341246 : /* ... */
    2535              : /* ... */
    2536      2647926 : /* ... */
    2537              : /* ... */
    2538       272420 : /* ... */
    2539              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2540         1418 : /* (content generated from coverage data) */
    2541              : /* ... */
    2542          240 : /* ... */
    2543              : /* ... */
    2544         5093 : /* ... */
    2545              : /* ... */
    2546            0 : /* ... */
    2547            0 : /* ... */
    2548    358376820 : /* ... */
    2549    358376820 : /* ... */
    2550              : /* ... */
    2551              : /* ... */
    2552      5658008 : /* ... */
    2553              : /* ... */
    2554      4051038 : /* ... */
    2555              : /* ... */
    2556      1376793 : /* ... */
    2557              : /* ... */
    2558      1387686 : /* ... */
    2559              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2560        19926 : /* (content generated from coverage data) */
    2561              : /* ... */
    2562    197004900 : /* ... */
    2563              : /* ... */
    2564      1182090 : /* ... */
    2565              : /* ... */
    2566    142793602 : /* ... */
    2567              : /* ... */
    2568      3150757 : /* ... */
    2569              : /* ... */
    2570       506445 : /* ... */
    2571              : /* ... */
    2572      1217351 : /* ... */
    2573              : /* ... */
    2574            0 : /* ... */
    2575            0 : /* ... */
    2576            0 : /* ... */
    2577            0 : /* ... */
    2578            0 : /* ... */
    2579            0 : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2580            0 : /* (content generated from coverage data) */
    2581            0 : /* ... */
    2582            0 : /* ... */
    2583            0 : /* ... */
    2584            0 : /* ... */
    2585            0 : /* ... */
    2586            0 : /* ... */
    2587            0 : /* ... */
    2588            0 : /* ... */
    2589            0 : /* ... */
    2590      8724575 : /* ... */
    2591      8724575 : /* ... */
    2592              : /* ... */
    2593              : /* ... */
    2594      1329145 : /* ... */
    2595              : /* ... */
    2596            0 : /* ... */
    2597              : /* ... */
    2598            0 : /* ... */
    2599              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2600            0 : /* (content generated from coverage data) */
    2601              : /* ... */
    2602            0 : /* ... */
    2603              : /* ... */
    2604            0 : /* ... */
    2605              : /* ... */
    2606       221299 : /* ... */
    2607              : /* ... */
    2608         8292 : /* ... */
    2609              : /* ... */
    2610      6224700 : /* ... */
    2611              : /* ... */
    2612       158478 : /* ... */
    2613              : /* ... */
    2614       270536 : /* ... */
    2615              : /* ... */
    2616         3499 : /* ... */
    2617              : /* ... */
    2618            0 : /* ... */
    2619              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2620            0 : /* (content generated from coverage data) */
    2621            0 : /* ... */
    2622            0 : /* ... */
    2623            0 : /* ... */
    2624            0 : /* ... */
    2625            0 : /* ... */
    2626            0 : /* ... */
    2627            0 : /* ... */
    2628            0 : /* ... */
    2629            0 : /* ... */
    2630            0 : /* ... */
    2631            0 : /* ... */
    2632            0 : /* ... */
    2633            0 : /* ... */
    2634            0 : /* ... */
    2635            0 : /* ... */
    2636            0 : /* ... */
    2637            0 : /* ... */
    2638            0 : /* ... */
    2639            0 : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2640            0 : /* (content generated from coverage data) */
    2641            0 : /* ... */
    2642            0 : /* ... */
    2643            0 : /* ... */
    2644            0 : /* ... */
    2645            0 : /* ... */
    2646            0 : /* ... */
    2647            0 : /* ... */
    2648              : /* ... */
    2649              : /* ... */
    2650         1337 : /* ... */
    2651              : /* END: function "_Z19lookup_constraint_1PKc" */
    2652              : /* ... */
    2653              : /* ... */
    2654              : /* ... */
    2655              : /* ... */
    2656              : /* ... */
    2657              : /* ... */
    2658              : /* ... */
    2659              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2660              : /* (content generated from coverage data) */
    2661              : /* ... */
    2662              : /* ... */
    2663              : /* ... */
    2664              : /* ... */
    2665              : /* ... */
    2666              : /* ... */
    2667              : /* ... */
    2668              : /* ... */
    2669              : /* ... */
    2670              : /* ... */
    2671              : /* ... */
    2672              : /* ... */
    2673              : /* ... */
    2674              : /* ... */
    2675              : /* ... */
    2676              : /* ... */
    2677              : /* ... */
    2678              : /* ... */
    2679              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2680              : /* (content generated from coverage data) */
    2681              : /* ... */
    2682              : /* ... */
    2683              : /* ... */
    2684              : /* ... */
    2685              : /* ... */
    2686              : /* ... */
    2687              : /* ... */
    2688              : /* ... */
    2689              : /* ... */
    2690              : /* ... */
    2691              : /* ... */
    2692              : /* ... */
    2693              : /* ... */
    2694              : /* ... */
    2695              : /* ... */
    2696              : /* ... */
    2697              : /* ... */
    2698              : /* ... */
    2699              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2700              : /* (content generated from coverage data) */
    2701              : /* ... */
    2702              : /* ... */
    2703              : /* ... */
    2704              : /* ... */
    2705              : /* ... */
    2706              : /* ... */
    2707              : /* ... */
    2708              : /* ... */
    2709              : /* ... */
    2710              : /* ... */
    2711              : /* ... */
    2712              : /* ... */
    2713              : /* ... */
    2714              : /* ... */
    2715              : /* ... */
    2716              : /* ... */
    2717              : /* ... */
    2718              : /* ... */
    2719              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2720              : /* (content generated from coverage data) */
    2721              : /* ... */
    2722              : /* ... */
    2723              : /* ... */
    2724              : /* ... */
    2725              : /* ... */
    2726              : /* ... */
    2727              : /* ... */
    2728              : /* ... */
    2729              : /* ... */
    2730              : /* ... */
    2731              : /* ... */
    2732              : /* ... */
    2733              : /* ... */
    2734              : /* ... */
    2735              : /* ... */
    2736              : /* ... */
    2737              : /* ... */
    2738              : /* ... */
    2739              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2740              : /* (content generated from coverage data) */
    2741              : /* ... */
    2742              : /* ... */
    2743              : /* ... */
    2744              : /* ... */
    2745              : /* ... */
    2746              : /* ... */
    2747              : /* ... */
    2748              : /* ... */
    2749              : /* ... */
    2750              : /* ... */
    2751              : /* ... */
    2752              : /* ... */
    2753              : /* ... */
    2754              : /* ... */
    2755              : /* ... */
    2756              : /* ... */
    2757              : /* ... */
    2758              : /* ... */
    2759              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2760              : /* (content generated from coverage data) */
    2761              : /* ... */
    2762              : /* ... */
    2763              : /* ... */
    2764              : /* ... */
    2765              : /* ... */
    2766              : /* ... */
    2767              : /* ... */
    2768              : /* ... */
    2769              : /* ... */
    2770              : /* ... */
    2771              : /* ... */
    2772              : /* ... */
    2773              : /* ... */
    2774              : /* ... */
    2775              : /* ... */
    2776              : /* ... */
    2777              : /* ... */
    2778              : /* ... */
    2779              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2780              : /* (content generated from coverage data) */
    2781              : /* ... */
    2782              : /* ... */
    2783              : /* ... */
    2784              : /* ... */
    2785              : /* ... */
    2786              : /* ... */
    2787              : /* ... */
    2788              : /* ... */
    2789              : /* ... */
    2790              : /* ... */
    2791              : /* ... */
    2792              : /* ... */
    2793              : /* ... */
    2794              : /* ... */
    2795              : /* ... */
    2796              : /* ... */
    2797              : /* ... */
    2798              : /* ... */
    2799              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2800              : /* (content generated from coverage data) */
    2801              : /* ... */
    2802              : /* ... */
    2803              : /* ... */
    2804              : /* ... */
    2805              : /* ... */
    2806              : /* ... */
    2807              : /* ... */
    2808              : /* ... */
    2809              : /* ... */
    2810              : /* ... */
    2811              : /* ... */
    2812              : /* ... */
    2813              : /* ... */
    2814              : /* ... */
    2815              : /* ... */
    2816              : /* ... */
    2817              : /* ... */
    2818              : /* ... */
    2819              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2820              : /* (content generated from coverage data) */
    2821              : /* ... */
    2822              : /* ... */
    2823              : /* ... */
    2824              : /* ... */
    2825              : /* ... */
    2826              : /* ... */
    2827              : /* ... */
    2828              : /* ... */
    2829              : /* ... */
    2830              : /* ... */
    2831              : /* ... */
    2832              : /* ... */
    2833              : /* ... */
    2834              : /* ... */
    2835              : /* ... */
    2836              : /* ... */
    2837              : /* ... */
    2838              : /* ... */
    2839              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2840              : /* (content generated from coverage data) */
    2841              : /* ... */
    2842              : /* ... */
    2843              : /* ... */
    2844              : /* ... */
    2845              : /* ... */
    2846              : /* ... */
    2847              : /* ... */
    2848              : /* ... */
    2849              : /* ... */
    2850              : /* ... */
    2851              : /* ... */
    2852              : /* ... */
    2853              : /* ... */
    2854              : /* ... */
    2855              : /* ... */
    2856              : /* ... */
    2857              : /* ... */
    2858              : /* ... */
    2859              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2860              : /* (content generated from coverage data) */
    2861              : /* ... */
    2862              : /* ... */
    2863              : /* ... */
    2864              : /* ... */
    2865              : /* ... */
    2866              : /* ... */
    2867              : /* ... */
    2868              : /* ... */
    2869              : /* ... */
    2870              : /* ... */
    2871              : /* ... */
    2872              : /* ... */
    2873              : /* ... */
    2874              : /* ... */
    2875              : /* ... */
    2876              : /* ... */
    2877              : /* ... */
    2878              : /* ... */
    2879              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2880              : /* (content generated from coverage data) */
    2881              : /* ... */
    2882              : /* ... */
    2883              : /* ... */
    2884              : /* ... */
    2885              : /* ... */
    2886              : /* ... */
    2887              : /* ... */
    2888              : /* ... */
    2889              : /* ... */
    2890              : /* ... */
    2891              : /* ... */
    2892              : /* ... */
    2893              : /* ... */
    2894              : /* ... */
    2895              : /* ... */
    2896              : /* ... */
    2897              : /* ... */
    2898              : /* ... */
    2899              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2900              : /* (content generated from coverage data) */
    2901              : /* ... */
    2902              : /* ... */
    2903              : /* ... */
    2904              : /* ... */
    2905              : /* ... */
    2906              : /* ... */
    2907              : /* ... */
    2908              : /* ... */
    2909              : /* ... */
    2910              : /* ... */
    2911              : /* ... */
    2912              : /* ... */
    2913   7428904864 : /* BEGIN: function "_Z26reg_class_for_constraint_114constraint_num" */
    2914              : /* ... */
    2915   7428904864 : /* ... */
    2916              : /* ... */
    2917              : /* ... */
    2918              : /* ... */
    2919    137126440 : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2920              : /* (content generated from coverage data) */
    2921     54872330 : /* ... */
    2922     23779175 : /* ... */
    2923              : /* ... */
    2924     24955032 : /* ... */
    2925      9994455 : /* ... */
    2926       751314 : /* ... */
    2927       960564 : /* ... */
    2928       782910 : /* ... */
    2929      1459773 : /* ... */
    2930    218449247 : /* ... */
    2931        81699 : /* ... */
    2932         8637 : /* ... */
    2933       921173 : /* ... */
    2934     45288628 : /* ... */
    2935    673396227 : /* ... */
    2936    243851877 : /* ... */
    2937   1519001791 : /* ... */
    2938        14330 : /* ... */
    2939      5657561 : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2940      4050611 : /* (content generated from coverage data) */
    2941      1320435 : /* ... */
    2942            0 : /* ... */
    2943      1387682 : /* ... */
    2944        14123 : /* ... */
    2945    186345952 : /* ... */
    2946       320971 : /* ... */
    2947    142510533 : /* ... */
    2948      2754897 : /* ... */
    2949       447021 : /* ... */
    2950              : /* ... */
    2951       133825 : /* ... */
    2952      6223480 : /* ... */
    2953              : /* ... */
    2954              : /* ... */
    2955              : /* ... */
    2956              : /* END: function "_Z26reg_class_for_constraint_114constraint_num" */
    2957              : /* ... */
    2958              : /* ... */
    2959              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2960              : /* (content generated from coverage data) */
    2961              : /* ... */
    2962              : /* ... */
    2963              : /* ... */
    2964              : /* ... */
    2965              : /* ... */
    2966              : /* ... */
    2967              : /* ... */
    2968              : /* ... */
    2969              : /* ... */
    2970              : /* ... */
    2971              : /* ... */
    2972              : /* ... */
    2973              : /* ... */
    2974              : /* ... */
    2975              : /* ... */
    2976              : /* ... */
    2977              : /* ... */
    2978              : /* ... */
    2979              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    2980              : /* (content generated from coverage data) */
    2981              : /* ... */
    2982              : /* ... */
    2983              : /* ... */
    2984              : /* ... */
    2985              : /* ... */
    2986              : /* ... */
    2987              : /* ... */
    2988              : /* ... */
    2989              : /* ... */
    2990              : /* ... */
    2991              : /* ... */
    2992              : /* ... */
    2993              : /* ... */
    2994              : /* ... */
    2995              : /* ... */
    2996              : /* ... */
    2997              : /* ... */
    2998              : /* ... */
    2999              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    3000              : /* (content generated from coverage data) */
    3001              : /* ... */
    3002              : /* ... */
    3003              : /* ... */
    3004              : /* ... */
    3005              : /* ... */
    3006              : /* ... */
    3007              : /* ... */
    3008              : /* ... */
    3009              : /* ... */
    3010              : /* ... */
    3011              : /* ... */
    3012              : /* ... */
    3013              : /* ... */
    3014              : /* ... */
    3015              : /* ... */
    3016              : /* ... */
    3017              : /* ... */
    3018              : /* ... */
    3019              : /* /home/worker/buildworker/tiber-lcov/build/gcc/config/i386/predicates.md not long enough */
    3020      7325452 : /* END: function "_Z32insn_const_int_ok_for_constraintl14constraint_num" */
    3021              : /* ... */
    3022      7325452 : /* ... */
    3023              : /* ... */
    3024      1374443 : /* ... */
    3025      1374443 : /* ... */
        

Generated by: LCOV version 2.5.0-beta

LCOV profile is generated on x86_64 machine using following configure options: configure --disable-bootstrap --enable-coverage=opt --enable-languages=c,c++,fortran,go,jit,lto,rust,m2 --enable-host-shared. GCC test suite is run with the built compiler.