[PATCH] Fix PR c/11420 (broken amd64 movabs*)

Jan Hubicka jh@suse.cz
Thu Jul 3 15:12:00 GMT 2003


> On Thu, Jul 03, 2003 at 01:38:37PM +0200, Jan Hubicka wrote:
> > > Hi!
> > > 
> > > This patch fixes PR c/11420.
> > > movabs does not have
> > > movabs[bwlq] $imm, (%reg)
> > > form.
> > > Interestingly, this has been (partially) fixed on gcc-3_{1,2}-branch
> > > in http://gcc.gnu.org/ml/gcc-patches/2002-05/msg01740.html
> > > but only the movabsq variant while the other insns were left untouched.
> > > Ok for trunk/3.3?
> > 
> > Now I recall it.  The third alternative with immediate should not be
> > movabs, but simple plain mov for [bwl], so it is just typo in the
> > template.  It is supposed to not matter as the instruction should be
> > re-recognized after reload as plain move, not sure why.
> 
> But are there any advantages to keep that alternative for bwl (after fixing
> the template)? For q it is obviously wrong.

It theoretically gives slightly more freedom to reload.  Whether it is
able to take any advantage of it is unknown to me but obviously it is
able to generate it in some cases.
For q you can still use the movabs $imm, rax instruction when you use
'I' and 'a' constraints.

I am not against dropping that feature or fixing the templates, just was
trying to dig out the reason why I made the code so, uhm, interesting :)
Thank you for fixing that, BTW!

Honza
> 
> 	Jakub



More information about the Gcc-patches mailing list