diff options
author | Eugene Rozenfeld <erozen@microsoft.com> | 2022-11-21 13:33:38 -0800 |
---|---|---|
committer | Eugene Rozenfeld <erozen@microsoft.com> | 2023-04-28 13:15:33 -0700 |
commit | 0c77a0909456034d34036aa22a8dfcf0258cfa2d (patch) | |
tree | 9dd6aee44439480c4c858d250b1d9156ed746c48 /gcc/c | |
parent | 065be0ffbcd676b635d492f4679e635b6ece4fe4 (diff) | |
download | gcc-0c77a0909456034d34036aa22a8dfcf0258cfa2d.zip gcc-0c77a0909456034d34036aa22a8dfcf0258cfa2d.tar.gz gcc-0c77a0909456034d34036aa22a8dfcf0258cfa2d.tar.bz2 |
Fix autoprofiledbootstrap build
1. Fix gcov version
2. Merge perf data collected when compiling the compiler and runtime libraries
3. Fix documentation typo
Tested on x86_64-pc-linux-gnu.
ChangeLog:
* Makefile.in: Define PROFILE_MERGER
* Makefile.tpl: Define PROFILE_MERGER
gcc/c/ChangeLog:
* Make-lang.in: Merge perf data collected when compiling cc1 and runtime libraries
gcc/cp/ChangeLog:
* Make-lang.in: Merge perf data collected when compiling cc1plus and runtime libraries
gcc/lto/ChangeLog:
* Make-lang.in: Merge perf data collected when compiling lto1 and runtime libraries
gcc/ChangeLog:
* doc/install.texi: Fix documentation typo
Diffstat (limited to 'gcc/c')
-rw-r--r-- | gcc/c/Make-lang.in | 32 |
1 files changed, 29 insertions, 3 deletions
diff --git a/gcc/c/Make-lang.in b/gcc/c/Make-lang.in index b3b12dc..20840ac 100644 --- a/gcc/c/Make-lang.in +++ b/gcc/c/Make-lang.in @@ -88,9 +88,34 @@ cc1$(exeext): $(C_OBJS) cc1-checksum.o $(BACKEND) $(LIBDEPS) cc1-checksum.o $(BACKEND) $(LIBS) $(BACKENDLIBS) @$(call LINK_PROGRESS,$(INDEX.c),end) -cc1.fda: ../stage1-gcc/cc1$(exeext) ../prev-gcc/$(PERF_DATA) - $(CREATE_GCOV) -binary ../stage1-gcc/cc1$(exeext) -gcov cc1.fda -profile ../prev-gcc/$(PERF_DATA) -gcov_version 1 - +components_in_prev = "bfd opcodes binutils fixincludes gas gcc gmp mpfr mpc isl gold intl ld libbacktrace libcpp libcody libdecnumber libiberty libiberty-linker-plugin libiconv zlib lto-plugin libctf libsframe" +components_in_prev_target = "libstdc++-v3 libsanitizer libvtv libgcc libbacktrace libphobos zlib libgomp libatomic" + +.PHONY: create_fdas_for_cc1 + +cc1.fda: create_fdas_for_cc1 + $(PROFILE_MERGER) $(shell ls -ha cc1_*.fda) --output_file cc1.fda -gcov_version 2 + +create_fdas_for_cc1: ../stage1-gcc/cc1$(exeext) ../prev-gcc/$(PERF_DATA) + for component_in_prev in "$(components_in_prev)"; do \ + perf_path=../prev-$$component_in_prev/$(PERF_DATA); \ + echo "Perf path:"; \ + echo $$perf_path; \ + if [ -f $$perf_path ]; then \ + profile_name=cc1_$$component_in_prev.fda; \ + $(CREATE_GCOV) -binary ../stage1-gcc/cc1$(exeext) -gcov $$profile_name -profile $$perf_path -gcov_version 2; \ + fi; \ + done; + + for component_in_prev_target in "$(components_in_prev_target)"; do \ + perf_path=../prev-$(TARGET_SUBDIR)/$$component_in_prev_target/$(PERF_DATA); \ + echo "Perf path:"; \ + echo $$perf_path; \ + if [ -f $$perf_path ]; then \ + profile_name=cc1_$$component_in_prev_target.fda; \ + $(CREATE_GCOV) -binary ../stage1-gcc/cc1$(exeext) -gcov $$profile_name -profile $$perf_path -gcov_version 2; \ + fi; \ + done; # # Build hooks: @@ -181,6 +206,7 @@ c.mostlyclean: -rm -f c/*$(objext) -rm -f c/*$(coverageexts) -rm -f cc1.fda + -rm -f cc1_*.fda c.clean: c.distclean: -rm -f c/config.status c/Makefile |