This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: make gcov counters 64bit take 2
> On Thu, Jun 14, 2001 at 04:46:21PM +0200, Jan Hubicka wrote:
> > updated patch. Now chooses the GCOV_TYPE_SIZE as LONG_TYPE_SIZE if it is
> > greater or equal to 64. Otherwise LONG_LONG_TYPE_SIZE is used.
> > This way 72bit long targets noted by Lars will be happy.
>
> One thing -- GCOV_TYPE_SIZE should be overridable by the target.
>
> At some point we need the option to generate atomic updates to
> the counters so that we can collect profile data for threaded
> programs. Since we're annotating those edges off the minimal
> spanning tree, any missed updates means we can't solve the
> graph. The target may not be able to do atomic updates on a
> 64-bit counter.
Good point. Perhaps we can later add special expander for the
code increasing counters. 64bit is really a must.
Perhaps better solution is to fork the tables as we do for errno..
Concerning the re-defining, I've tought about that. Thats why
GCOV_TYPE_SIZE is defined in defaults.h. Re-defining it to
something else will cause gcc to use it.
(well because of the libgcc2.c bits it must be eighter long or long long,
but I think it is not big problem).
I am defining gcov_type to HOST_WIDEST_INT at basic-block.h and
gcov.c, but these are just for analyzis and it doesn't matter
if the sizes don't match.
Honza
>
>
> r~