This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH, tree-optimization]: FIX PR 36129; [4.3, 4.4 Regression] ICE with -fprofile-use
- From: "Richard Guenther" <richard dot guenther at gmail dot com>
- To: "Uros Bizjak" <ubizjak at gmail dot com>
- Cc: "gcc patches" <gcc-patches at gcc dot gnu dot org>
- Date: Fri, 9 May 2008 16:55:41 +0200
- Subject: Re: [PATCH, tree-optimization]: FIX PR 36129; [4.3, 4.4 Regression] ICE with -fprofile-use
- References: <5787cf470805090707q75e4e8f9m5544484fa53696dd@mail.gmail.com>
On Fri, May 9, 2008 at 4:07 PM, Uros Bizjak <ubizjak@gmail.com> wrote:
> Hello!
>
> As shown in the PR audit trail [1], "verify_histograms fail" ICE is
> triggered by "fold all builtins" pass where __builtin_memset() is
> folded/CCPed to a constant. If there is a histogram attached to
> __builtin_memset (as is the case in the PR), removing stmt without
> removing histogram leads to ICE.
>
> Attached patch calls gimple_remove_stmt_histograms, when builtin was
> folded to a constant. I was not able to extract a testcase from
> attached huge testcase, but the patch fixes the ICE with original
> CP2K build (+ a duplicate PR).
>
> 2008-05-09 Uros Bizjak <ubizjak@gmail.com>
>
> PR tree-optimization/36129
> * tree-ssa-cpp.c: Include value-prof.h.
> (execute_fold_all_builtins): Call gimple_remove_stmt_histograms if
> built-in function was folded to a constant.
> * Makefile.in (tree-ssa-cpp.c): Depend on value-prof.h
>
> Patch was bootstrapped and regression tested on i686-pc-linux-gnu. OK
> for mainline?
Yes.
Thanks,
Richard.