Bug 1382502 - Enable sccache on PGO builds. r=ted

Note this will only enable it on try, autoland and mozilla-inbound,
which are the only branches where sccache are enabled at the moment.
Enabling on more builds (or not) is the subject of bug 1373460.

Also note that bug 1181040, that ensured PGO builds weren't using
sccache mentions that back then, link times went up when using sccache
(with -Z7) vs. without, but that was presumably with MSVC 2013. Try
suggests link times are the same using sccache now (still using -Z7,
pending bug 1318370).
This commit is contained in:
Mike Hommey
2017-07-20 11:31:14 +09:00
parent 99fbfae27c
commit d89f522a9c
2 changed files with 4 additions and 2 deletions

View File

@@ -248,10 +248,12 @@ default::
@echo "===SCCACHE STATS==="
-$(CCACHE) --show-stats
@echo "==================="
ifndef MOZ_PROFILE_GENERATE
# Ideally we'd do that in the same file as we set the sccache.log location for
# sccache, but it's too late in the build.
-gzip -9 $(DIST)/sccache.log
endif
endif
distclean::
$(RM) $(DIST_GARBAGE)

View File

@@ -14,7 +14,7 @@ $(python2.7 -c 'import json; p = json.loads(open("'"$topsrcdir"'/../buildprops.j
EOF
bucket=
if test -z "$SCCACHE_DISABLE" -a -z "$MOZ_PGO_IS_SET" -a -z "$MOZ_PGO"; then
if test -z "$SCCACHE_DISABLE"; then
case "${branch}" in
try)
case "${master}" in
@@ -44,7 +44,7 @@ fi
fi
# builds where buildprops didn't have the data (eg: taskcluster or non-buildbot) and without sccache disabled:
if test -z "$bucket" -a -z "$SCCACHE_DISABLE" -a -z "$MOZ_PGO_IS_SET" -a -z "$MOZ_PGO"; then
if test -z "$bucket" -a -z "$SCCACHE_DISABLE"; then
# prevent rerun if az is set, or wget is not available
if test -z "$availability_zone" -a -x "$(command -v wget)"; then