This is the mail archive of the gcc@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]
Other format: [Raw text]

Re: Cleanups for the m68k backend


On Sat, Jul 05, 2003 at 12:38:13PM -0400, Kaveh R. Ghazi wrote:
> 1.  One option might be to use %O and extend ASM_OUTPUT_OPCODE to use
> print_operand for punctuation.  If you do that then something like
> this:
> 
>  > 	    asm_fprintf (stream,
>  > #ifdef MOTOROLA
>  > 			 "\t%Omove.l %s,-(%Rsp)\n",
>  > #else
>  > 			 "\tmovel %s,%Rsp@-\n",
>  > #endif
>  > 			 reg_names[15 - i]);

The best option, IMO, is to stop using asm_fprintf so much,
and instead use output_asm_insn.  Then, both cases would be

	xops[0] = gen_rtx_REG (Pmode, i);
	output_asm_insn ("move%.l %0,%-", xops);

Even better would be to update the m68k port to emit prologues
as rtl instead of as text.  Yes, I know scheduling is more or
less pointless on these machines, but we'd like to eventually
*elimitate* prologue-as-text for maintainence, validation, and
other assorted reasons.


r~


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