https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98668

Martin Liška <marxin at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |INVALID

--- Comment #1 from Martin Liška <marxin at gcc dot gnu.org> ---
Thank you for the nice report.

You are right, there's only one called of do_per_function_toporder at it's from
execute_ipa_pass_list where current_function_decl == NULL.

However, reading the commend for the function:

/* If we are in IPA mode (i.e., current_function_decl is NULL), call
   function CALLBACK for every function in the call graph.  Otherwise,
   call CALLBACK on the current function.
   This function is global so that plugins can use it.  */

It's a plugin API entry point, so one can theoretically call it with
current_function_decl != NULL.

Reply via email to