Patchwork [Ada] Implementation of aspects within generic units

login
register
mail settings
Submitter Richard Guenther
Date Sept. 1, 2011, 10:33 a.m.
Message ID <CAFiYyc1VkmrUckAR5GzBg5hzAjF9sHeEK3beTjXLwZ--duAVNQ@mail.gmail.com>
Download mbox | patch
Permalink /patch/112857/
State New
Headers show

Comments

Richard Guenther - Sept. 1, 2011, 10:33 a.m.
On Thu, Sep 1, 2011 at 11:34 AM, Arnaud Charlet <charlet@adacore.com> wrote:
> After doing a binary search, the first revision which breaks bootstrap on
> my environment with Ada enabled is the following:
>
> r178353 | vries | 2011-08-31 09:04:25 +0200 (Wed, 31 Aug 2011) | 8 lines
>
> 2011-08-31  Tom de Vries  <tom@codesourcery.com>
>
>        PR middle-end/43513
>        * Makefile.in (tree-ssa-ccp.o): Add $(PARAMS_H) to rule.
>        * tree-ssa-ccp.c (params.h): Include.
>        (fold_builtin_alloca_for_var): New function.
>        (ccp_fold_stmt): Use fold_builtin_alloca_for_var.
>
> Which makes sense, since Ada uses alloca a lot, much more than other languages.
>
> In other words, none of the changes in the Ada repository is reponsible for
> this regression.
>
> So Tom and/or Richard, could you please have a look at this regression? TIA.

Probably worth checking

should be reproducable with low stack ulimit.

Richard.

> Arno
>
Tom de Vries - Sept. 1, 2011, 11:01 a.m.
On 09/01/2011 12:33 PM, Richard Guenther wrote:
> On Thu, Sep 1, 2011 at 11:34 AM, Arnaud Charlet <charlet@adacore.com> wrote:
>> After doing a binary search, the first revision which breaks bootstrap on
>> my environment with Ada enabled is the following:
>>
>> r178353 | vries | 2011-08-31 09:04:25 +0200 (Wed, 31 Aug 2011) | 8 lines
>>
>> 2011-08-31  Tom de Vries  <tom@codesourcery.com>
>>
>>        PR middle-end/43513
>>        * Makefile.in (tree-ssa-ccp.o): Add $(PARAMS_H) to rule.
>>        * tree-ssa-ccp.c (params.h): Include.
>>        (fold_builtin_alloca_for_var): New function.
>>        (ccp_fold_stmt): Use fold_builtin_alloca_for_var.
>>
>> Which makes sense, since Ada uses alloca a lot, much more than other languages.
>>
>> In other words, none of the changes in the Ada repository is reponsible for
>> this regression.
>>
>> So Tom and/or Richard, could you please have a look at this regression? TIA.
> 
> Probably worth checking
> 
> Index: gcc/tree-ssa-ccp.c
> ===================================================================
> --- gcc/tree-ssa-ccp.c  (revision 178394)
> +++ gcc/tree-ssa-ccp.c  (working copy)
> @@ -1714,7 +1714,7 @@ fold_builtin_alloca_for_var (gimple stmt
>    block = gimple_block (stmt);
>    if (!(cfun->after_inlining
>          && TREE_CODE (BLOCK_SUPERCONTEXT (block)) == FUNCTION_DECL))
> -    threshold /= 10;
> +    return NULL_TREE;
>    if (size > threshold)
>      return NULL_TREE;
> 
> should be reproducable with low stack ulimit.
> 
> Richard.
> 
>> Arno
>>

I'm doing an ada bootstrap now, trying to reproduce this. My apologies for this
breakage.

Thanks,
- Tom

Patch

Index: gcc/tree-ssa-ccp.c
===================================================================
--- gcc/tree-ssa-ccp.c  (revision 178394)
+++ gcc/tree-ssa-ccp.c  (working copy)
@@ -1714,7 +1714,7 @@  fold_builtin_alloca_for_var (gimple stmt
   block = gimple_block (stmt);
   if (!(cfun->after_inlining
         && TREE_CODE (BLOCK_SUPERCONTEXT (block)) == FUNCTION_DECL))
-    threshold /= 10;
+    return NULL_TREE;
   if (size > threshold)
     return NULL_TREE;