This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH] var-tracking.c speedups
- From: Steven Bosscher <stevenb dot gcc at gmail dot com>
- To: Jakub Jelinek <jakub at redhat dot com>
- Cc: gcc-patches at gcc dot gnu dot org, Alexandre Oliva <aoliva at redhat dot com>
- Date: Tue, 23 Jun 2009 16:50:41 +0200
- Subject: Re: [PATCH] var-tracking.c speedups
- References: <20090623125102.GC4462@tyan-ft48-01.lab.bos.redhat.com>
On Tue, Jun 23, 2009 at 2:51 PM, Jakub Jelinek<email@example.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:
* 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.