This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Fix indirect call profiling for COMDAT symbols
- From: Jakub Jelinek <jakub at redhat dot com>
- To: Jan Hubicka <hubicka at ucw dot cz>
- Cc: rguenther at suse dot de, gcc-patches at gcc dot gnu dot org
- Date: Mon, 14 Apr 2014 19:25:44 +0200
- Subject: Re: Fix indirect call profiling for COMDAT symbols
- Authentication-results: sourceware.org; auth=none
- References: <20140411060023 dot GG12814 at kam dot mff dot cuni dot cz> <20140414172237 dot GA15009 at kam dot mff dot cuni dot cz>
- Reply-to: Jakub Jelinek <jakub at redhat dot com>
On Mon, Apr 14, 2014 at 07:22:37PM +0200, Jan Hubicka wrote:
> > Hi,
> > while looking into firefox profiles, I noticed that we miss devirtualizations
> > to comdat symbols, because we manage to get different profile_id in each
> > unit. This is easily fixed by the following patch that makes profiled_id
> > to by crc32 of the symbol name in this case.
> >
> > Bootstrapped/regtested x86_64-linux, tested with firefox, will
> > commit it tomorrow.
>
> this is version I comitted with minor change of using the coverage checksum
> because I think some of anonymous namespace functions do get exported with
> random seed attached in a very side case.
>
> To answer Martin's question, I am just removing the tp_first_run merging code becuase
> it is done twice - second time in ipa_merge_profiles.
>
> Jakub/Richi: I would like to see this in 4.9 (it is missed optimization compared
> to 4.8). Let me know when it is OK to commit it (perhaps minus the lto-symtab.c
> change that is not necessary).
For missed optimization at this point I'd prefer not to put it into 4.9.0
GA, for whether it is ok for 4.9.1 I'll defer to Richi.
Jakub