-
Notifications
You must be signed in to change notification settings - Fork 26.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Impeller] TextField widget, long text causes severe frame drop. #126562
Comments
This comment was marked as duplicate.
This comment was marked as duplicate.
@xiaohucode |
|
Thanks for the details @xiaohucode Is it possible to verify if the same occurs without using material 3 ? |
@darshankawar |
Thanks for the update. Verified with and without impeller and seeing the difference as below:
Trace as shared here. stable, master flutter doctor -v
|
For text editing in general we're aware that large amounts of text results in major performance problems. For example #90063. But not sure about the specific correlation with Impeller here. |
I can confirm that the performance is much worse with impeller, but the difference appears to be something happening in layer tree dispatch and not actually in the impeller backend. Still investigating. |
98% of frametime is being spent in flutter::DIRTree::searchAndConsolidateRects (https://github.com/flutter/engine/blob/a0ea4d2d9ea5bc0951acf0ea9b4dcaa808a92708/display_list/geometry/dl_rtree.h#L116). FYI @flar |
I can confirm locally that disabling the Rtree computation causes the performance to return to reasonable levels. From a cursory reading of the code, it seems like we might have quadradic behavior if none of the rectangles intersect. At a certain number of existing rects, we should probably fall back to a less precise but faster strategy if possible. |
Fixed via flutter/engine#42399 |
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of |
Is there an existing issue for this?
Steps to reproduce
TextField widget, long text causes severe frame drop.
Expected results
There is no such issue on versions 3.9.0-10.0.pre
Actual results
Scroll, drop frame
Code sample
Code sample
Screenshots or Video
Screenshots / Video demonstration
[Upload media here]
Logs
Logs
[Paste your logs here]
Flutter Doctor output
Doctor output
The text was updated successfully, but these errors were encountered: