Skip to content
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] Adjust advanced blend construction to avoid moto g4 crash. #47637

Closed

Conversation

jonahwilliams
Copy link
Member

Re-arrange how the advanced blend shaders are constructed to simplify the shader slightly, avoid moto g4 driver crash.

Fixes flutter/flutter#137816

This is tested, but the test is in the framework repo for reasons.

@zanderso
Copy link
Member

zanderso commented Nov 3, 2023

Hmm. I wonder why the test bot isn't complaining. Maybe it doesn't know about .frag and .glsl files? Would changes to the shaders also be covered by the playground golden tests? Also a little worried that changes to the shaders aren't noticed by the malioc analysis.

zanderso
zanderso previously approved these changes Nov 3, 2023
@jonahwilliams
Copy link
Member Author

This shouldn't trigger malioc because the shader should be identical after some inlining/constant folding.

Yeah, we can ask about the bot

@zanderso zanderso dismissed their stale review November 3, 2023 14:35

The original patch slipped into the 3.17 beta. We should revert it first so it can be CP'd

@jonahwilliams
Copy link
Member Author

I'll just merge this into the reland.

@@ -22,39 +22,51 @@
// kColor,
// kLuminosity,
// Note, this isn't a switch as GLSL ES 1.0 does not support them.
#define AdvancedBlend(blend_type) \
Copy link
Member

Choose a reason for hiding this comment

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

Ah, yeah this shader was totally broken for all backends (impellerc runs the preprocessor), but we just don't use this shader on iOS anymore. GL goldens on CI would have caught this.

auto-submit bot pushed a commit that referenced this pull request Nov 7, 2023
Reland of #47432

Also includes:
  * #47617
  * #47637
  
Fixes the performance on iOS by removing blocking on compilation of shaders. From local testing this has identical before/after numbers. Additional, ensures that we don't unecessarily specialize vertex shaders and notes this restriction in the documentation.

----

Adds support for Specialization constants to Impeller for our usage in the engine. A motivating example has been added in the impeller markdown docs.

Fixes flutter/flutter#136210
Fixes flutter/flutter#119357
auto-submit bot added a commit that referenced this pull request Nov 7, 2023
…47762)

Reverts #47678
Initiated by: jonahwilliams
This change reverts the following previous change:
Original Description:
Reland of #47432

Also includes:
  * #47617
  * #47637
  
Fixes the performance on iOS by removing blocking on compilation of shaders. From local testing this has identical before/after numbers. Additional, ensures that we don't unecessarily specialize vertex shaders and notes this restriction in the documentation.

----

Adds support for Specialization constants to Impeller for our usage in the engine. A motivating example has been added in the impeller markdown docs.

Fixes flutter/flutter#136210
Fixes flutter/flutter#119357
auto-submit bot pushed a commit that referenced this pull request Nov 8, 2023
Reland of #47432

Also includes:

#47617
#47637

Fixes the performance on iOS by removing blocking on compilation of shaders. From local testing this has identical before/after numbers. Additional, ensures that we don't unecessarily specialize vertex shaders and notes this restriction in the documentation.

Adds support for Specialization constants to Impeller for our usage in the engine. A motivating example has been added in the impeller markdown docs.

Fixes flutter/flutter#136210
Fixes flutter/flutter#119357

Investigating: flutter/flutter#138028
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Archived in project
3 participants