Bug 1522111 - disable opt builds/tests when we have pgo builds/tests for integration branches. r=ahal
authorJoel Maher <jmaher@mozilla.com>
Fri, 01 Feb 2019 21:45:22 +0000
changeset 456555 8d7c099bbe0dbb73c8b9eb3a356ffad3cdd0e723
parent 456554 756f2a2d201754603ef2cc856303abe4b48129dc
child 456556 2ff333373fe4cc5cdd2a05ff4686f1640be5b280
push id35489
push userrmaries@mozilla.com
push dateSat, 02 Feb 2019 21:36:03 +0000
treeherdermozilla-central@63348118ef1d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersahal
bugs1522111
milestone67.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1522111 - disable opt builds/tests when we have pgo builds/tests for integration branches. r=ahal disable opt builds when pgo exists for autoland/inbound and adjust seta to run those opt jobs on pgo. Differential Revision: https://phabricator.services.mozilla.com/D18104
taskcluster/ci/build/linux.yml
taskcluster/ci/build/windows.yml
taskcluster/taskgraph/util/seta.py
--- a/taskcluster/ci/build/linux.yml
+++ b/taskcluster/ci/build/linux.yml
@@ -16,16 +16,17 @@ linux64/opt:
         actions: [get-secrets, build, check-test]
         config:
             - builds/releng_base_firefox.py
             - builds/releng_base_linux_64_builds.py
         script: "mozharness/scripts/fx_desktop_build.py"
         secrets: true
         tooltool-downloads: public
         need-xvfb: true
+    run-on-projects: ['mozilla-central', 'try']
     toolchains:
         - linux64-binutils
         - linux64-clang
         - linux64-rust
         - linux64-rust-size
         - linux64-cbindgen
         - linux64-sccache
         - linux64-node
@@ -50,17 +51,17 @@ linux64-plain/opt:
         config:
             - builds/releng_base_firefox.py
             - builds/releng_base_linux_64_builds.py
         script: mozharness/scripts/fx_desktop_build.py
         tooltool-downloads: public
         extra-config:
             disable_package_metrics: true
         mozconfig-variant: plain-opt
-    run-on-projects: [trunk]
+    run-on-projects: ['mozilla-central', 'try']
     toolchains:
         - linux64-binutils
         - linux64-clang
         - linux64-rust
         - linux64-node
         - linux64-cbindgen
 
 linux64/pgo:
--- a/taskcluster/ci/build/windows.yml
+++ b/taskcluster/ci/build/windows.yml
@@ -53,16 +53,17 @@ win32/opt:
         options: [append-env-variables-from-configs]
         script: mozharness/scripts/fx_desktop_build.py
         config:
             - builds/releng_base_firefox.py
             - builds/taskcluster_base_windows.py
             - builds/taskcluster_base_win32.py
         extra-config:
             stage_platform: win32
+    run-on-projects: ['mozilla-central', 'try']
     toolchains:
         - win64-clang-cl
         - win64-rust
         - win64-rust-size
         - win64-cbindgen
         - win64-sccache
         - win64-node
 
@@ -192,17 +193,17 @@ win64-plain/debug:
         config:
             - builds/releng_base_firefox.py
             - builds/taskcluster_base_windows.py
             - builds/taskcluster_base_win64.py
         extra-config:
             disable_package_metrics: true
             stage_platform: win64
         mozconfig-variant: plain-debug
-    run-on-projects: [trunk]
+    run-on-projects: ['trunk']
     toolchains:
         - win64-clang-cl
         - win64-rust
         - win64-node
         - win64-cbindgen
 
 win64/opt:
     description: "Win64 Opt"
@@ -225,16 +226,17 @@ win64/opt:
         options: [append-env-variables-from-configs]
         script: mozharness/scripts/fx_desktop_build.py
         config:
             - builds/releng_base_firefox.py
             - builds/taskcluster_base_windows.py
             - builds/taskcluster_base_win64.py
         extra-config:
             stage_platform: win64
