Patchwork patch to fix PR55106

login
register
mail settings
Submitter Gary Funck
Date Oct. 31, 2012, 4:33 p.m.
Message ID <20121031163306.GI3805@intrepid.com>
Download mbox | patch
Permalink /patch/195933/
State New
Headers show

Comments

Gary Funck - Oct. 31, 2012, 4:33 p.m.
On 10/28/12 20:43:05, Vladimir Makarov wrote:
> The following patch fixes PR55106.  A value in GENERAL_REGS is
> inherited into a move with destination pseudo of SSE_REGS.  It
> results into secondary move for which inheritance is tried again an
> again.  It means cycling LRA passes.
> 
>   The patch was successfully bootstrapped on x86/x86-64.

This patch fails on IA64, due to unused variables on an #ifndef path.

This fix, or something like it is needed.
Vladimir Makarov - Oct. 31, 2012, 4:54 p.m.
On 12-10-31 12:33 PM, Gary Funck wrote:
> On 10/28/12 20:43:05, Vladimir Makarov wrote:
>> The following patch fixes PR55106.  A value in GENERAL_REGS is
>> inherited into a move with destination pseudo of SSE_REGS.  It
>> results into secondary move for which inheritance is tried again an
>> again.  It means cycling LRA passes.
>>
>>    The patch was successfully bootstrapped on x86/x86-64.
> This patch fails on IA64, due to unused variables on an #ifndef path.
>
> This fix, or something like it is needed.
Sorry for this.  It was already fixed today by Joerne Rennecke.
> Index: gcc/lra-constraints.c
> ===================================================================
> --- gcc/lra-constraints.c       (revision 192988)
> +++ gcc/lra-constraints.c       (working copy)
> @@ -3591,7 +3591,8 @@ skip_usage_debug_insns (rtx usage_insns)
>      USAGE_INSNS after inserting inherited pseudo of class INHER_CL
>      into the insn.  */
>   static bool
> -check_secondary_memory_needed_p (enum reg_class inher_cl, rtx usage_insns)
> +check_secondary_memory_needed_p (enum reg_class inher_cl ATTRIBUTE_UNUSED,
> +                                rtx usage_insns ATTRIBUTE_UNUSED)
>   {
>   #ifndef SECONDARY_MEMORY_NEEDED
>     return false;

Patch

Index: gcc/lra-constraints.c
===================================================================
--- gcc/lra-constraints.c       (revision 192988)
+++ gcc/lra-constraints.c       (working copy)
@@ -3591,7 +3591,8 @@  skip_usage_debug_insns (rtx usage_insns)
    USAGE_INSNS after inserting inherited pseudo of class INHER_CL
    into the insn.  */
 static bool
-check_secondary_memory_needed_p (enum reg_class inher_cl, rtx usage_insns)
+check_secondary_memory_needed_p (enum reg_class inher_cl ATTRIBUTE_UNUSED,
+                                rtx usage_insns ATTRIBUTE_UNUSED)
 {
 #ifndef SECONDARY_MEMORY_NEEDED
   return false;