Bug 1656465 - [taskgraph.optimize] Rename 'push-interval-{10,20}' strategies to 'expanded' and 'backstop' respectively, r=marco

This removes the last uses of the 'push-interval-10' and 'push-interval-20' strategies.
They are being removed because they are dangerous in that its easy to accidentally not run
tasks when they should.

Instead, task authors should decide whether they want their tasks to run on
"backstop" pushes (run everything) or "expanded" pushes (run more than usual,
but still not as much as a backstop). Note that using "expanded" means the task
will *also* run on backstop pushes. It'll just additionally run on "expanded"
pushes.

In practice 'backstop' pushes will be every 20th push and 'expanded' pushes
will be every 10th push. Though this may vary due to the time component in
backstops.

Differential Revision: https://phabricator.services.mozilla.com/D89503
This commit is contained in:
Andrew Halberstadt 2020-09-10 14:47:02 +00:00
Родитель 3abd53ae2c
Коммит 455f1d3e89
18 изменённых файлов: 39 добавлений и 41 удалений

Просмотреть файл

@ -107,4 +107,4 @@ jobs:
- builds/releng_base_android_64_builds.py
- taskcluster_nightly.py
optimization:
push-interval-20: null
skip-unless-backstop: null

Просмотреть файл

@ -381,7 +381,7 @@ android-api-16-gcp/debug:
- linux64-clang
- linux64-sccache
optimization:
push-interval-20: null
skip-unless-backstop: null
android-x86-gcp/opt:
@ -409,7 +409,7 @@ android-x86-gcp/opt:
- linux64-clang
- linux64-sccache
optimization:
push-interval-20: null
skip-unless-backstop: null
android-api-16-gcp/opt:
description: "Android 4.0 api-16+ Opt - built on GCP"
@ -436,7 +436,7 @@ android-api-16-gcp/opt:
- linux64-clang
- linux64-sccache
optimization:
push-interval-20: null
skip-unless-backstop: null
android-aarch64-gcp/opt:
description: "Android 5.0 AArch64 Opt - built on GCP"
@ -463,7 +463,7 @@ android-aarch64-gcp/opt:
- linux64-clang
- linux64-sccache
optimization:
push-interval-20: null
skip-unless-backstop: null
android-aarch64-gcp/debug:
description: "Android 5.0 AArch64 Debug - built on GCP"
@ -490,7 +490,7 @@ android-aarch64-gcp/debug:
- linux64-clang
- linux64-sccache
optimization:
push-interval-20: null
skip-unless-backstop: null
android-x86_64-gcp/opt:
description: "Android 5.0 x86-64 Opt - built on GCP"
@ -517,7 +517,7 @@ android-x86_64-gcp/opt:
- linux64-clang
- linux64-sccache
optimization:
push-interval-20: null
skip-unless-backstop: null
android-x86_64-gcp/debug:
description: "Android 5.0 x86-64 Debug - built on GCP"
@ -542,7 +542,7 @@ android-x86_64-gcp/debug:
toolchain:
- linux64-clang
optimization:
push-interval-20: null
skip-unless-backstop: null
android-x86_64-asan-fuzzing/opt:
description: "Android 5.0 x86-64 Fuzzing Opt ASAN"

Просмотреть файл

@ -54,7 +54,7 @@ linux64-base-toolchains/debug:
platform: linux64/debug
symbol: Bb
optimization:
push-interval-10: null
skip-unless-expanded: null
worker-type: b-linux
worker:
docker-image: {in-tree: debian8-amd64-build-base}
@ -136,7 +136,7 @@ linux64-base-toolchains-clang/debug:
platform: linux64/debug
symbol: Bbc
optimization:
push-interval-10: null
skip-unless-expanded: null
worker-type: b-linux
worker:
docker-image: {in-tree: debian8-amd64-build-base}

Просмотреть файл

