re PR bootstrap/4195 (mn10200-elf fails building libgcc __ffssi2)
authorJakub Jelinek <jakub@redhat.com>
Thu, 21 Mar 2002 07:14:18 +0000 (08:14 +0100)
committerJakub Jelinek <jakub@gcc.gnu.org>
Thu, 21 Mar 2002 07:14:18 +0000 (08:14 +0100)
PR bootstrap/4195
* genrecog.c (maybe_both_true_mode): Remove.
(maybe_both_true_2, write_switch): Revert 2001-07-17 changes.
* machmode.def (Pmode): Likewise.

From-SVN: r51115

gcc/ChangeLog
gcc/genrecog.c
gcc/machmode.def

index ddc27263e7c51f321e0088aa9b93e6a10ab79461..0a06dbd1b20953d5e087098e1110fa6b3e13ed8e 100644 (file)
@@ -1,3 +1,10 @@
+2002-03-21  Jakub Jelinek  <jakub@redhat.com>
+
+       PR bootstrap/4195
+       * genrecog.c (maybe_both_true_mode): Remove.
+       (maybe_both_true_2, write_switch): Revert 2001-07-17 changes.
+       * machmode.def (Pmode): Likewise.
+
 Thu Mar 21 01:55:06 EST 2002  John Wehle  (john@feith.com)
 
        * alias.c: (nonlocal_mentioned_p): Use for_each_rtx.
index 136422c3e4f3c15ed1d9a1323d7c5fb7547502b2..1e8f8545f1c431aed70ba20bd7e6f097b1938bbb 100644 (file)
@@ -238,8 +238,6 @@ static void validate_pattern
 static struct decision *add_to_sequence
   PARAMS ((rtx, struct decision_head *, const char *, enum routine_type, int));
 
-static int maybe_both_true_mode
-  PARAMS ((enum machine_mode, enum machine_mode));
 static int maybe_both_true_2
   PARAMS ((struct decision_test *, struct decision_test *));
 static int maybe_both_true_1
@@ -1056,29 +1054,6 @@ add_to_sequence (pattern, last, position, insn_type, top)
   return sub;
 }
 \f
-/* A subroutine of maybe_both_true; compares two modes.
-   Returns > 0 for "definitely both true" and < 0 for "maybe both true".  */
-
-static int
-maybe_both_true_mode (m1, m2)
-     enum machine_mode m1, m2;
-{
-  enum mode_class other_mode_class;
-
-  /* Pmode is not a distinct mode.  We do know that it is
-     either MODE_INT or MODE_PARTIAL_INT though.  */
-  if (m1 == Pmode)
-    other_mode_class = GET_MODE_CLASS (m2);
-  else if (m2 == Pmode)
-    other_mode_class = GET_MODE_CLASS (m1);
-  else
-    return m1 == m2;
-
-  return (other_mode_class == MODE_INT
-         || other_mode_class == MODE_PARTIAL_INT
-         ? -1 : 0);
-}
-
 /* A subroutine of maybe_both_true; examines only one test.
    Returns > 0 for "definitely both true" and < 0 for "maybe both true".  */
 
@@ -1091,7 +1066,7 @@ maybe_both_true_2 (d1, d2)
       switch (d1->type)
        {
        case DT_mode:
-         return maybe_both_true_mode (d1->u.mode, d2->u.mode);
+         return d1->u.mode == d2->u.mode;
 
        case DT_code:
          return d1->u.code == d2->u.code;
@@ -1127,7 +1102,7 @@ maybe_both_true_2 (d1, d2)
        {
          if (d2->type == DT_mode)
            {
-             if (maybe_both_true_mode (d1->u.pred.mode, d2->u.mode) == 0
+             if (d1->u.pred.mode != d2->u.mode
                  /* The mode of an address_operand predicate is the
                     mode of the memory, not the operand.  It can only
                     be used for testing the predicate, so we must
@@ -1910,9 +1885,6 @@ write_switch (start, depth)
           || type == DT_elt_zero_wide_safe)
     {
       const char *indent = "";
-      /* Pmode may not be a compile-time constant.  */
-      if (type == DT_mode && p->tests->u.mode == Pmode)
-       return p;
 
       /* We cast switch parameter to integer, so we must ensure that the value
         fits.  */
@@ -1956,10 +1928,6 @@ write_switch (start, depth)
            if (nodes_identical_1 (p->tests, q->tests))
              goto case_done;
 
-         /* Pmode may not be a compile-time constant.  */
-         if (type == DT_mode && p->tests->u.mode == Pmode)
-           goto case_done;
-
          if (p != start && p->need_label && needs_label == NULL)
            needs_label = p;
 
index 16abebb8f3189b99c59eaa47e3db10fa0c72bcaf..eedff972d997f4dd2458a823fc2843054bfa902e 100644 (file)
@@ -165,14 +165,7 @@ EXTRA_CC_MODES
 #undef CC
 
 /* The symbol Pmode stands for one of the above machine modes (usually SImode).
-   The tm file specifies which one.  It is not a distinct mode.  Nevertheless,
-   while processing the md file, we wish to treat as a distinct mode so that 
-   it is preserved intact through to the insn-foo.c files.  This eliminates a
-   lot of redundancy in ports that support both 32-bit and 64-bit targets.  */
-#ifdef GENERATOR_FILE
-#undef Pmode
-DEF_MACHMODE (Pmode, "P", MODE_RANDOM, 0, 0, 0, VOIDmode, VOIDmode)
-#endif
+   The tm file specifies which one.  It is not a distinct mode.  */
 
 /*
 Local variables: