[Bug gcov-profile/47618] Collecting multiple profiles and using all for PGO
marxin at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Tue Jun 6 19:19:00 GMT 2017
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=47618
--- Comment #14 from Martin Liška <marxin at gcc dot gnu.org> ---
Created attachment 41481
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=41481&action=edit
Patch candidate
I'm attaching patch that supports following expansion of -fprofile-dir (or
arguments of -fprofile-generate and -fprofile-use) option value:
%w - expands during compile time to working directory; it's handy when one
wants to preserve tree hierarchy of gcda files corresponding to another build
directory
%p - expands during run-time to PID
%q{ENV} - expands to value of environmental variable 'ENV' during run-time
Having that, I guess we can eventually drop GCOV_PREFIX_STRIP and GCOV_PREFIX
as one can use -fprofile-dir="%q{PREFIX}" and then e.g. set
PREFIX="../my/folder/".
Feel free to comment the patch.
More information about the Gcc-bugs
mailing list