Re: FDO usability patch -- cfg and lineno checksum

2011-04-27 Thread Xinliang David Li
On Wed, Apr 27, 2011 at 10:03 AM, Jan Hubicka wrote: >> >> -       else if (entry->checksum != checksum) >> >> +       else if (entry->lineno_checksum != lineno_checksum >> >> +                || entry->cfg_checksum != cfg_checksum) >> >>           { >> >>             error ("coverage mismatch for

Re: FDO usability patch -- cfg and lineno checksum

2011-04-27 Thread Jan Hubicka
> >> -       else if (entry->checksum != checksum) > >> +       else if (entry->lineno_checksum != lineno_checksum > >> +                || entry->cfg_checksum != cfg_checksum) > >>           { > >>             error ("coverage mismatch for function %u while reading > >> execution counters", > >>

Re: FDO usability patch -- cfg and lineno checksum

2011-04-27 Thread Xinliang David Li
On Wed, Apr 27, 2011 at 8:54 AM, Jan Hubicka wrote: > Please don't forget about changelogs.. >> Index: tree.c >> === >> --- tree.c    (revision 172802) >> +++ tree.c    (working copy) >> @@ -8513,14 +8513,12 @@ dump_tree_statistics (v

Re: FDO usability patch -- cfg and lineno checksum

2011-04-27 Thread Jan Hubicka
Please don't forget about changelogs.. > Index: tree.c > === > --- tree.c(revision 172802) > +++ tree.c(working copy) > @@ -8513,14 +8513,12 @@ dump_tree_statistics (void) The crc bits was already reviewed, right? > - el

Re: FDO usability patch -- cfg and lineno checksum

2011-04-27 Thread Xinliang David Li
Honza, any more comments? Thanks, David On Mon, Apr 25, 2011 at 9:35 AM, Xinliang David Li wrote: > Is the patch ok? > > Thanks, > > David > > On Fri, Apr 22, 2011 at 12:48 PM, Jan Hubicka wrote: >>> Please review the new patch which only implements cfg checksum. >>> >>> The auto version gener

Re: FDO usability patch -- cfg and lineno checksum

2011-04-25 Thread Xinliang David Li
Is the patch ok? Thanks, David On Fri, Apr 22, 2011 at 12:48 PM, Jan Hubicka wrote: >> Please review the new patch which only implements cfg checksum. >> >> The auto version generation was introduced in 2002 before FDO support >> was added (so the old way never existed), so it might be better t

Re: FDO usability patch -- cfg and lineno checksum

2011-04-22 Thread Jan Hubicka
> Please review the new patch which only implements cfg checksum. > > The auto version generation was introduced in 2002 before FDO support > was added (so the old way never existed), so it might be better to > make the change independent of this one. FDO support was there well before 2002, just

Re: FDO usability patch -- cfg and lineno checksum

2011-04-22 Thread Xinliang David Li
Please review the new patch which only implements cfg checksum. The auto version generation was introduced in 2002 before FDO support was added (so the old way never existed), so it might be better to make the change independent of this one. Thanks, David On Thu, Apr 21, 2011 at 2:15 PM, Xinlia

Re: FDO usability patch -- cfg and lineno checksum

2011-04-21 Thread Xinliang David Li
On Thu, Apr 21, 2011 at 1:43 PM, Jan Hubicka wrote: >> > I don't really follow the logic here.  buffer is allocated to be size of >> > block+4 and it is expected that gcov_write_words is not executed on size >> > greater than 4.  Since gcov_write_string now seems to be expected to handle >> > stri

Re: FDO usability patch -- cfg and lineno checksum

2011-04-21 Thread Jan Hubicka
> > I don't really follow the logic here.  buffer is allocated to be size of > > block+4 and it is expected that gcov_write_words is not executed on size > > greater than 4.  Since gcov_write_string now seems to be expected to handle > > strings of bigger size, I think you acually need to make writ

Re: FDO usability patch -- cfg and lineno checksum

2011-04-21 Thread Diego Novillo
On Tue, Apr 19, 2011 at 15:47, Xinliang David Li wrote: > The attached is the revised patch with a warning suggested for cases > when CFG matches, but source locations change. > > Ok for trunk? The tree.c changes are OK. Diego.

Re: FDO usability patch -- cfg and lineno checksum

2011-04-20 Thread Xinliang David Li
On Tue, Apr 19, 2011 at 3:20 PM, Jan Hubicka wrote: > I can not review tree.c changes.  I would probably suggest making crc_byte > inline. Diego, can you review this change? This is just a simple refactoring. > >> +#if IN_LIBGCOV >> + >> +/* These functions are guarded by #if to avoid compile

Re: FDO usability patch -- cfg and lineno checksum

2011-04-19 Thread Jan Hubicka
I can not review tree.c changes. I would probably suggest making crc_byte inline. > +#if IN_LIBGCOV > + > +/* These functions are guarded by #if to avoid compile time warning. */ > + > +/* Return the number of words STRING would need including the length > + field in the output stream itself.

Re: FDO usability patch -- cfg and lineno checksum

2011-04-19 Thread Xinliang David Li
The attached is the revised patch with a warning suggested for cases when CFG matches, but source locations change. Ok for trunk? thanks, David On Sun, Apr 17, 2011 at 8:36 AM, Jan Hubicka wrote: >> Hi,  in current FDO implementation, the source file version used in >> profile-generate needs t

Re: FDO usability patch -- cfg and lineno checksum

2011-04-17 Thread Xinliang David Li
On Sun, Apr 17, 2011 at 8:36 AM, Jan Hubicka wrote: >> Hi,  in current FDO implementation, the source file version used in >> profile-generate needs to strictly match the version used in >> profile-use -- simple formating changes will invalidate the profile >> data (use of it will lead to compiler

Re: FDO usability patch -- cfg and lineno checksum

2011-04-17 Thread Jan Hubicka
> Hi, in current FDO implementation, the source file version used in > profile-generate needs to strictly match the version used in > profile-use -- simple formating changes will invalidate the profile > data (use of it will lead to compiler error or ICE). There are two > main problems that lead t

Re: FDO usability patch -- cfg and lineno checksum

2011-04-15 Thread Xinliang David Li
Resent in plain text mode .. David On Fri, Apr 15, 2011 at 9:28 AM, Xinliang David Li wrote: > > Honza, do you have a chance to take a look at it? > Thanks, > > David > > On Wed, Apr 13, 2011 at 3:25 PM, Xinliang David Li wrote: >> >> Hi,  in current FDO implementation, the source file version

Re: FDO usability patch -- cfg and lineno checksum

2011-04-13 Thread Xinliang David Li
This was contributed by: 2011-04-13 Neil Vachharajani On Wed, Apr 13, 2011 at 3:25 PM, Xinliang David Li wrote: > Hi,  in current FDO implementation, the source file version used in > profile-generate needs to strictly match the version used in > profile-use -- simple formating changes will i

FDO usability patch -- cfg and lineno checksum

2011-04-13 Thread Xinliang David Li
Hi, in current FDO implementation, the source file version used in profile-generate needs to strictly match the version used in profile-use -- simple formating changes will invalidate the profile data (use of it will lead to compiler error or ICE). There are two main problems that lead to the weak