This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [patch] MIPS/gcc: Revert removal of DImode shifts for 32-bittargets
- From: Richard Sandiford <rsandifo at redhat dot com>
- To: Nigel Stephens <nigel at mips dot com>
- Cc: "Maciej W. Rozycki" <macro at linux-mips dot org>, Ralf Baechle <ralf at linux-mips dot org>, Richard Henderson <rth at redhat dot com>, gcc-patches at gcc dot gnu dot org, linux-mips at linux-mips dot org
- Date: Tue, 03 Aug 2004 10:36:09 +0100
- Subject: Re: [patch] MIPS/gcc: Revert removal of DImode shifts for 32-bittargets
- References: <Pine.LNX.4.55.0407191648451.3667@jurand.ds.pg.gda.pl><87hds49bmo.fsf@redhat.com><Pine.LNX.4.55.0407191907300.3667@jurand.ds.pg.gda.pl><20040719213801.GD14931@redhat.com><Pine.LNX.4.55.0407201505330.14824@jurand.ds.pg.gda.pl><20040723202703.GB30931@redhat.com><20040723211232.GB5138@linux-mips.org><Pine.LNX.4.58L.0407261325470.3873@blysk.ds.pg.gda.pl><410E9E25.7080104@mips.com> <87acxcbxfl.fsf@redhat.com><410F5964.3010109@mips.com>
Nigel Stephens <nigel@mips.com> writes:
>>If we handle it in a target-independent way, with each insn exposed
>>separately, we will be able to optimize special cases better.
>>We'll also get the usual scheduling benefits.
>
> I agree that we should open-code it for the obvious reasons, but does it
> have to be target independent, or could/should we prototype it with
> define_expand?
I think we should only use define_expands if there's a truly
MIPS-specific feature in the expansion (as there is in the block
move stuff, for example, where we use left/right loads and stores).
Now obviously I'm only guessing what insn sequence you're using,
but I suspect it doesn't involve anything that the middle-end
couldn't work out from stock optabs. If there are different
trade-offs to be made during the expansion, they should probably
be predicated on rtx_costs.
Richard