------- Additional Comments From pinskia at gcc dot gnu dot org  2004-11-04 17:20 
-------
I am testing this patch (which is a modified version of the one which you gave me), it 
should help -O0 
compile time as we no longer have an extra INSN which gets removed right after the 
register allocator:
Index: expmed.c
===============================================================
====
RCS file: /cvs/gcc/gcc/gcc/expmed.c,v
retrieving revision 1.200
diff -u -p -r1.200 expmed.c
--- expmed.c    21 Oct 2004 10:51:00 -0000      1.200
+++ expmed.c    4 Nov 2004 16:55:46 -0000
@@ -2638,7 +2638,10 @@ expand_mult_const (enum machine_mode mod
     }
   else if (alg->op[0] == alg_m)
     {
-      accum = copy_to_mode_reg (mode, op0);
+      if (REG_P (op0) && GET_MODE (op0) == mode && alg->ops == 2)
+        accum = op0;
+      else
+        accum = copy_to_mode_reg (mode, op0);
       val_so_far = 1;
     }
   else


-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |pinskia at gcc dot gnu dot
                   |                            |org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18293

Reply via email to