This fixes an annoying thing on release branches - the gcov version changes from 407p to 407* at the single revisions that are releases and then back to 407p. That makes it impossible to consume profile-feedback data across the revisions on a branch.
As we do not change the gcov-version with patchlevel increases it makes no sense to change it for release vs. prerelease. Trunk is marked with experiental and thus is different. Tested on x86_64-unknown-linux-gnu, ok for all active branches? Thanks, Richard. 2012-06-21 Richard Guenther <rguent...@suse.de> PR gcov-profile/53744 * gcov-iov.c (main): Treat "" and "prerelease" the same. Index: gcc/gcov-iov.c =================================================================== *** gcc/gcov-iov.c (revision 188848) --- gcc/gcov-iov.c (working copy) *************** main (int argc, char **argv) *** 48,55 **** if (*ptr == '.') minor = strtoul (ptr + 1, 0, 10); phase = argv[2][0]; ! if (phase == '\0') phase = '*'; v[0] = (major < 10 ? '0' : 'A' - 10) + major; --- 48,61 ---- if (*ptr == '.') minor = strtoul (ptr + 1, 0, 10); + /* For releases the development phase is an empty string, for + prerelease versions on a release branch it is "prerelease". + Consider both equal as patch-level releases do not change + the GCOV version either. + On the trunk the development phase is "experimental". */ phase = argv[2][0]; ! if (phase == '\0' ! || strcmp (argv[2], "prerelease") == 0) phase = '*'; v[0] = (major < 10 ? '0' : 'A' - 10) + major;