This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Fix tuples branch bootstrap


On Sat, Jul 26, 2008 at 1:18 PM, Jan Hubicka <jh@suse.cz> wrote:
>
> Hi,
> this patch fixes segfault on tuples branch building with --enable-gather-detailed-mem-stats.
> CALL_STMT_CANNOT_INLINE_P is generic thingy, gimple_call_set_cannot_inline, is for gimple.
> This is fallout from merging function specific changes flag.
>
> This is just one problem with this: the calls in question is call to fputc_unlocked because
> the function is marked by the code as optimized for size.  This is quite wrong.
>
> Also we should not handle hot/cold attributes at function level when there is
> BB granuality infrastructure for doing so.
>
> I am testing it and will commit as obvious.  This will hopefully make memory
> tester to produce results.

Thanks, I removed the unused macro as a followup.

Richard.

> Honza
>
>        * ipa-inline.c (cgraph_decide_inlining_of_small_function, cgraph_decide_inlining,
>        cgraph_decide_inlining_incrementally):  Use gimple_call_set_cannot_inline.
> Index: ipa-inline.c
> ===================================================================
> *** ipa-inline.c        (revision 138165)
> --- ipa-inline.c        (working copy)
> *************** cgraph_decide_inlining_of_small_function
> *** 958,964 ****
>        }
>        if (!tree_can_inline_p (edge->caller->decl, edge->callee->decl))
>        {
> !         CALL_STMT_CANNOT_INLINE_P (edge->call_stmt) = true;
>          edge->inline_failed = N_("target specific option mismatch");
>          if (dump_file)
>            fprintf (dump_file, " inline_failed:%s.\n", edge->inline_failed);
> --- 958,964 ----
>        }
>        if (!tree_can_inline_p (edge->caller->decl, edge->callee->decl))
>        {
> !         gimple_call_set_cannot_inline (edge->call_stmt, true);
>          edge->inline_failed = N_("target specific option mismatch");
>          if (dump_file)
>            fprintf (dump_file, " inline_failed:%s.\n", edge->inline_failed);
> *************** cgraph_decide_inlining (void)
> *** 1110,1116 ****
>            continue;
>          if (!tree_can_inline_p (e->caller->decl, e->callee->decl))
>            {
> !             CALL_STMT_CANNOT_INLINE_P (e->call_stmt) = true;
>              continue;
>            }
>          cgraph_mark_inline_edge (e, true);
> --- 1110,1116 ----
>            continue;
>          if (!tree_can_inline_p (e->caller->decl, e->callee->decl))
>            {
> !             gimple_call_set_cannot_inline (e->call_stmt, true);
>              continue;
>            }
>          cgraph_mark_inline_edge (e, true);
> *************** cgraph_decide_inlining_incrementally (st
> *** 1342,1348 ****
>        }
>        if (!tree_can_inline_p (node->decl, e->callee->decl))
>        {
> !         CALL_STMT_CANNOT_INLINE_P (e->call_stmt) = true;
>          if (dump_file)
>            {
>              indent_to (dump_file, depth);
> --- 1342,1348 ----
>        }
>        if (!tree_can_inline_p (node->decl, e->callee->decl))
>        {
> !         gimple_call_set_cannot_inline (e->call_stmt, true);
>          if (dump_file)
>            {
>              indent_to (dump_file, depth);
> *************** cgraph_decide_inlining_incrementally (st
> *** 1450,1456 ****
>          }
>        if (!tree_can_inline_p (node->decl, e->callee->decl))
>          {
> !           CALL_STMT_CANNOT_INLINE_P (e->call_stmt) = true;
>            if (dump_file)
>              {
>                indent_to (dump_file, depth);
> --- 1450,1456 ----
>          }
>        if (!tree_can_inline_p (node->decl, e->callee->decl))
>          {
> !           gimple_call_set_cannot_inline (e->call_stmt, true);
>            if (dump_file)
>              {
>                indent_to (dump_file, depth);
>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]