Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Lazily allocate RasterCacheItems only when caching is enabled #45211

Merged
merged 1 commit into from
Aug 31, 2023

Conversation

flar
Copy link
Contributor

@flar flar commented Aug 29, 2023

Fixes flutter/flutter#133377

The default allocation of RasterCacheItems in the layer tree was showing up in profiles of apps running on Impeller which don't actually use the raster cache.

In order to eliminate the overhead of those allocations, RasterCacheItems are now lazily allocated only when the layers encounter an actual raster_cache during the Preroll phase.

@flar flar requested review from dnfield and jonahwilliams August 31, 2023 18:15
Copy link
Contributor

@dnfield dnfield left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thank you!

@flar flar added the autosubmit Merge PR when tree becomes green via auto submit App label Aug 31, 2023
@auto-submit auto-submit bot merged commit df619c6 into flutter:main Aug 31, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Aug 31, 2023
auto-submit bot pushed a commit to flutter/flutter that referenced this pull request Aug 31, 2023
…133810)

flutter/engine@51090e3...ca513c9

2023-08-31 [email protected] Revert "Reland "Build iOS unittest target in unopt builds" (#44356)"" (flutter/engine#45346)
2023-08-31 [email protected] Lazily allocate RasterCacheItems only when caching is enabled (flutter/engine#45211)
2023-08-31 [email protected] Roll Skia from 8ff4fd208c26 to 5d08dadd2ef4 (3 revisions) (flutter/engine#45340)
2023-08-31 [email protected] Reland "Build iOS unittest target in unopt builds" (#44356)" (flutter/engine#44821)
2023-08-31 [email protected] Update comment const_finder.dart (flutter/engine#45180)
2023-08-31 [email protected] Replace an unnecessary util function with PostSync (flutter/engine#45190)
2023-08-31 [email protected] Roll Skia from cda0cfaadfd7 to 8ff4fd208c26 (3 revisions) (flutter/engine#45337)
2023-08-31 [email protected] Roll Dart SDK from 0cea73a8d3c3 to ac3bc9f6351a (4 revisions) (flutter/engine#45336)
2023-08-31 [email protected] [macOS] Link __availability_version_check (flutter/engine#45333)
2023-08-31 [email protected] Roll Skia from 8c05d5103d6b to cda0cfaadfd7 (3 revisions) (flutter/engine#45334)
2023-08-31 [email protected] Adds an --rbe option to tools/gn that works on Linux hosts (flutter/engine#45271)
2023-08-31 [email protected] Migrate VK calls of GrBackend* (flutter/engine#45325)
2023-08-31 [email protected] Roll buildroot (flutter/engine#45329)
2023-08-31 [email protected] Revert dl split (flutter/engine#45326)
2023-08-31 [email protected] Roll Skia from d113402de2ce to 8c05d5103d6b (4 revisions) (flutter/engine#45331)

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://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
zanderso added a commit to zanderso/engine that referenced this pull request Sep 12, 2023
zanderso added a commit that referenced this pull request Sep 12, 2023
auto-submit bot pushed a commit that referenced this pull request Sep 12, 2023
zanderso added a commit to zanderso/engine that referenced this pull request Sep 12, 2023
zanderso added a commit to zanderso/engine that referenced this pull request Sep 13, 2023
itsjustkevin pushed a commit that referenced this pull request Sep 13, 2023
XilaiZhang pushed a commit to XilaiZhang/engine that referenced this pull request Sep 13, 2023
XilaiZhang added a commit that referenced this pull request Sep 13, 2023
…abled… (#45756)

…… (#45747)

…" (#45734)

Reverts #45211

b/298583505

preemptively cp the revert to the next roll i am looking at. I do see
the recipe branch show up on
https://flutter-review.googlesource.com/admin/repos/recipes,branches/q/filter:flutter-3.15
, I will assume the recipe branch is created for now. We will see the
post submit results. If it doesn't work I will create the recipe branch
manually.

Co-authored-by: Zachary Anderson <[email protected]>
XilaiZhang pushed a commit to XilaiZhang/engine that referenced this pull request Sep 14, 2023
XilaiZhang added a commit that referenced this pull request Sep 14, 2023
…caching is enabled… (#45811)

…" (#45734)

Reverts #45211

b/298583505

Co-authored-by: Zachary Anderson <[email protected]>
XilaiZhang pushed a commit to XilaiZhang/engine that referenced this pull request Sep 16, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
autosubmit Merge PR when tree becomes green via auto submit App
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Flow unconditionally does raster-cache related work for CacheableContainerLayer, which is wasted if the raster cache is disabled.
2 participants