Heavy Widget construction and destruction performance test (#60336)
* Add widget construction benchmark * Add to device lab
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
// 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 'dart:async';
|
||||
|
||||
import 'package:flutter_devicelab/tasks/perf_tests.dart';
|
||||
import 'package:flutter_devicelab/framework/adb.dart';
|
||||
import 'package:flutter_devicelab/framework/framework.dart';
|
||||
|
||||
Future<void> main() async {
|
||||
deviceOperatingSystem = DeviceOperatingSystem.android;
|
||||
await task(createsMultiWidgetConstructPerfTest());
|
||||
}
|
||||
@@ -242,6 +242,14 @@ TaskFunction createImageFilteredTransformAnimationPerfTest() {
|
||||
).run;
|
||||
}
|
||||
|
||||
TaskFunction createsMultiWidgetConstructPerfTest() {
|
||||
return PerfTest(
|
||||
'${flutterDirectory.path}/dev/benchmarks/macrobenchmarks',
|
||||
'test_driver/multi_widget_construction_perf.dart',
|
||||
'multi_widget_construction_perf',
|
||||
).run;
|
||||
}
|
||||
|
||||
/// Measure application startup performance.
|
||||
class StartupTest {
|
||||
const StartupTest(this.testDirectory, { this.reportMetrics = true });
|
||||
|
||||
@@ -156,6 +156,12 @@ tasks:
|
||||
stage: devicelab
|
||||
required_agent_capabilities: ["mac/android"]
|
||||
|
||||
multi_widget_construction_perf__timeline_summary:
|
||||
description: >
|
||||
Measures the runtime performance of constructing and destructing widgets on Android.
|
||||
stage: devicelab
|
||||
required_agent_capabilities: ["linux/android"]
|
||||
|
||||
picture_cache_perf__timeline_summary:
|
||||
description: >
|
||||
Measures the runtime performance of raster caching many pictures on Android.
|
||||
|
||||
Reference in New Issue
Block a user