This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [RFC/RFA] speed up cp_genericize a little
- From: Geoffrey Keating <geoffk at geoffk dot org>
- To: Andrew Pinski <pinskia at physics dot uc dot edu>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: 15 Nov 2004 10:59:24 -0800
- Subject: Re: [RFC/RFA] speed up cp_genericize a little
- References: <7A725D17-3736-11D9-89EF-000A95D692F4@physics.uc.edu>
Andrew Pinski <pinskia@physics.uc.edu> writes:
> I noticed that a large amount of the time while "genericizing" in
> htab_find_slot but I also notice that we don't need a full fledge
> hashtable but only a pointer set. This patch changes the hashtable
> to be a pointer set and should speed up C++ compiling (even at -O0).
> (Note I did not do timings but I know that htab_find_slot is very heavy
> weight and this should speed it up no matter what.
>
> OK? Bootstrapped on powerpc-darwin with no regressions.
>
> Thanks,
> Andrew Pinski
>
> ChangeLog:
>
> * cp-gimplify.c: Include pointer-set.h
> (cp_genericize_r): Use pointer_sets instead of a hashtable.
> Also instert the new statement for CLEANUP_STMT.
> (cp_genericize): Use pointer_sets instead of a hashtable.
> * Make-lang.in (cp-gimplify.o): Depend on pointer-set.h.
This is OK.