+    run-on-projects: ['mozilla-central', 'try']
     toolchains:
         - win64-clang-cl
         - win64-rust
         - win64-rust-size
         - win64-cbindgen
         - win64-sccache
         - win64-node
 
@@ -261,17 +263,17 @@ win64-plain/opt:
         config:
             - builds/releng_base_firefox.py
             - builds/taskcluster_base_windows.py
             - builds/taskcluster_base_win64.py
         extra-config:
             disable_package_metrics: true
             stage_platform: win64
         mozconfig-variant: plain-opt
-    run-on-projects: [trunk]
+    run-on-projects: ['mozilla-central', 'try']
     toolchains:
         - win64-clang-cl
         - win64-rust
         - win64-node
         - win64-cbindgen
 
 win32-nightly/opt:
     description: "Win32 Nightly"
@@ -414,17 +416,17 @@ win32-add-on-devel/opt:
         script: "mozharness/scripts/fx_desktop_build.py"
         config:
             - builds/releng_base_firefox.py
             - builds/taskcluster_base_windows.py
             - builds/taskcluster_base_win32.py
         extra-config:
             stage_platform: win32-add-on-devel
         mozconfig-variant: add-on-devel
-    run-on-projects: ['mozilla-beta', 'mozilla-release', 'mozilla-esr45']
+    run-on-projects: ['mozilla-beta', 'mozilla-release']
     toolchains:
         - win64-clang-cl
         - win64-rust
         - win64-rust-size
         - win64-cbindgen
         - win64-sccache
         - win64-node
 
@@ -448,17 +450,17 @@ win64-add-on-devel/opt:
         script: "mozharness/scripts/fx_desktop_build.py"
         config:
             - builds/releng_base_firefox.py
             - builds/taskcluster_base_windows.py
             - builds/taskcluster_base_win64.py
         extra-config:
             stage_platform: win64-on-devel
         mozconfig-variant: add-on-devel
-    run-on-projects: ['mozilla-beta', 'mozilla-release', 'mozilla-esr45']
+    run-on-projects: ['mozilla-beta', 'mozilla-release']
     toolchains:
         - win64-clang-cl
         - win64-rust
         - win64-rust-size
         - win64-cbindgen
         - win64-sccache
         - win64-node
 
--- a/taskcluster/taskgraph/util/seta.py
+++ b/taskcluster/taskgraph/util/seta.py
@@ -71,18 +71,30 @@ class SETA(object):
             if type(task_list) == dict and len(task_list) > 0:
                 if type(task_list.values()[0]) == list and len(task_list.values()[0]) > 0:
                     low_value_tasks = task_list.values()[0]
                     # bb job types return a list instead of a single string,
                     # convert to a single string to match tc tasks format
                     if type(low_value_tasks[0]) == list:
                         low_value_tasks = [self._get_task_string(x) for x in low_value_tasks]
 
+            # hack seta tasks to run 'opt' jobs on 'pgo' builds - see Bug 1522111
+            def opt_to_pgo(label):
+                opt = ['test-windows10-64/opt',
+                       'test-windows7-32/opt',
+                       'test-linux64/opt']
+                pgo = ['test-windows10-64-pgo/opt',
+                       'test-windows7-32-pgo/opt',
+                       'test-linux64-pgo/opt']
+                for iter in range(0, len(opt)):
+                    if label.startswith(opt[iter]):
+                        label = label.replace(opt[iter], pgo[iter])
+
             # ensure no build tasks slipped in, we never want to optimize out those
-            low_value_tasks = [x for x in low_value_tasks if 'build' not in x.lower()]
+            low_value_tasks = [opt_to_pgo(x) for x in low_value_tasks if 'build' not in x]
 
         # In the event of request times out, requests will raise a TimeoutError.
         except exceptions.Timeout:
             logger.warning("SETA timeout, we will treat all test tasks as high value.")
 
         # In the event of a network problem (e.g. DNS failure, refused connection, etc),
         # requests will raise a ConnectionError.
         except exceptions.ConnectionError: