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] Devirtualization dump functions fix



On 06/27/2014 10:38 AM, Richard Biener wrote:
On Thu, Jun 26, 2014 at 5:58 PM, Martin LiÅka <mliska@suse.cz> wrote:
On 06/26/2014 04:29 PM, Jakub Jelinek wrote:
On Thu, Jun 26, 2014 at 04:27:49PM +0200, Martin LiÅka wrote:
Well yes - it is of course similar broken in spirit but at least a lot
simpler ;)  I'd put a comment there why we do check g for NULL.
But it increases overhead, there are hundreds of gimple_location calls
and most of them will never pass NULL.  Can't you simply
do what you do in the inline here in the couple of spots where
the stmt might be NULL?
Sure, do you have any suggestion how should be called such function?
Suggestion: gimple_location_or_unknown ?
gimple_location_safe or gimple_safe_location?

         Jakub
Thanks, there's new patch.

Patch has been tested for Firefox with -flto -fdump-ipa-devirt.
Bootstrap and regression tests have been running.

Ready for trunk after regression tests?
Ok with s/gimple_safe_location/gimple_location_safe/ (I think that's
the more canonical naming - what's a "safe location" after all?)

Thanks,
Richard.
You are right, gimple_location_safe sounds better.
Patch has been just committed with your change.

Thanks,
Martin

ChangeLog:

2014-06-26  Martin Liska  <mliska@suse.cz>

     * gimple.h (gimple_safe_location): New function introduced.
     * cgraphunit.c (walk_polymorphic_call_targets): Usage
     of gimple_safe_location replaces gimple_location.
     (gimple_fold_call): Likewise.
     * ipa-devirt.c (ipa_devirt): Likewise.
     * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
     * ipa.c (walk_polymorphic_call_targets): Likewise.
     * tree-ssa-pre.c (eliminate_dom_walker::before_dom_children): Likewise.


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