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

[Impeller] Exploit dynamic state in OpenGL for fewer program links. #53764

Merged
merged 6 commits into from
Jul 8, 2024

Conversation

chinmaygarde
Copy link
Member

@flutter-dashboard

This comment was marked as outdated.

@chinmaygarde
Copy link
Member Author

No change in functionality. Reduces the compilation and link load at runtime.

@chinmaygarde chinmaygarde self-assigned this Jul 8, 2024
@jonahwilliams
Copy link
Member

Can we test this in someway? For example, ask for a pipeline - then ask for a variant. Assert they have the same backing program?

@chinmaygarde
Copy link
Member Author

chinmaygarde commented Jul 8, 2024

Yup. Added a test. There are goldens that should cover this and an earlier version of this patch did break advanced blends because I forgot about spec. constants. But having a non-golden test that checks for program equality makes sense and I've added that.

// The program handles should be live and equal.
ASSERT_FALSE(pipeline_gles.GetProgramHandle().IsDead());
ASSERT_FALSE(new_pipeline_gles.GetProgramHandle().IsDead());
ASSERT_EQ(pipeline_gles.GetProgramHandle().name.value(),
Copy link
Member

Choose a reason for hiding this comment

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

Note for readers: the name is actually a unique ID, so its not like an arbitrary string or something like that.

Copy link
Member

@jonahwilliams jonahwilliams left a comment

Choose a reason for hiding this comment

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

LGTM

@chinmaygarde
Copy link
Member Author

Added a test that asserts that changing a spec. constant creates a new program object.

@chinmaygarde chinmaygarde added the autosubmit Merge PR when tree becomes green via auto submit App label Jul 8, 2024
Copy link
Member

@bdero bdero left a comment

Choose a reason for hiding this comment

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

Nice one, LGTM

Copy link
Contributor

auto-submit bot commented Jul 8, 2024

auto label is removed for flutter/engine/53764, due to - The status or check suite Mac mac_clang_tidy has failed. Please fix the issues identified (or deflake) before re-applying this label.

@auto-submit auto-submit bot removed the autosubmit Merge PR when tree becomes green via auto submit App label Jul 8, 2024
@chinmaygarde chinmaygarde added the autosubmit Merge PR when tree becomes green via auto submit App label Jul 8, 2024
@auto-submit auto-submit bot merged commit a3ba6c9 into flutter:main Jul 8, 2024
31 checks passed
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jul 9, 2024
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jul 9, 2024
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jul 9, 2024
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jul 9, 2024
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jul 9, 2024
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jul 9, 2024
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jul 9, 2024
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jul 9, 2024
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jul 9, 2024
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jul 9, 2024
@chinmaygarde chinmaygarde deleted the fewerlinks branch July 9, 2024 18:31
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jul 9, 2024
auto-submit bot pushed a commit to flutter/flutter that referenced this pull request Jul 9, 2024
…151482)

flutter/engine@69075e7...4a2ac0e

2024-07-09 bdero@google.com Revert 4 Dart rolls (726cb2467 -> ffc8bb004) to recover engine roll (flutter/engine#53778)
2024-07-09 skia-flutter-autoroll@skia.org Roll Dart SDK from 33b65d2fe034 to 726cb2467f27 (1 revision) (flutter/engine#53776)
2024-07-09 skia-flutter-autoroll@skia.org Roll Skia from 9a6f8dfb9102 to 46e5bf98158a (1 revision) (flutter/engine#53775)
2024-07-09 49699333+dependabot[bot]@users.noreply.github.com Bump actions/upload-artifact from 4.3.3 to 4.3.4 (flutter/engine#53774)
2024-07-09 skia-flutter-autoroll@skia.org Roll Skia from ced941fdddc4 to 9a6f8dfb9102 (1 revision) (flutter/engine#53773)
2024-07-09 skia-flutter-autoroll@skia.org Roll Dart SDK from 0ecada960645 to 33b65d2fe034 (2 revisions) (flutter/engine#53772)
2024-07-09 skia-flutter-autoroll@skia.org Roll Skia from 9edafde22cb3 to ced941fdddc4 (2 revisions) (flutter/engine#53769)
2024-07-08 skia-flutter-autoroll@skia.org Roll Dart SDK from 1679aba20a03 to 0ecada960645 (1 revision) (flutter/engine#53767)
2024-07-08 dustingreen@google.com [fuchsia][sysmem2] move to sysmem2 protocols (flutter/engine#53138)
2024-07-08 chinmaygarde@google.com [Impeller] Exploit dynamic state in OpenGL for fewer program links. (flutter/engine#53764)
2024-07-08 skia-flutter-autoroll@skia.org Roll Fuchsia Linux SDK from Em1nantnFXXK8xJH9... to yYs6rINJxWJ8J2vxo... (flutter/engine#53763)
2024-07-08 jonahwilliams@google.com [Impeller] fix incorrect padding/translation in drawVertices with texture coordinates. (flutter/engine#53746)
2024-07-08 skia-flutter-autoroll@skia.org Roll Skia from c65710d00047 to 9edafde22cb3 (3 revisions) (flutter/engine#53762)
2024-07-08 jonahwilliams@google.com [Impeller] implement clear color opt for experimental canvas. (flutter/engine#53749)
2024-07-08 jonahwilliams@google.com [Impeller] add experimental canvas support to screenshotter. (flutter/engine#53751)
2024-07-08 chinmaygarde@google.com Add a host_debug_unopt local engine config for Windows. (flutter/engine#53734)
2024-07-08 skia-flutter-autoroll@skia.org Roll Dart SDK from ffc8bb004a64 to 1679aba20a03 (16 revisions) (flutter/engine#53761)
2024-07-08 skia-flutter-autoroll@skia.org Roll Skia from 38b17b22312d to c65710d00047 (2 revisions) (flutter/engine#53758)
2024-07-08 skia-flutter-autoroll@skia.org Roll Skia from b2c51b2fe15f to 38b17b22312d (1 revision) (flutter/engine#53757)
2024-07-08 skia-flutter-autoroll@skia.org Roll Skia from 1f85fb9238aa to b2c51b2fe15f (3 revisions) (flutter/engine#53756)
2024-07-08 skia-flutter-autoroll@skia.org Roll Skia from f1d06de0ae87 to 1f85fb9238aa (2 revisions) (flutter/engine#53753)

Also rolling transitive DEPS:
  fuchsia/sdk/core/linux-amd64 from Em1nantnFXXK to yYs6rINJxWJ8

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 bdero@google.com,rmistry@google.com,zra@google.com 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
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 e: impeller e: opengl
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Impeller] GLES pipeline libraries must ignore all descriptor fields except the shader stages.
3 participants