Fix -fdump-passes

Submitted by Teresa Johnson on May 29, 2013, 8:11 p.m.

Details

Message ID CAAe5K+Vsdud+Xd2nqiW1OJktGGZgLWhdQEigznTha62wo0xanw@mail.gmail.com
State New
Headers show

Commit Message

Teresa Johnson May 29, 2013, 8:11 p.m.
This patch re-enables -fdump-passes. It had stopped working because
dump_passes was changed to use the FOR_EACH_DEFINED_FUNCTION iterator,
however, functions are not marked as defined until after dump_passes
is called, in cgraph_analyze_functions. Fixed by iterating over all
functions.

Bootstrapped and tested on x86-64-unknown-linux-gnu. Ok for trunk?

Thanks,
Teresa

2013-05-29  Teresa Johnson  <tejohnson@google.com>

* passes.c (dump_passes): Use FOR_EACH_FUNCTION since
        functions are not yet marked as defined.



--
Teresa Johnson | Software Engineer | tejohnson@google.com | 408-460-2413

Comments

Jeff Law May 29, 2013, 8:32 p.m.
On 05/29/2013 02:11 PM, Teresa Johnson wrote:
> This patch re-enables -fdump-passes. It had stopped working because
> dump_passes was changed to use the FOR_EACH_DEFINED_FUNCTION iterator,
> however, functions are not marked as defined until after dump_passes
> is called, in cgraph_analyze_functions. Fixed by iterating over all
> functions.
>
> Bootstrapped and tested on x86-64-unknown-linux-gnu. Ok for trunk?
>
> Thanks,
> Teresa
>
> 2013-05-29  Teresa Johnson  <tejohnson@google.com>
>
> * passes.c (dump_passes): Use FOR_EACH_FUNCTION since
>          functions are not yet marked as defined.
OK, Assuming you fix the whitespace in the ChangeLog entry.

jeff
Teresa Johnson May 29, 2013, 8:51 p.m.
On Wed, May 29, 2013 at 1:32 PM, Jeff Law <law@redhat.com> wrote:
> On 05/29/2013 02:11 PM, Teresa Johnson wrote:
>>
>> This patch re-enables -fdump-passes. It had stopped working because
>> dump_passes was changed to use the FOR_EACH_DEFINED_FUNCTION iterator,
>> however, functions are not marked as defined until after dump_passes
>> is called, in cgraph_analyze_functions. Fixed by iterating over all
>> functions.
>>
>> Bootstrapped and tested on x86-64-unknown-linux-gnu. Ok for trunk?
>>
>> Thanks,
>> Teresa
>>
>> 2013-05-29  Teresa Johnson  <tejohnson@google.com>
>>
>> * passes.c (dump_passes): Use FOR_EACH_FUNCTION since
>>          functions are not yet marked as defined.
>
> OK, Assuming you fix the whitespace in the ChangeLog entry.

Fixed and committed at r199424. Thanks, Teresa

>
> jeff
>



--
Teresa Johnson | Software Engineer | tejohnson@google.com | 408-460-2413

Patch hide | download patch | download mbox

Index: passes.c
===================================================================
--- passes.c (revision 199199)
+++ passes.c (working copy)
@@ -718,7 +718,7 @@  dump_passes (void)

   create_pass_tab();

-  FOR_EACH_DEFINED_FUNCTION (n)
+  FOR_EACH_FUNCTION (n)
     if (DECL_STRUCT_FUNCTION (n->symbol.decl))
       {
  node = n;