Patch from John Wehle to fix movxf_push spill reg allocation failure.
authorJohn Wehle <john@feith.com>
Mon, 20 Apr 1998 15:06:40 +0000 (15:06 +0000)
committerJim Wilson <wilson@gcc.gnu.org>
Mon, 20 Apr 1998 15:06:40 +0000 (08:06 -0700)
* i386.md (movsf_push, movdf_push, movxf_push): Allow memory
operands during and after reload.

From-SVN: r19346

gcc/ChangeLog
gcc/config/i386/i386.md

index 563928d4d5a175ce0fc9aa1b00a7c4bfd6107147..fbac26bdaf325608aa21037acdaab2d4eabd0d54 100644 (file)
@@ -1,3 +1,8 @@
+Mon Apr 20 15:04:14 1998  John Wehle  (john@feith.com)
+
+       * i386.md (movsf_push, movdf_push, movxf_push): Allow memory
+       operands during and after reload.
+
 Mon Apr 20 22:37:50 1998  J"orn Rennecke <amylaar@cygnus.co.uk>
 
        * final.c (shorten_branches, init_insn_lengths): Move code
index ecae5172ad825120264aef98a2de327b93392502..7fe22aafbd1d37d81c24dd20f3534ccd9d82bfe3 100644 (file)
 
 (define_insn "movsf_push"
   [(set (match_operand:SF 0 "push_operand" "=<,<")
-       (match_operand:SF 1 "nonmemory_operand" "rF,f"))]
-  ""
+       (match_operand:SF 1 "general_operand" "*rfF,m"))]
+  "GET_CODE (operands[1]) != MEM || reload_in_progress || reload_completed"
   "*
 {
   if (STACK_REG_P (operands[1]))
 
       RET;
     }
+
   return AS1 (push%L0,%1);
 }")
 
 
 (define_insn "movdf_push"
   [(set (match_operand:DF 0 "push_operand" "=<,<")
-       (match_operand:DF 1 "nonmemory_operand" "rF,f"))]
-  ""
+       (match_operand:DF 1 "general_operand" "*rfF,o"))]
+  "GET_CODE (operands[1]) != MEM || reload_in_progress || reload_completed"
   "*
 {
   if (STACK_REG_P (operands[1]))
 
       RET;
     }
+
+  if (which_alternative == 1)
+    return output_move_pushmem (operands, insn, GET_MODE_SIZE (DFmode), 0, 0);
+
   return output_move_double (operands);
 }")
 
 
 (define_insn "movxf_push"
   [(set (match_operand:XF 0 "push_operand" "=<,<")
-       (match_operand:XF 1 "nonmemory_operand" "rF,f"))]
-  ""
+       (match_operand:XF 1 "general_operand" "*rfF,o"))]
+  "GET_CODE (operands[1]) != MEM || reload_in_progress || reload_completed"
   "*
 {
   if (STACK_REG_P (operands[1]))
 
       RET;
     }
+
+  if (which_alternative == 1)
+    return output_move_pushmem (operands, insn, GET_MODE_SIZE (XFmode), 0, 0);
+
   return output_move_double (operands);
  }")