cse.c (canon_hash): Don't register registers in very small register classes...
authorGeoffrey Keating <geoffk@redhat.com>
Mon, 2 Jul 2001 23:24:02 +0000 (23:24 +0000)
committerGeoffrey Keating <geoffk@gcc.gnu.org>
Mon, 2 Jul 2001 23:24:02 +0000 (23:24 +0000)
* cse.c (canon_hash): Don't register registers in very small
register classes, as extending their lifetime might cause
reload to fail.

From-SVN: r43714

gcc/ChangeLog
gcc/cse.c

index a83fdf5142676cf4589249abb6ee2d405370947f..5b45aab9c3acc5af0874bf5325e784652bba17aa 100644 (file)
@@ -1,3 +1,9 @@
+2001-07-02  Geoffrey Keating  <geoffk@redhat.com>
+
+       * cse.c (canon_hash): Don't register registers in very small
+       register classes, as extending their lifetime might cause
+       reload to fail.
+
 Mon Jul  2 23:14:00 CEST 2001  Jan Hubicka  <jh@suse.cz>
 
        * flow.c (try_redirect_by_replacing_jump): Remove cc0 setter.
index bc4a05aad763118d16d6b457228cda27e93ed719..87694a1414786dcae5c50af2d3b1ed23bfa44dab 100644 (file)
--- a/gcc/cse.c
+++ b/gcc/cse.c
@@ -2266,10 +2266,13 @@ canon_hash (x, mode)
           failure to do so leads to failure to simplify 0<100 type of
           conditionals.
 
-          On all machines, we can't record any global registers.  */
+          On all machines, we can't record any global registers.  
+          Nor should we record any register that is in a small
+          class, as defined by CLASS_LIKELY_SPILLED_P.  */
 
        if (regno < FIRST_PSEUDO_REGISTER
            && (global_regs[regno]
+               || CLASS_LIKELY_SPILLED_P (REGNO_REG_CLASS (regno))
                || (SMALL_REGISTER_CLASSES
                    && ! fixed_regs[regno]
                    && regno != FRAME_POINTER_REGNUM