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

Conversation

@gaaclarke
Copy link
Member

fixes flutter/flutter#146452

Pre-launch Checklist

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I read the Tree Hygiene wiki page, which explains my responsibilities.
  • I read and followed the Flutter Style Guide and the C++, Objective-C, Java style guides.
  • I listed at least one issue that this PR fixes in the description above.
  • I added new tests to check the change I am making or feature I am adding, or the PR is test-exempt. See testing the engine for instructions on writing and running engine tests.
  • I updated/added relevant documentation (doc comments with ///).
  • I signed the CLA.
  • All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-new channel on Discord.

@flutter-dashboard
Copy link

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.

/// match the output slots of the vertex shaders.
/// It's not used at runtime.
template <typename VertexShaderT, typename FragmentShaderT>
class ShaderBindingComparator {
Copy link
Member Author

Choose a reason for hiding this comment

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

This is a class because it's required for partial specialization. Also I wish we got better feedback when this failed, but I couldn't figure out how to get multiple static asserts happening in the loop, that's why it returns bool.

struct ClipVertexShader;

template <typename FragmentShaderT>
class ShaderBindingComparator<CheckerboardVertexShader, FragmentShaderT> {
Copy link
Member

Choose a reason for hiding this comment

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

Another idea for if you don't want to update the code gen template, you could have a third template size_t argument that is the count of the array elements and have a specialization for zero that is true.

Copy link
Member

@chinmaygarde chinmaygarde left a comment

Choose a reason for hiding this comment

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

LGTM with nits. I'd rather we patch the codegen template so the checkerboard and clip shaders aren't specialized here.

@chinmaygarde
Copy link
Member

This is awesome. Moving more stuff to be compile time verified.

@gaaclarke gaaclarke merged commit 818191d into flutter:main Apr 17, 2024
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Apr 17, 2024
auto-submit bot pushed a commit to flutter/flutter that referenced this pull request Apr 17, 2024
…146898)

flutter/engine@25b09e8...818191d

2024-04-17 [email protected] [Impeller] added static check that fragment shader and vertex shaders slots match (flutter/engine#52174)
2024-04-17 [email protected] [macOS] FlutterSurfaceManager should not return surfaces that are in use (flutter/engine#52082)
2024-04-17 [email protected] [macOS] FlutterView should not override platform view cursor (flutter/engine#52159)

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
gilnobrega pushed a commit to gilnobrega/flutter that referenced this pull request Apr 22, 2024
…lutter#146898)

flutter/engine@25b09e8...818191d

2024-04-17 [email protected] [Impeller] added static check that fragment shader and vertex shaders slots match (flutter/engine#52174)
2024-04-17 [email protected] [macOS] FlutterSurfaceManager should not return surfaces that are in use (flutter/engine#52082)
2024-04-17 [email protected] [macOS] FlutterView should not override platform view cursor (flutter/engine#52159)

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
@As90909w

This comment was marked as spam.

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Impeller] Statically assert that the pipeline stages have compatible interfaces.

3 participants