This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: m68k patch for handling m5200 pushes and pops
- To: Will Cohen <wcohen at redhat dot com>
- Subject: Re: m68k patch for handling m5200 pushes and pops
- From: Roman Zippel <zippel at linux-m68k dot org>
- Date: Mon, 13 Aug 2001 23:56:31 +0200 (CEST)
- cc: <gcc-patches at gcc dot gnu dot org>
Hi,
On Mon, 13 Aug 2001, Will Cohen wrote:
> I tracked this problem down to print_operand_address in m68k.c and
> INDIRECTABLE_1_ADDRESS_P in m68k.h missing checks for PRE_MODIFY and
> POST_MODIFY.
These shouldn't be generated for m68k (at least not currently). Below is
the correct patch.
bye, Roman
2001-08-13 Roman Zippel <zippel@linux-m68k.org>
* config/m68k/m68k.md (pushqi1): New, to generate correct byte push
Index: config/m68k/m68k.md
===================================================================
RCS file: /cvs/gcc/egcs/gcc/config/m68k/m68k.md,v
retrieving revision 1.44
diff -u -r1.44 m68k.md
--- m68k.md 2001/07/31 03:45:08 1.44
+++ m68k.md 2001/07/31 13:11:21
@@ -1425,6 +1432,15 @@
(match_operand:SI 1 "address_operand" "p"))]
""
"pea %a1")
+
+(define_expand "pushqi1"
+ [(set (reg:SI 15)
+ (plus:SI (reg:SI 15) (const_int -2)))
+ (set (mem:QI (plus:SI (reg:SI 15)
+ (const_int 1)))
+ (match_operand:QI 0 "general_operand" ""))]
+ ""
+ "")
;; truncation instructions
(define_insn "truncsiqi2"