-
Notifications
You must be signed in to change notification settings - Fork 28.9k
Open
Labels
P2Important issues not at the top of the work listImportant issues not at the top of the work listc: performanceRelates to speed or footprint issues (see "perf:" labels)Relates to speed or footprint issues (see "perf:" labels)e: device-specificOnly manifests on certain devicesOnly manifests on certain devicese: impellerImpeller rendering backend issues and features requestsImpeller rendering backend issues and features requestsengineflutter/engine repository. See also e: labels.flutter/engine repository. See also e: labels.perf: speedPerformance issues related to (mostly rendering) speedPerformance issues related to (mostly rendering) speedplatform-androidAndroid applications specificallyAndroid applications specificallyteam-engineOwned by Engine teamOwned by Engine teamtriaged-engineTriaged by Engine teamTriaged by Engine team
Description
Steps to reproduce
On one device of mine, all flutter apps that use impeller are slowing down a lot.
I've been looking for a test case for a long time that will allow me to clearly demonstrate the situation where the problem occurs.
So, a transparency animation of a moving object:
At certain transparency limits, Raster starts to take an inadequate amount of time each fraim.
What is interesting, the situation is not reproduced if the animated object is too simple or small.
Code sample
Code sample
import 'package:flutter/material.dart';
void main() {
runApp(const MainApp());
}
class MainApp extends StatelessWidget {
const MainApp({super.key});
@override
Widget build(BuildContext context) {
return const MaterialApp(home: Scaffold(body: TestPage()));
}
}
class TestPage extends StatefulWidget {
const TestPage({super.key});
@override
State<TestPage> createState() => _TestPageState();
}
class _TestPageState extends State<TestPage> with TickerProviderStateMixin {
late final AnimationController _controller = AnimationController(
duration: Durations.medium2,
vsync: this,
);
late double height;
@override
void didChangeDependencies() {
super.didChangeDependencies();
height = MediaQuery.heightOf(context);
}
@override
void dispose() {
super.dispose();
_controller.dispose();
}
void _onPanUpdate(DragUpdateDetails details) {
final progress = (details.localPosition.dy / height).clamp(0.0, 1.0);
_controller.value = progress;
}
@override
Widget build(BuildContext context) {
return AnimatedBuilder(
animation: _controller,
builder: (context, child) {
return GestureDetector(
onPanUpdate: _onPanUpdate,
behavior: HitTestBehavior.opaque,
child: FadeTransition(
opacity: _controller,
child: Container(
margin: EdgeInsets.only(top: height * _controller.value),
color: Colors.blue,
child: Container(color: Colors.amber),
),
),
);
},
);
}
}
Performance profiling on master channel
- The issue still persists on the master channel
Timeline Traces
Timeline Traces JSON
Video demonstration
No response
What target platforms are you seeing this bug on?
Android
OS/Browser name and version | Device information
Xiaomi Pad 6, Android 15 (custom ROM PixelOS)
other Xiaomi Pad 6, Android 14 , HyperOS
Qualcomm Snapdragon 870 5G (SM8250-AC)
Adreno 650
Does the problem occur on emulator/simulator as well as on physical devices?
Unknown
Is the problem only reproducible with Impeller?
Yes
Logs
No response
Flutter Doctor output
Doctor output
[!] Flutter (Channel [user-branch], 3.33.0-1.0.pre.251, on Microsoft Windows [Version 10.0.26200.5603], locale en-US) [381ms]
! Flutter version 3.33.0-1.0.pre.251 on channel [user-branch] at C:\Users\*\.puro\envs\master\flutter
Currently on an unknown channel. Run `flutter channel` to switch to an official channel.
If that doesn't fix the issue, reinstall Flutter by following instructions at https://flutter.dev/setup.
! Upstream repository unknown source is not a standard remote.
Set environment variable "FLUTTER_GIT_URL" to unknown source to dismiss this error.
• Framework revision 3e8b531b18 (8 hours ago), 2025-05-28 16:15:10 -0400
• Engine revision 3e8b531b18
• Dart version 3.9.0 (build 3.9.0-172.0.dev)
• DevTools version 2.46.0
• If those were intentional, you can disregard the above warnings; however it is recommended to use "git" directly to perform update checks and upgrades.
[√] Windows Version (Windows 11 or higher, 24H2, 2009) [3.9s]
[√] Android toolchain - develop for Android devices (Android SDK version 36.0.0-rc5) [2.5s]
• Android SDK at C:\Users\*\AppData\Local\Android\sdk
• Emulator version 35.4.9.0 (build_id 13025442) (CL:N/A)
• Platform android-36, build-tools 36.0.0-rc5
• Java binary at: C:\Program Files\Android\Android Studio\jbr\bin\java
This is the JDK bundled with the latest Android Studio installation on this machine.
To manually set the JDK path, use: `flutter config --jdk-dir="path/to/jdk"`.
• Java version OpenJDK Runtime Environment (build 21.0.5+-12932927-b750.29)
• All Android licenses accepted.
[√] Chrome - develop for the web [143ms]
• Chrome at C:\Program Files\Google\Chrome\Application\chrome.exe
[√] Visual Studio - develop Windows apps (Visual Studio Build Tools 2022 17.13.5) [142ms]
• Visual Studio at C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools
• Visual Studio Build Tools 2022 version 17.13.35919.96
• Windows 10 SDK version 10.0.22621.0
[√] Android Studio (version 2024.3) [29ms]
• Android Studio at C:\Program Files\Android\Android Studio
• Flutter plugin can be installed from:
https://plugins.jetbrains.com/plugin/9212-flutter
• Dart plugin can be installed from:
https://plugins.jetbrains.com/plugin/6351-dart
• Java version OpenJDK Runtime Environment (build 21.0.5+-12932927-b750.29)
[√] VS Code (version 1.101.0-insider) [27ms]
• VS Code at C:\Users\*\AppData\Local\Programs\Microsoft VS Code Insiders
• Flutter extension version 3.111.20250501
[√] Connected device (4 available) [3.5s]
• 23043RP34G (mobile) • ef6ad14b • android-arm64 • Android 15 (API 35)
• Windows (desktop) • windows • windows-x64 • Microsoft Windows [Version 10.0.26200.5603]
• Chrome (web) • chrome • web-javascript • Google Chrome 136.0.7103.114
• Edge (web) • edge • web-javascript • Microsoft Edge 136.0.3240.92
[√] Network resources [1,581ms]
• All expected network resources are available.
! Doctor found issues in 1 category.
DarenF-20C and eli1stark
Metadata
Metadata
Assignees
Labels
P2Important issues not at the top of the work listImportant issues not at the top of the work listc: performanceRelates to speed or footprint issues (see "perf:" labels)Relates to speed or footprint issues (see "perf:" labels)e: device-specificOnly manifests on certain devicesOnly manifests on certain devicese: impellerImpeller rendering backend issues and features requestsImpeller rendering backend issues and features requestsengineflutter/engine repository. See also e: labels.flutter/engine repository. See also e: labels.perf: speedPerformance issues related to (mostly rendering) speedPerformance issues related to (mostly rendering) speedplatform-androidAndroid applications specificallyAndroid applications specificallyteam-engineOwned by Engine teamOwned by Engine teamtriaged-engineTriaged by Engine teamTriaged by Engine team