From: mstembera Date: Tue, 3 Feb 2015 03:09:37 +0000 (+0800) Subject: Profile build options X-Git-Url: https://git.sesse.net/?p=stockfish;a=commitdiff_plain;h=f4136c54348d06a581d38d43ca6b6f730b3eb258;hp=ddccb5355cabb7d1a9bf2c0fe3c51b3da0234260;ds=sidebyside Profile build options I went through all the individual compile options that differ between -fprofile-generate/-fprofile-use and -fprofile-arcs/-fbranch-probabilities and distilled the speed difference down to only turning off -fno-peel-loops and -fno-tracer. Using this we still get the full speedup (maybe a bit more because other optimizations stay on) and it's also much cleaner because we can get rid of the "@rm -f ucioption.gc*" hack for all versions of gcc. No functional change. Resolves #237 --- diff --git a/src/Makefile b/src/Makefile index 53bbc1f4..ce8421a4 100644 --- a/src/Makefile +++ b/src/Makefile @@ -447,16 +447,13 @@ gcc-profile-prepare: gcc-profile-make: $(MAKE) ARCH=$(ARCH) COMP=$(COMP) \ - EXTRACXXFLAGS='-fprofile-arcs' \ + EXTRACXXFLAGS='-fprofile-generate' \ EXTRALDFLAGS='-lgcov' \ all gcc-profile-use: -# Deleting corrupt ucioption.gc* profile files is necessary to avoid an -# "internal compiler error" for gcc versions 4.7.x - @rm -f ucioption.gc* $(MAKE) ARCH=$(ARCH) COMP=$(COMP) \ - EXTRACXXFLAGS='-fbranch-probabilities' \ + EXTRACXXFLAGS='-fprofile-use -fno-peel-loops -fno-tracer' \ EXTRALDFLAGS='-lgcov' \ all