-
Notifications
You must be signed in to change notification settings - Fork 6k
[Impeller] re-enable AHB swapchain. #53978
[Impeller] re-enable AHB swapchain. #53978
Conversation
|
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. |
|
This is primarily tested via eyeballing and looking at performance benchmarks. We can't really unit test the timing/fence synchronization. |
| #include "impeller/renderer/backend/vulkan/swapchain/surface_vk.h" | ||
| #include "impeller/toolkit/android/surface_transaction.h" | ||
| #include "impeller/toolkit/android/surface_transaction_stats.h" | ||
| #include "vulkan/vulkan_enums.hpp" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bad include? impeller/renderer/backend/vulkan/vk.h should be the right include.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
...now
|
Unfortunately I found that this does not currently work with hybrid composition, we fail to construct the SurfaceControl |
|
The only failure mode I am aware of is ASurfaceControl_createFromWindow. Do we not have a window? If not, we can create a control and add it to an existing control reference. |
|
We have the Surface/window obtained from the Image reader but ASurfaceControl_createFromWindow is returning nullptr. I'm looking into reparenting for hc++ but that will require API 34 to get the correct behavior for the platform views themselves |
|
The failure case here is that the SurfaceControl object is invalid (because the parenting failed). This is easy to detect and we can fall back to the khr swapchain. |
|
auto label is removed for flutter/engine/53978, due to - The status or check suite Linux linux_host_engine has failed. Please fix the issues identified (or deflake) before re-applying this label. |
flutter/engine@6312dfc...5810b3f 2024-07-19 chris@bracken.jp Move !is_android to build_engine_artifacts declaration (flutter/engine#54006) 2024-07-19 zanderso@users.noreply.github.com [et] Plumb -j to ninja (flutter/engine#54005) 2024-07-19 jonahwilliams@google.com [Impeller] re-enable AHB swapchain. (flutter/engine#53978) 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 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
…2054) flutter/engine@6312dfc...5810b3f 2024-07-19 chris@bracken.jp Move !is_android to build_engine_artifacts declaration (flutter/engine#54006) 2024-07-19 zanderso@users.noreply.github.com [et] Plumb -j to ninja (flutter/engine#54005) 2024-07-19 jonahwilliams@google.com [Impeller] re-enable AHB swapchain. (flutter/engine#53978) 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 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
…2054) flutter/engine@6312dfc...5810b3f 2024-07-19 chris@bracken.jp Move !is_android to build_engine_artifacts declaration (flutter/engine#54006) 2024-07-19 zanderso@users.noreply.github.com [et] Plumb -j to ninja (flutter/engine#54005) 2024-07-19 jonahwilliams@google.com [Impeller] re-enable AHB swapchain. (flutter/engine#53978) 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 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
Fixes flutter/flutter#148139
Block on the CPU rather than immediately beginning encoding. Seems to fix the synchronization issues that we knew about. We need to find a way to use AHB swapchains, as it seems like correct synchronization via either SurfaceView or a SurfaceControl hierarchy will require exposing our rendering as a SurfaceTransaction.