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

Conversation

@jonahwilliams
Copy link
Contributor

@jonahwilliams jonahwilliams commented Jan 20, 2024

Part of the work for: flutter/flutter#140804

Removes ComputeCommand and has both ComputePassMTL and ComputePassVK immediately record to their respective comand buffers. This combines the commits for Metal/Vulkan as they are both fairly small. After this, I can add barriers to fix compute for Vulkan.

@jonahwilliams jonahwilliams marked this pull request as ready for review January 22, 2024 20:22
/// There should be no change to rendering if this caching was
/// absent.
///
struct ComputePassBindingsCache {
Copy link
Member

Choose a reason for hiding this comment

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

ComputePassBindingsCacheMTL. The MTL suffix for non-backend-agnostic classes.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

using TextureMap = std::map<uint64_t, id<MTLTexture>>;
using SamplerMap = std::map<uint64_t, id<MTLSamplerState>>;

id<MTLComputeCommandEncoder> encoder_;
Copy link
Member

Choose a reason for hiding this comment

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

= nil (or nullptr like the rest) this out. IIRC, ObjC ivars aren't zero initialized in C++.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

auto width = grid_size.width;
auto height = grid_size.height;

auto maxTotalThreadsPerThreadgroup = static_cast<int64_t>(
Copy link
Member

Choose a reason for hiding this comment

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

Here and elsewhere, the use underscore_case for vars instead of camelCase.

Copy link
Member

Choose a reason for hiding this comment

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

Oh, I see this was just code that was moved. Just the same, a drive-by change to make this conform the style would be good.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

@jonahwilliams jonahwilliams added the autosubmit Merge PR when tree becomes green via auto submit App label Jan 22, 2024
@auto-submit auto-submit bot merged commit df6b15d into flutter:main Jan 22, 2024
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jan 23, 2024
auto-submit bot pushed a commit to flutter/flutter that referenced this pull request Jan 23, 2024
…142023)

flutter/engine@d3dbd42...df6b15d

2024-01-22 [email protected] [Impeller] dont emulate command buffers for compute on Metal/Vulkan. (flutter/engine#49922)
2024-01-22 [email protected] [Impeller] fixed colorspace for metal screenshots (flutter/engine#49941)
2024-01-22 [email protected] [Impeller] remove frame counter that was unused in Vulkan allocator. (flutter/engine#49913)
2024-01-22 [email protected] [Impeller] Create the golden test screenshotter after setting the Vulkan ICD environment variable (flutter/engine#49948)
2024-01-22 [email protected] [Windows] Rename and move EGL types (flutter/engine#49900)
2024-01-22 [email protected] Roll Skia from fa5f2461554f to 58973cca0edd (2 revisions) (flutter/engine#49947)

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

Projects

No open projects
Status: ✅ Done

Development

Successfully merging this pull request may close these issues.

2 participants