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] var-tracking.c speedups


On Tue, Jun 23, 2009 at 2:51 PM, Jakub Jelinek<jakub@redhat.com> wrote:
> 4) in sel-sched merge, rtx_equal_p was moved to very infrequently used
> ? rtx_equal_p_cb with added callback and rtx_equal_p implemented on top
> ? of that new function. ?Given that rtx_equal_p was showing very high
> ? in the callgrind profile and is very frequently used throughout gcc
> ? rtl passes (400+ different callers), isn't too long to be a maintainance
> ? burden and is recursive, so we can't get rid of the overhead of passing
> ? cb around and checking at each level, I'm proposing returning to the
> ? old rtx_equal_p function and have rtx_equal_p_cb as completely separate
> ? function.

Please don't do that.

We already have too many RTL comparison functions:

* rtx_equal_p
* rtx_equal_p_cb
* rtx_renumbered_equal_p
* the latest version of my/Joern's patch for PR20070 adds another one.

All of them can be re-written as users of rtx_equal_p_cb with small
changes to the callback interface (I am working on a patch for that).

It's not the length of the function that is the problem.  It is the
duplication for all the special cases that hurts.

So, again, please don't make them separate functions.

Ciao!
Steven


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