-
Notifications
You must be signed in to change notification settings - Fork 6k
[Impeller] sorted commonly used default pipelines first #52231
Conversation
It looks like this pull request may not have tests. Please make sure to add tests before merging. If you need an exemption to this rule, contact "@test-exemption-reviewer" in the #hackers channel in Chat (don't just cc them here, they won't see it! Use Discord!). If you are not sure if you need tests, consider this rule of thumb: the purpose of a test is to make sure someone doesn't accidentally revert the fix. Ask yourself, is there anything in your PR that you feel it is important we not accidentally revert back to how it was before your fix? Reviewers: Read the Tree Hygiene page and make sure this patch meets those guidelines before LGTMing. |
I think we can do more to fix the linked issue. This was just an easy tweak in the meantime while we look into more invasive solutions. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, good idea!
Its hard to gauge if this just kicks the can down the road and blocks on the first frame instead. Also, and though I have no qualms about landing this as-is, I bet this is hard to tune and harder still to test. How about about giving these the compilation jobs to the job scheduler that maintains a std::priority_queue of procs ordered by the last time they were requested and pops from that queue to the concurrent task runner. The get of the future (if no already fulfilled) can bump the place of the proc in the priority queue. That way, the jobs that are most eagerly needed will skip to the front of the job queue automatically. |
I don't know if I would invest that much effort in this kind of change. We may need to completely rethink how we bootstrap pipelines to be fast on Vulkan |
Yeah, and the 2s was on old devices too and only on first launch. If this is the end of the line on investigating perf wins in this area, then great. If we keep spending time tinkering on this order, perhaps our time is better spent bringing down the counts, etc.. |
I think its still like 500ms on a Pixel 4/5 :( |
Yea, I think we can do more. I'm actively looking into it. This is just an easy tweak that relies on the worker queue being fifo. |
…147017) flutter/engine@13a6ce4...61bf47d 2024-04-18 [email protected] Roll Dart SDK from 8d834bbb2163 to 62b85ea79bce (1 revision) (flutter/engine#52236) 2024-04-18 [email protected] Roll Skia from 1af1e478ef85 to edece87ce734 (5 revisions) (flutter/engine#52233) 2024-04-18 [email protected] Suppress in-actionable warnings in the iOS profiler. (flutter/engine#52227) 2024-04-18 [email protected] [Impeller] sorted commonly used default pipelines first (flutter/engine#52231) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-engine-flutter-autoroll Please CC [email protected],[email protected],[email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
…lutter#147017) flutter/engine@13a6ce4...61bf47d 2024-04-18 [email protected] Roll Dart SDK from 8d834bbb2163 to 62b85ea79bce (1 revision) (flutter/engine#52236) 2024-04-18 [email protected] Roll Skia from 1af1e478ef85 to edece87ce734 (5 revisions) (flutter/engine#52233) 2024-04-18 [email protected] Suppress in-actionable warnings in the iOS profiler. (flutter/engine#52227) 2024-04-18 [email protected] [Impeller] sorted commonly used default pipelines first (flutter/engine#52231) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-engine-flutter-autoroll Please CC [email protected],[email protected],[email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
A minor optimization that places default pipelines that are synchronized upon in the
InitializeCommonlyUsedShadersIfNeeded
first in the queue to be created.issue: flutter/flutter#145843
sequence diagram of the synchronization:

Pre-launch Checklist
///
).If you need help, consider asking for advice on the #hackers-new channel on Discord.