On 01/13/2017 06:21 PM, Jeff Law wrote:
> On 01/13/2017 08:08 AM, Martin Liška wrote:
>> Hello.
>>
>> Nice example provided in the PR causes ICE as we have an artificial symbol
>> created in tree-profile.c once being removed by remove unreachable nodes 
>> (-O0)
>> and once not (-O1). Well, difference is in process_references where 
>> following hunk
>> prevent removal:
>>
>>           || (((before_inlining_p
>>             && ((TREE_CODE (node->decl) != FUNCTION_DECL
>>              && optimize)
>>
>> Anyway, these artificial symbols really should be just declarations as they 
>> are defined
>> in libgcov library.
>>
>> Patch can bootstrap on ppc64le-redhat-linux and survives regression tests.
>>
>> Ready to be installed?
>> Martin
>>
>>
>> 0001-Do-not-declare-artificial-variables-in-tree-profile..patch
>>
>>
>> From 87262b1b60009381fd943fb433bc38f5d5685ac9 Mon Sep 17 00:00:00 2001
>> From: marxin <mli...@suse.cz>
>> Date: Fri, 13 Jan 2017 13:12:57 +0100
>> Subject: [PATCH] Do not declare artificial variables in tree-profile.c to 
>> have
>>  a definition (PR lto/69188).
>>
>> gcc/testsuite/ChangeLog:
>>
>> 2017-01-13  Martin Liska  <mli...@suse.cz>
>>
>>     PR lto/69188
>>     * gcc.dg/lto/pr69188_0.c: New test.
>>     * gcc.dg/lto/pr69188_1.c: New test.
>>
>> gcc/ChangeLog:
>>
>> 2017-01-13  Martin Liska  <mli...@suse.cz>
>>
>>     PR lto/69188
>>     * tree-profile.c (init_ic_make_global_vars): Do not call
>>     finalize_decl.
>>     (gimple_init_gcov_profiler): Likewise.
> OK.
> jeff
> 

May I install the same patch to both active branches after it survives 
regression tests?

Thanks,
Martin

Reply via email to