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, pretty-ipa] Nuke call graph edges when inlining in all cases


> Hi,
> 
> optimize_inline_calls()  always discards all  edges outgoing  from the
> function into  which it has previously inlined  other stuff.  However,
> this function is called from  ipa-inline.c only when there actually is
> some inlining  (or early inlining) to do.   Consequently, the outgoing
> edges  are either  stripped off  or  left hanging  there depending  on
> inlining decisions.
> 
> For  the sake  of  consistency,  the following  patch  moves the  edge
> cleansing  to  the  two  callers  of this  function  and  performs  it
> unconditionally.
> 
> Bootstrapped and tested on x86_64-suse-linux, OK for pretty-ipa?

It woudl probably make most sense to make this pass manager property
destroyed by local passes. Early inliner is not only reason why edges
are wrong, i.e. with -fno-early-inlining I think your patch will make
worng edges to appear to later local passes....
It is not very pretty to modify entires of every local pass we have to
destroy cgraph edges, but I wonder what alternatives we have?

Honza


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