mirror of
https://github.com/flutter/flutter.git
synced 2025-06-03 00:51:18 +00:00
Adding macrobenchmarks for DDC (#166617)
We're adding macrobenchmark support to DDC (AMD modules and our new hot-reload-capable module system) to be aware of any current/future performance regressions. I'm not terribly aware of the metrics collection pipeline; please let me know if we need to do any more work to see these tests run/report numbers to the proper dashboards.
This commit is contained in:
parent
a8a61a1c06
commit
10a1d1520e
28
.ci.yaml
28
.ci.yaml
@ -1663,6 +1663,34 @@ targets:
|
||||
["devicelab","hostonly", "linux"]
|
||||
task_name: web_benchmarks_canvaskit
|
||||
|
||||
- name: Linux web_benchmarks_ddc
|
||||
recipe: devicelab/devicelab_drone
|
||||
bringup: true
|
||||
presubmit: false
|
||||
timeout: 60
|
||||
properties:
|
||||
dependencies: >-
|
||||
[
|
||||
{"dependency": "chrome_and_driver", "version": "version:125.0.6422.141"}
|
||||
]
|
||||
tags: >
|
||||
["devicelab","hostonly", "linux"]
|
||||
task_name: web_benchmarks_ddc
|
||||
|
||||
- name: Linux web_benchmarks_ddc_hot_reload
|
||||
recipe: devicelab/devicelab_drone
|
||||
bringup: true
|
||||
presubmit: false
|
||||
timeout: 60
|
||||
properties:
|
||||
dependencies: >-
|
||||
[
|
||||
{"dependency": "chrome_and_driver", "version": "version:125.0.6422.141"}
|
||||
]
|
||||
tags: >
|
||||
["devicelab","hostonly", "linux"]
|
||||
task_name: web_benchmarks_ddc_hot_reload
|
||||
|
||||
- name: Linux web_benchmarks_skwasm
|
||||
recipe: devicelab/devicelab_drone
|
||||
presubmit: false
|
||||
|
@ -298,6 +298,8 @@
|
||||
/dev/devicelab/bin/tasks/run_release_test_windows.dart @loic-sharma @flutter/tool
|
||||
/dev/devicelab/bin/tasks/technical_debt__cost.dart @Piinks @flutter/framework
|
||||
/dev/devicelab/bin/tasks/web_benchmarks_canvaskit.dart @yjbanov @flutter/web
|
||||
/dev/devicelab/bin/tasks/web_benchmarks_ddc.dart @yjbanov @flutter/web
|
||||
/dev/devicelab/bin/tasks/web_benchmarks_ddc_hot_reload.dart @yjbanov @flutter/web
|
||||
/dev/devicelab/bin/tasks/web_benchmarks_skwasm.dart @eyebrowsoffire @flutter/web
|
||||
/dev/devicelab/bin/tasks/web_benchmarks_skwasm_st.dart @eyebrowsoffire @flutter/web
|
||||
/dev/devicelab/bin/tasks/windows_home_scroll_perf__timeline_summary.dart @jonahwilliams @flutter/engine
|
||||
|
@ -8,6 +8,11 @@ import 'package:flutter_devicelab/tasks/web_benchmarks.dart';
|
||||
/// Runs all Web benchmarks using the CanvasKit rendering backend.
|
||||
Future<void> main() async {
|
||||
await task(() async {
|
||||
return runWebBenchmark((useWasm: false, forceSingleThreadedSkwasm: false));
|
||||
return runWebBenchmark((
|
||||
useWasm: false,
|
||||
forceSingleThreadedSkwasm: false,
|
||||
useDdc: false,
|
||||
withHotReload: false,
|
||||
));
|
||||
});
|
||||
}
|
||||
|
18
dev/devicelab/bin/tasks/web_benchmarks_ddc.dart
Normal file
18
dev/devicelab/bin/tasks/web_benchmarks_ddc.dart
Normal file
@ -0,0 +1,18 @@
|
||||
// Copyright 2014 The Flutter Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
import 'package:flutter_devicelab/tasks/web_benchmarks.dart';
|
||||
|
||||
/// Runs all Web benchmarks using DDC.
|
||||
Future<void> main() async {
|
||||
await task(() async {
|
||||
return runWebBenchmark((
|
||||
useWasm: false,
|
||||
forceSingleThreadedSkwasm: false,
|
||||
useDdc: true,
|
||||
withHotReload: false,
|
||||
));
|
||||
});
|
||||
}
|
18
dev/devicelab/bin/tasks/web_benchmarks_ddc_hot_reload.dart
Normal file
18
dev/devicelab/bin/tasks/web_benchmarks_ddc_hot_reload.dart
Normal file
@ -0,0 +1,18 @@
|
||||
// Copyright 2014 The Flutter Authors. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style license that can be
|
||||
// found in the LICENSE file.
|
||||
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
import 'package:flutter_devicelab/tasks/web_benchmarks.dart';
|
||||
|
||||
/// Runs all Web benchmarks using DDC.
|
||||
Future<void> main() async {
|
||||
await task(() async {
|
||||
return runWebBenchmark((
|
||||
useWasm: false,
|
||||
forceSingleThreadedSkwasm: false,
|
||||
useDdc: true,
|
||||
withHotReload: true,
|
||||
));
|
||||
});
|
||||
}
|
@ -8,6 +8,11 @@ import 'package:flutter_devicelab/tasks/web_benchmarks.dart';
|
||||
/// Runs all Web benchmarks using the Skwasm rendering backend.
|
||||
Future<void> main() async {
|
||||
await task(() async {
|
||||
return runWebBenchmark((useWasm: true, forceSingleThreadedSkwasm: false));
|
||||
return runWebBenchmark((
|
||||
useWasm: true,
|
||||
forceSingleThreadedSkwasm: false,
|
||||
useDdc: false,
|
||||
withHotReload: false,
|
||||
));
|
||||
});
|
||||
}
|
||||
|
@ -8,6 +8,11 @@ import 'package:flutter_devicelab/tasks/web_benchmarks.dart';
|
||||
/// Runs all Web benchmarks using the Skwasm rendering backend.
|
||||
Future<void> main() async {
|
||||
await task(() async {
|
||||
return runWebBenchmark((useWasm: true, forceSingleThreadedSkwasm: true));
|
||||
return runWebBenchmark((
|
||||
useWasm: true,
|
||||
forceSingleThreadedSkwasm: true,
|
||||
useDdc: false,
|
||||
withHotReload: false,
|
||||
));
|
||||
});
|
||||
}
|
||||
|
@ -20,7 +20,8 @@ import '../framework/utils.dart';
|
||||
const int benchmarkServerPort = 9999;
|
||||
const int chromeDebugPort = 10000;
|
||||
|
||||
typedef WebBenchmarkOptions = ({bool useWasm, bool forceSingleThreadedSkwasm});
|
||||
typedef WebBenchmarkOptions =
|
||||
({bool useWasm, bool forceSingleThreadedSkwasm, bool useDdc, bool withHotReload});
|
||||
|
||||
Future<TaskResult> runWebBenchmark(WebBenchmarkOptions benchmarkOptions) async {
|
||||
// Reduce logging level. Otherwise, package:webkit_inspection_protocol is way too spammy.
|
||||
@ -40,7 +41,9 @@ Future<TaskResult> runWebBenchmark(WebBenchmarkOptions benchmarkOptions) async {
|
||||
'--no-tree-shake-icons', // local engine builds are frequently out of sync with the Dart Kernel version
|
||||
if (benchmarkOptions.useWasm) ...<String>['--wasm', '--no-strip-wasm'],
|
||||
'--dart-define=FLUTTER_WEB_ENABLE_PROFILING=true',
|
||||
'--profile',
|
||||
if (benchmarkOptions.useDdc) '--debug' else '--profile',
|
||||
if (benchmarkOptions.useDdc && benchmarkOptions.withHotReload)
|
||||
'--extra-front-end-options=--dartdevc-canary,--dartdevc-module-format=ddc',
|
||||
'--no-web-resources-cdn',
|
||||
'-t',
|
||||
'lib/web_benchmarks.dart',
|
||||
|
Loading…
Reference in New Issue
Block a user