This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH, ARM, PR64208] LRA ICE Fix
- From: Yvan Roux <yvan dot roux at linaro dot org>
- To: Kyrill Tkachov <kyrylo dot tkachov at arm dot com>
- Cc: "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>, Ramana Radhakrishnan <Ramana dot Radhakrishnan at arm dot com>, Richard Earnshaw <Richard dot Earnshaw at arm dot com>, Vladimir Makarov <vmakarov at redhat dot com>
- Date: Wed, 18 Mar 2015 12:42:31 +0100
- Subject: Re: [PATCH, ARM, PR64208] LRA ICE Fix
- Authentication-results: sourceware.org; auth=none
- References: <CAD57uCfHZuBqWbMiqGT+qDXQj37NCa9wKcEN+RpcUS3xpurYhQ at mail dot gmail dot com> <55095252 dot 3000306 at arm dot com>
HI Kyrill,
On 18 March 2015 at 11:24, Kyrill Tkachov <kyrylo.tkachov@arm.com> wrote:
> Hi Yvan,
>
>
> On 18/03/15 10:19, Yvan Roux wrote:
>>
>> Hi,
>>
>> This is a fix for PR64208 where LRA loops when dealing with
>> iwmmxt_arm_movdi insn. As explain in the PR, the issue was introduced
>> on trunk and 4.9 branch by fix of PR rtl-optimization/60969 and then
>> workaround by r211798 (-fuse-caller-save enable for ARM).
>>
>> The changes in IRA cost made by PR60969, changed the register class of
>> this insn output from GENERAL_REGS to IWMMXT_REGS, and the
>> redundancies in the insn pattern alternatives description force LRA to
>> reload the pseudo, which generates the same iwmmxt_arm_movdi insn,
>> which can't be resolved, and so on ...
>>
>> Removing the redundancies fixes the issue, as LRA find that
>> alternative 8 (Uy => y) matches.
>>
>> This issue is present in 4.9 branch, but latent on trunk (the
>> clobbering of IP and CC information added during -fuse-caller-save
>> patch changed the register allocation).
>>
>> Cross compiled and regression tested on ARM targets (but not on an
>> IWMMXT one), is it ok for trunk and 4.9 branch ?
>>
>> Rq: I think that adding IP and CC clobbers to
>> CALL_INSN_FUNCTION_USAGE, as specified by AAPCS, in 4.9 branch is
>> something we need too, I've a patch for that if you agree on that.
>>
>> Thanks,
>> Yvan
>>
>> 2105-03-17 Yvan Roux <yvan.roux@linaro.org>
>>
>> PR target/64208
>> * config/arm/iwmmxt.md ("*iwmmxt_arm_movdi"): Cleanup redundant
>> alternatives.
>
>
> As a general note, I think this patch should include the testcase from the
> PR.
> I can see that it's fairly self-contained.
Yes, I wanted to find one that exhibits the issue on trunk as the PR
testcase doesn't, but don't find one so far. If it's fine to include
a testcase that don't fail without that patch on trunk, I can include
it.
Cheers,
Yvan