[rz@linux-m68k.org: Re: m68k, extendqidi2 problem]
Gunther Nikl
gni@gecko.de
Wed Mar 17 12:20:00 GMT 2004
On Tue, Mar 16, 2004 at 10:56:49PM +0100, Richard Zidlicky wrote:
> --- gcc-3.4-20040218/gcc/config/m68k/m68k.md.rz-extbdi 2004-03-07 23:08:04.000000000 +0100
> +++ gcc-3.4-20040218/gcc/config/m68k/m68k.md 2004-03-07 23:32:21.000000000 +0100
> @@ -1455,10 +1455,20 @@
> {
> CC_STATUS_INIT;
> operands[2] = gen_rtx_REG (SImode, REGNO (operands[0]) + 1);
> - if (TARGET_68020 || TARGET_COLDFIRE)
> - return "move%.b %1,%2\;extb%.l %2\;smi %0\;extb%.l %0";
> + if (ADDRESS_REG_P(operands[1]))
> + {
> + if (TARGET_68020 || TARGET_COLDFIRE)
> + return "move%.w %1,%2\;extb%.l %2\;smi %0\;extb%.l %0";
> + else
> + return "move%.w %1,%2\;ext%.w %0\;ext%.l %2\;move%.l %2,%0\;smi %0";
Why "ext%.w %0"? Shouldn't it be "ext%.w %2"? Then I don't understand
the "move%.l %2,%0 in the else case and the extbl after smi in the if
case.
> + }
> else
> - return "move%.b %1,%2\;ext%.w %0\;ext%.l %2\;move%.l %2,%0\;smi %0";
> + {
> + if (TARGET_68020 || TARGET_COLDFIRE)
> + return "move%.b %1,%2\;extb%.l %2\;smi %0\;extb%.l %0";
> + else
> + return "move%.b %1,%2\;ext%.w %0\;ext%.l %2\;move%.l %2,%0\;smi %0";
Same here.
Gunther
More information about the Gcc
mailing list