This is the mail archive of the
mailing list for the GCC project.
Re: PATCH: PR target/40470: unab le to find a register to spill i n class âSSE_FIRST_REGâ
- From: "graham stott" <graham dot stott at btinternet dot com>
- To: "Richard Henderson" <rth at redhat dot com>
- Cc: "H.J. Lu" <hjl dot tools at gmail dot com>, "Jeff Law" <law at redhat dot com>, "Vladimir Makarov" <vmakarov at redhat dot com>, "Steven Bosscher" <stevenb dot gcc at gmail dot com>, "Richard Guenther" <richard dot guenther at gmail dot com>, <gcc-patches at gcc dot gnu dot org>, <ubizjak at gmail dot com>
- Date: Thu, 18 Jun 2009 23:14:18 +0100
- Subject: Re: PATCH: PR target/40470: unab le to find a register to spill i n class âSSE_FIRST_REGâ
- References: <firstname.lastname@example.org> <4A3AA28F.email@example.com>
Yes, you are correct.
I got the regiter classes mixed up it's been so long since I last looked at
the x86 backend in any detail.
----- Original Message -----
From: "Richard Henderson" <firstname.lastname@example.org>
To: "Graham Stott" <email@example.com>
Cc: "H.J. Lu" <firstname.lastname@example.org>; "Jeff Law" <email@example.com>; "Vladimir
Makarov" <firstname.lastname@example.org>; "Steven Bosscher" <email@example.com>;
"Richard Guenther" <firstname.lastname@example.org>; <email@example.com>;
Sent: Thursday, June 18, 2009 9:24 PM
Subject: Re: PATCH: PR target/40470: unable to find a register to spill in
Graham Stott wrote:
cant_combine_insn_p looks to be where the combind should get rejected.
It uses CLASS_LIKELY_SPILLED (REGNO_REG_CLASS (REGNO (...)) to reject
the combine if it finds a HARD reg which is likely to be spilled.
Now on the x86 XMM0 is in MMX_REGS class which is NOT a likely spilled
class hence it doen't get rejected.
Adding MMX_REGS to the set of likely spilled classes on x86 should do the
%xmm0 is *supposed* to be in SSE_FIRST_REG class.
Are you sure you saw MMX_REG?
Now, CLASS_LIKELY_SPILLED_P in i386.h didn't get
updated when the SSE_FIRST_REG class was introduced,
so fixing that could fix the problem described.