This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

[patch 3.1] h8300.md: Don't push stack pointer.


Hi,

Attached is a patch to do the same thing as

http://gcc.gnu.org/ml/gcc-patches/2001-07/msg01635.html

OK to apply to the mainline if testing goes well?

Thanks,

Kazu Hirata

2001-07-23  Kazu Hirata  <kazu@hxi.com>

	* h8300.md: Fix formatting.

Index: h8300.md
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/h8300/h8300.md,v
retrieving revision 1.31
diff -u -r1.31 h8300.md
--- h8300.md	2001/07/23 21:46:38	1.31
+++ h8300.md	2001/07/23 21:55:45
@@ -175,7 +175,9 @@
 	(match_operand:HI 1 "general_operand_src" "I,r>,r,i,m,r"))]
   "TARGET_H8300
    && (register_operand (operands[0],HImode)
-       || register_operand (operands[1], HImode))"
+       || register_operand (operands[1], HImode))
+   && !(push_operand (operands[0], HImode)
+        && operands[1] == stack_pointer_rtx)"
   "@
    sub.w	%T0,%T0
    mov.w	%T1,%T0
@@ -404,7 +406,9 @@
 	(match_operand:SI 1 "general_operand_src" "I,r,i,m,r,r,>,I,r,*a"))]
   "(TARGET_H8300S || TARGET_H8300H)
    && (register_operand (operands[0], SImode)
-       || register_operand (operands[1], SImode))"
+       || register_operand (operands[1], SImode))
+   && !(push_operand (operands[0], SImode)
+        && operands[1] == stack_pointer_rtx)"
   "*
 {
   switch (which_alternative)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]