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: [patch] ipa/ipcp partitioning





Daniel Berlin <dberlin@dberlin.org> wrote on 18/05/2005 19:57:59:

> Your ipcp_method_contains_asm is overcomplex.
>
> all ASM's appear bare.
>
> IE the following will suffice:
>
>
> /*  Finds if there are any asm expr in the function.  */
> static bool
> ipcp_method_contains_asm (ipa_method mt)
> {
>   tree decl;
>   tree body;
>   block_stmt_iterator bsi;
>   tree stmt;
>   struct function *func;
>   basic_block bb;
>
>   decl = mt->decl;
>   body = DECL_SAVED_TREE (decl);
>   if (body != NULL)
>     {
>       func = DECL_STRUCT_FUNCTION (decl);
>       FOR_EACH_BB_FN (bb, func)
>       {
>         for (bsi = bsi_start (bb); !bsi_end_p (bsi); bsi_next (&bsi))
>           {
>             stmt = bsi_stmt (bsi);
>        if (TREE_CODE (stmt) == ASM_EXPR)
>               return true;
>           }
>       }
>     }
>   return false;
> }
>
>

Daniel,

Thanks a lot for suggestion. I have talked to Razya.
It's found out she know about that. The patch I submitted
here is only splitting, without functionality changes
(to prepare a room for ipaa :) ).

olga





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