@ -81,7 +81,7 @@ linux64-plain/opt:
- linux64-cbindgen
- linux64-dump-syms
optimization:
push-interval-10: null
skip-unless-expanded: null
linux64-fuzzing/debug:
description: "Linux64 Fuzzing Debug"
@ -281,7 +281,7 @@ linux64-plain/debug:
- linux64-cbindgen
- linux64-dump-syms
optimization:
push-interval-10: null
skip-unless-expanded: null
linux64-devedition/opt:
description: "Linux64 devedition (shippable)"
@ -1011,7 +1011,7 @@ linux64-asan/debug:
# this dependency can be removed.
- linux64-fix-stacks
optimization:
push-interval-10: null
skip-unless-expanded: null
linux64-shippable/opt:
description: "Linux64 Shippable"
@ -1324,7 +1324,7 @@ linux64-aarch64/opt:
- linux64-lucetc
- wasi-sysroot
optimization:
push-interval-10: null
skip-unless-expanded: null
linux-gcp/debug:
description: "Linux32 Debug - built on GCP"
@ -1375,7 +1375,7 @@ linux-gcp/debug:
# this dependency can be removed.
- linux64-fix-stacks
optimization:
push-interval-20: null
skip-unless-backstop: null
linux-gcp/opt:
description: "Linux32 Opt - built on GCP"
@ -1467,7 +1467,7 @@ linux64-gcp/debug:
# this dependency can be removed.
- linux64-fix-stacks
optimization:
push-interval-20: null
skip-unless-backstop: null
linux64-gcp/opt:
description: "Linux64 Opt - built on GCP"

Просмотреть файл

@ -316,7 +316,7 @@ macosx64-gcp/debug:
- linux64-sccache
- wasi-sysroot
optimization:
push-interval-20: null
skip-unless-backstop: null
macosx64-gcp/opt:
description: "MacOS X x64 Cross-compile - built on GCP"

Просмотреть файл

@ -13,7 +13,7 @@ job-defaults:
script: mozharness/scripts/fx_desktop_build.py
need-xvfb: false
optimization:
push-interval-10: null
skip-unless-expanded: null
win32-mingwclang/opt:
description: "Win32 MinGW-Clang Opt"

Просмотреть файл

@ -249,7 +249,7 @@ win64-plain/debug:
- win64-cbindgen
- win64-winchecksec
optimization:
push-interval-10: null
skip-unless-expanded: null
win64/opt:
description: "Win64 Opt"
@ -345,7 +345,7 @@ win64-plain/opt:
- win64-cbindgen
- win64-winchecksec
optimization:
push-interval-10: null
skip-unless-expanded: null
win32-shippable/opt:
description: "Win32 Opt Shippable"
@ -923,7 +923,7 @@ win64-asan/debug:
- win32-fix-stacks
- win64-winchecksec
optimization:
push-interval-10: null
skip-unless-expanded: null
win64-asan/opt:
description: "Win64 Opt ASAN"
@ -1229,7 +1229,7 @@ win64-aarch64/debug:
- nsis-3.01-win
- upx-3.95-win
optimization:
push-interval-10: null
skip-unless-expanded: null
win64-aarch64/opt:
description: "AArch64 Win64 Opt"
@ -1289,7 +1289,7 @@ win64-aarch64/opt:
- nsis-3.01-win
- upx-3.95-win
optimization:
push-interval-10: null
skip-unless-expanded: null
win64-aarch64-eme/opt:
description: "AArch64 Win64 Opt w/ EME"
@ -1332,7 +1332,7 @@ win64-aarch64-eme/opt:
- nsis-3.01-win
- upx-3.95-win
optimization:
push-interval-10: null
skip-unless-expanded: null
win64-aarch64-shippable/opt:
description: "AArch64 Win64 Shippable"
@ -1431,7 +1431,7 @@ win64-aarch64-shippable/opt:
- nsis-3.01-win
- upx-3.95-win
optimization:
push-interval-10: null
skip-unless-expanded: null
win64-aarch64-shippable-no-eme/opt:
description: "AArch64 Win64 Shippable w/o EME"
@ -1493,7 +1493,7 @@ win64-aarch64-shippable-no-eme/opt:
- nsis-3.01-win
- upx-3.95-win
optimization:
push-interval-10: null
skip-unless-expanded: null
win64-aarch64-devedition/opt:
description: "AArch64 Win64 Dev Edition (shippable)"

