PR target/64889
authorlaw <law@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 6 Feb 2015 14:25:23 +0000 (14:25 +0000)
committerlaw <law@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 6 Feb 2015 14:25:23 +0000 (14:25 +0000)
* config/h8300/h8300.c (push): New argument "in_prologue".
Pass "in_prologue" along to "F".
(h8300_push_pop): Corresponding changes.
(h8300_expand_prologue): Likewise.
(h8300_swap_into_er6): Likewise.  Do not set RTX_FRAME_RELATED_P.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@220478 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/config/h8300/h8300.c

index 3a5d7a2..41a824d 100644 (file)
@@ -1,3 +1,12 @@
+2015-02-06  Jeff Law  <law@redhat.com>
+
+       PR target/64889
+       * config/h8300/h8300.c (push): New argument "in_prologue".
+       Pass "in_prologue" along to "F".
+       (h8300_push_pop): Corresponding changes.
+       (h8300_expand_prologue): Likewise.
+       (h8300_swap_into_er6): Likewise.  Do not set RTX_FRAME_RELATED_P.
+               
 2015-02-06  Jakub Jelinek  <jakub@redhat.com>
 
        PR rtl-optimization/64957
@@ -11,6 +20,7 @@
        * tree-ssa-loop-ivopts.c (get_shiftadd_cost): Use the mininum of costs
        of shift-add and (add + shift) operations.  Rename local variable.
 
+
 2015-02-05  Jeff Law  <law@redhat.com>
 
        PR target/17306
index ea90052..4e9110e 100644 (file)
@@ -619,7 +619,7 @@ compute_saved_regs (void)
 /* Emit an insn to push register RN.  */
 
 static rtx
-push (int rn)
+push (int rn, bool in_prologue)
 {
   rtx reg = gen_rtx_REG (word_mode, rn);
   rtx x;
@@ -630,7 +630,7 @@ push (int rn)
     x = gen_push_h8300hs_advanced (reg);
   else
     x = gen_push_h8300hs_normal (reg);
-  x = F (emit_insn (x), true);
+  x = F (emit_insn (x), in_prologue);
   add_reg_note (x, REG_INC, stack_pointer_rtx);
   return x;
 }
@@ -683,7 +683,7 @@ h8300_push_pop (int regno, int nregs, bool pop_p, bool return_p)
       if (pop_p)
        pop (regno);
       else
-       push (regno);
+       push (regno, false);
       return;
     }
 
@@ -868,7 +868,7 @@ h8300_expand_prologue (void)
   if (frame_pointer_needed)
     {
       /* Push fp.  */
-      push (HARD_FRAME_POINTER_REGNUM);
+      push (HARD_FRAME_POINTER_REGNUM, true);
       F (emit_move_insn (hard_frame_pointer_rtx, stack_pointer_rtx), true);
     }
 
@@ -2757,7 +2757,7 @@ h8sx_emit_movmd (rtx dest, rtx src, rtx length,
 void
 h8300_swap_into_er6 (rtx addr)
 {
-  rtx insn = push (HARD_FRAME_POINTER_REGNUM);
+  rtx insn = push (HARD_FRAME_POINTER_REGNUM, false);
   if (frame_pointer_needed)
     add_reg_note (insn, REG_CFA_DEF_CFA,
                  plus_constant (Pmode, gen_rtx_MEM (Pmode, stack_pointer_rtx),
@@ -2786,7 +2786,6 @@ h8300_swap_out_of_er6 (rtx addr)
     emit_move_insn (addr, hard_frame_pointer_rtx);
 
   insn = pop (HARD_FRAME_POINTER_REGNUM);
-  RTX_FRAME_RELATED_P (insn) = 1;
   if (frame_pointer_needed)
     add_reg_note (insn, REG_CFA_DEF_CFA,
                  plus_constant (Pmode, hard_frame_pointer_rtx,