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

Conversation

@jonahwilliams
Copy link
Contributor

Fixes flutter/flutter#158275

We are now counting on the content context to keep the host buffer alive. the imgui overlay does not use a content context, so it has to manage the lifetime of the host buffer correctly, keeping it alive for as many frames as needed and destroying it in the correct order (before context destruction).

Copy link
Member

@gaaclarke gaaclarke left a comment

Choose a reason for hiding this comment

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

Code looks good and the fix is reasonable. I would like us to have an automated test for this. Can we just run a playgrounds test for N frames on CI?

@flar
Copy link
Contributor

flar commented Nov 6, 2024

+1 to trying to make an automated test

@gaaclarke
Copy link
Member

I remember chinmay at some point implemented a flag for impeller_unittest that would run for N milliseconds. I thought we wired that up to be run on ci, but I guess not.

@flar
Copy link
Contributor

flar commented Nov 6, 2024

Although, arguably, this issue doesn't affect the production code and it doesn't affect CI because we don't run playground in CI, so for the same reason that this PR was ignored by the "there shalt be tests!" bot, I don't think it's a big issue to have a test for this.

@gaaclarke
Copy link
Member

I mean as long as we use interactive playground tests we should try to make sure they don't break since it costs developer time when they do break. If we don't want to try to assert they stay functional we should just delete them and rely on impeller_golden_tests.

@jonahwilliams
Copy link
Contributor Author

Expanded the interactive playground test suite to cover GLES and Metal.

Copy link
Member

@gaaclarke gaaclarke left a comment

Choose a reason for hiding this comment

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

awesome, thanks jonah

@flar
Copy link
Contributor

flar commented Nov 6, 2024

+1 to the thanks!

@jonahwilliams
Copy link
Contributor Author

The failure in 1DThreadgroupSizingIsCorrect looks real, investigating...

@jonahwilliams jonahwilliams added the autosubmit Merge PR when tree becomes green via auto submit App label Nov 6, 2024
@auto-submit auto-submit bot merged commit 94dac95 into flutter:main Nov 6, 2024
30 checks passed
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Nov 6, 2024
auto-submit bot pushed a commit to flutter/flutter that referenced this pull request Nov 7, 2024
…158297)

flutter/engine@b36ca33...94dac95

2024-11-06 jonahwilliams@google.com [Impeller] keep imgui hostbuffer alive. (flutter/engine#56409)

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 jsimmons@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
nick9822 pushed a commit to nick9822/flutter that referenced this pull request Dec 18, 2024
Fixes flutter#158275

We are now counting on the content context to keep the host buffer alive. the imgui overlay does not use a content context, so it has to manage the lifetime of the host buffer correctly, keeping it alive for as many frames as needed and destroying it in the correct order (before context destruction).
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

None yet

Development

Successfully merging this pull request may close these issues.

[Impeller] OpenGLES memory corruption in device buffers (and views)

3 participants