]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
re PR target/13256 (strict_low_part mistreated in delay slots)
authorHans-Peter Nilsson <hp@axis.com>
Fri, 12 Dec 2003 14:01:40 +0000 (14:01 +0000)
committerHans-Peter Nilsson <hp@gcc.gnu.org>
Fri, 12 Dec 2003 14:01:40 +0000 (14:01 +0000)
PR target/13256
Backport from mainline:
* resource.h (enum mark_resource_type): Remove member MARK_DEST.
The only user changed as follows:
* resource.c (mark_set_resources) <case SET>: Always recurse for
SET_SRC (x).
<case SIGN_EXTRACT, case ZERO_EXTRACT>: Always recurse on
operands.
<case STRICT_LOW_PART>: Delete, deferring to default code.

From-SVN: r74570

gcc/ChangeLog
gcc/resource.c
gcc/resource.h

index d91633ab986bcdb9b4d7ef24c768c9a15b51d67b..20f21cee0e464bf7d70645dae2d2c5e7d6e89c5b 100644 (file)
@@ -1,5 +1,15 @@
 2003-12-12  Hans-Peter Nilsson  <hp@axis.com>
 
+       PR target/13256
+       Backport from mainline:
+       * resource.h (enum mark_resource_type): Remove member MARK_DEST.
+       The only user changed as follows:
+       * resource.c (mark_set_resources) <case SET>: Always recurse for
+       SET_SRC (x).
+       <case SIGN_EXTRACT, case ZERO_EXTRACT>: Always recurse on
+       operands.
+       <case STRICT_LOW_PART>: Delete, deferring to default code.
+
        PR target/12598
        Backport from mainline:
        * config/cris/cris.md (define_split "*mov_sidesi_biap_mem"+1)
index a72dd9ce1a4fec4d9ccec9e3ba183faa9381c03e..f90342ddd66fd46dd9ef411254c781880e96f0b6 100644 (file)
@@ -1,5 +1,5 @@
 /* Definitions for computing resource usage of specific insns.
-   Copyright (C) 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+   Copyright (C) 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
 
 This file is part of GCC.
 
@@ -624,7 +624,7 @@ find_dead_or_set_registers (target, res, jump_target, jump_count, set, needed)
 /* Given X, a part of an insn, and a pointer to a `struct resource',
    RES, indicate which resources are modified by the insn. If
    MARK_TYPE is MARK_SRC_DEST_CALL, also mark resources potentially
-   set by the called routine.  If MARK_TYPE is MARK_DEST, only mark SET_DESTs
+   set by the called routine.
 
    If IN_DEST is nonzero, it means we are inside a SET.  Otherwise,
    objects are being referenced instead of set.
@@ -727,8 +727,7 @@ mark_set_resources (x, res, in_dest, mark_type)
                           || GET_CODE (SET_SRC (x)) != CALL),
                          mark_type);
 
-      if (mark_type != MARK_DEST)
-       mark_set_resources (SET_SRC (x), res, 0, MARK_SRC_DEST);
+      mark_set_resources (SET_SRC (x), res, 0, MARK_SRC_DEST);
       return;
 
     case CLOBBER:
@@ -758,12 +757,9 @@ mark_set_resources (x, res, in_dest, mark_type)
 
     case SIGN_EXTRACT:
     case ZERO_EXTRACT:
-      if (! (mark_type == MARK_DEST && in_dest))
-       {
-         mark_set_resources (XEXP (x, 0), res, in_dest, MARK_SRC_DEST);
-         mark_set_resources (XEXP (x, 1), res, 0, MARK_SRC_DEST);
-         mark_set_resources (XEXP (x, 2), res, 0, MARK_SRC_DEST);
-       }
+      mark_set_resources (XEXP (x, 0), res, in_dest, MARK_SRC_DEST);
+      mark_set_resources (XEXP (x, 1), res, 0, MARK_SRC_DEST);
+      mark_set_resources (XEXP (x, 2), res, 0, MARK_SRC_DEST);
       return;
 
     case MEM:
@@ -810,13 +806,6 @@ mark_set_resources (x, res, in_dest, mark_type)
        }
       return;
 
-    case STRICT_LOW_PART:
-      if (! (mark_type == MARK_DEST && in_dest))
-       {
-         mark_set_resources (XEXP (x, 0), res, 0, MARK_SRC_DEST);
-         return;
-       }
-
     case UNSPEC_VOLATILE:
     case ASM_INPUT:
       /* Traditional asm's are always volatile.  */
index fc2330c8e151bc865c42ff56768a283dc2ccf54b..124cf9b21b81e9dbaa360c0087331404a8da2119 100644 (file)
@@ -37,8 +37,7 @@ struct resources
 enum mark_resource_type
 {
   MARK_SRC_DEST = 0,
-  MARK_SRC_DEST_CALL = 1,
-  MARK_DEST = 2
+  MARK_SRC_DEST_CALL = 1
 };
 
 extern void mark_target_live_regs      PARAMS ((rtx, rtx, struct resources *));