Просмотреть файл

@ -61,7 +61,7 @@ jobs:
# This is necessary to avoid building `build-win64-aarch64` on every push on autoland
# A more robust fix for this is https://bugzilla.mozilla.org/show_bug.cgi?id=1643346
optimization:
push-interval-10: null
skip-unless-expanded: null
reproducible-linux32:
symbol: Linux32

Просмотреть файл

@ -76,4 +76,4 @@ jobs:
- linux64-lucetc
- wasi-sysroot
optimization:
push-interval-20: null
skip-unless-backstop: null

Просмотреть файл

@ -43,7 +43,7 @@ job-defaults:
toolchain:
- linux64-custom-v8
optimization:
push-interval-10: null
skip-unless-expanded: null
bench-ares6:
description: Ares6 JavaScript shell benchmark suite

Просмотреть файл

@ -68,7 +68,7 @@ job-defaults:
# Bug 1635749, disable window recorder temporarily
- --browsertime-no-ffwindowrecorder
optimization:
push-interval-20: null
skip-unless-backstop: null
variants:
by-app:
chrome-m: []

Просмотреть файл

@ -21,7 +21,7 @@ job-defaults:
extra-options:
- --no-conditioned-profile
optimization:
push-interval-20: null
skip-unless-backstop: null
raptor-speedometer-geckoview:
description: "Raptor Speedometer on GeckoView"

Просмотреть файл

@ -59,4 +59,4 @@ jobs:
- linux64-lucetc
- wasi-sysroot
optimization:
push-interval-10: null
skip-unless-expanded: null

Просмотреть файл

@ -42,4 +42,4 @@ job-template:
command: /builds/worker/bin/run-visual-metrics.py -- --orange --perceptual --contentful --force --renderignore 5 --json --viewport
checkout: false
optimization:
push-interval-20: null
skip-unless-backstop: null

Просмотреть файл

@ -503,7 +503,7 @@ import_sibling_modules()
# Register composite strategies.
register_strategy('build', args=('skip-unless-schedules',))(Alias)
register_strategy('build-fuzzing', args=('push-interval-10', 'skip-unless-backstop'))(All)
register_strategy('build-fuzzing', args=('skip-unless-expanded',))(Alias)
register_strategy('test', args=('skip-unless-schedules',))(Alias)
register_strategy('test-inclusive', args=('skip-unless-schedules',))(Alias)
register_strategy('test-verify', args=('skip-unless-schedules',))(Alias)
@ -569,7 +569,7 @@ class project(object):
),
),
'build': All(
'push-interval-10',
'skip-unless-expanded',
Any(
'skip-unless-schedules',
'bugbug-reduced-fallback',

Просмотреть файл

@ -16,8 +16,6 @@ class SkipUnlessBackstop(OptimizationStrategy):
return not params["backstop"]
@register_strategy("push-interval-10", args=(10,))
@register_strategy("push-interval-20", args=(20,))
class SkipUnlessPushInterval(OptimizationStrategy):
"""Always removes tasks except every N pushes.

Просмотреть файл

@ -355,7 +355,7 @@ def apply_tier_optimization(config, tests):
yield test
continue
test['optimization'] = {'push-interval-10': None}
test['optimization'] = {'skip-unless-expanded': None}
if test['tier'] > 1:
test['optimization'] = {'push-interval-20': None}
test['optimization'] = {'skip-unless-backstop': None}
yield test

Просмотреть файл

@ -229,8 +229,8 @@ OptimizationSchema = voluptuous.Any(
# never optimize this task
{'never': None},
# skip the task except for every Nth push
{'push-interval-10': None},
{'push-interval-20': None},
{'skip-unless-expanded': None},
{'skip-unless-backstop': None},
# skip this task if none of the given file patterns match
{'skip-unless-changed': [text_type]},
# skip this task if unless the change files' SCHEDULES contains any of these components