Skip to content

Consider adding Performance overlay to platform-web #52258

Open

Description

@filiph

Note: I'm not sure how this would work or how much work this entails. But it came up as a topic from conversations with @liyuqian, and we noticed there is no bug tracking it.

Use case

  • Performance optimization: Running a Flutter app on the web and seeing some skipped frames, I'd like to reuse my knowledge of Flutter performance tools to start addressing the issue.
  • Education: Writing docs about performance, I'd like to give the users two version of an app in DartPad. Users are able to bring up the performance overlay to see how one version of the app is performing much faster than the other one.

Proposal

  • Enable the performance overlay for Flutter web apps.

For clarity, this is what I mean by performance overlay.

performance-overlay-green-bb41b466cf6bcd529b285e1510b638086fc5afb8921b8ac5a6565dee5bc44788

It is an engine layer added to a --profile (or --debug) version of an app by the engine. It shows the build times for the UI thread (a.k.a. main thread, app thread, etc.) and the GPU thread (a.k.a. raster thread -- i.e. not actually running on the GPU).

Activity

  1. added this to the milestone on Mar 10, 2020
  2. added
    P1High-priority issues at the top of the work list
    on May 29, 2020
  3. added
    P2Important issues not at the top of the work list
    and removed
    P1High-priority issues at the top of the work list
    on Jun 16, 2020
  4. added
    frameworkflutter/packages/flutter repository. See also f: labels.
    c: proposalA detailed proposal for a change to Flutter
    c: new featureNothing broken; request for a new capability
    on Jul 6, 2020
  5. modified the milestone: on Jul 7, 2020
  6. removed this from the milestone on Jul 22, 2020
  7. removed this from the milestone on Aug 17, 2020
  8. goncalo-palma-3r commented on Sep 14, 2020

    @goncalo-palma-3r

    Thumbed up, we desperately need that 🙏

  9. OldMetalmind commented on Sep 14, 2020

    @OldMetalmind

    Working on flutter web. This would help!

  10. abid-shaon-3r commented on Sep 14, 2020

    @abid-shaon-3r

    This would be very helpful for as

  11. ghunkins commented on Mar 24, 2021

    @ghunkins

    Performance for Flutter web is very needed.

  12. ted-marozzi commented on Sep 27, 2021

    @ted-marozzi

    This would be very useful

  13. creativecreatorormaybenot commented on Sep 27, 2021

    @creativecreatorormaybenot
    Contributor

    Note that you can easily build your own performance overlay on web using the FrameTiming API.

    An example of what that looks like can be seen here. You can see the performance overlay in the top right:

    image

    If there is interest in such thing, I could create a similar overlay as a package.

  14. ted-marozzi commented on Sep 27, 2021

    @ted-marozzi

    Note that you can easily build your own performance overlay on web using the FrameTiming API.

    An example of what that looks like can be seen here. You can see the performance overlay in the top right:

    image

    If there is interest in such thing, I could create a similar overlay as a package.

    Hey I would definitely be interested in this. Could you share some of the code in the demo that lead to that overlay in the mean time? Looking into the frame timing api. Very interesting. Seems like it wouldn't be too much work to integrate it into the actual flutter sdk though!

  15. creativecreatorormaybenot commented on Oct 30, 2021

    @creativecreatorormaybenot
    Contributor

    I published the custom performance overlay for web as a package 🎉

    https://pub.dev/packages/performance

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work listc: new featureNothing broken; request for a new capabilityc: proposalA detailed proposal for a change to Flutterframeworkflutter/packages/flutter repository. See also f: labels.platform-webWeb applications specificallyteam-webOwned by Web platform teamtriaged-webTriaged by Web platform team

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions