Skip to content

Correct PerformanceOverlay optionsMask checks and add tests - #182309

Merged
auto-submit[bot] merged 4 commits into
flutter:masterfrom
Piinks:rebase_abandoned_pr_174814
Feb 20, 2026
Merged

Correct PerformanceOverlay optionsMask checks and add tests#182309
auto-submit[bot] merged 4 commits into
flutter:masterfrom
Piinks:rebase_abandoned_pr_174814

Conversation

@Piinks

Copy link
Copy Markdown
Contributor

This re-stages the changes from #174814
That PR had some outstanding feedback to resolve, this is now done and we can get this change in, with thanks to @jihanurrahman33 !

From the original PR:

Fix bitmask checks in RenderPerformanceOverlay._intrinsicHeight:

Use bitwise AND (&) and compare against 0 instead of bitwise OR (|).
This ensures the intrinsic height is 0 when no options are enabled, 80.0 for one graph,
and 160.0 when both rasterizer and engine graphs are enabled.
Add tests in rendering/performance_overlay_test.dart to verify intrinsic height for
various masks.

Pre-launch Checklist

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

Note: The Flutter team is currently trialing the use of Gemini Code Assist for GitHub. Comments from the gemini-code-assist bot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed.

@PiinksPiinks added the framework flutter/packages/flutter repository. See also f: labels. label Feb 12, 2026

@justinmcjustinmc left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM 👍 . Thanks for reviving that PR!

@gemini-code-assistgemini-code-assistBot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request correctly fixes a bug in the bitmask checks within RenderPerformanceOverlay to accurately calculate its intrinsic height. The addition of tests is a great step towards ensuring correctness. My review includes suggestions to use const for compile-time constant bitmasks, which is a minor performance and style improvement, and to enhance the new tests with more comprehensive cases to ensure all combinations of options are handled correctly.

Comment threadpackages/flutter/lib/src/rendering/performance_overlay.dart Outdated
Comment threadpackages/flutter/lib/src/rendering/performance_overlay.dart Outdated

@dkwingsmtdkwingsmt left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@PiinksPiinks added the autosubmit Merge PR when tree becomes green via auto submit App label Feb 19, 2026
@auto-submit

Copy link
Copy Markdown
Contributor

autosubmit label was removed for flutter/flutter/182309, because The base commit of the PR is older than 7 days and can not be merged. Please merge the latest changes from the main into this branch and resubmit the PR.

@auto-submitauto-submitBot removed the autosubmit Merge PR when tree becomes green via auto submit App label Feb 19, 2026
@Piinks
Piinksforce-pushed the rebase_abandoned_pr_174814 branch from beeb7c8 to 7fd23b9CompareFebruary 19, 2026 23:42
@PiinksPiinks added the autosubmit Merge PR when tree becomes green via auto submit App label Feb 19, 2026
@auto-submit
auto-submitBot added this pull request to the merge queueFeb 20, 2026
@github-merge-queue
github-merge-queueBot removed this pull request from the merge queue due to no response for status checks Feb 20, 2026
@auto-submit
auto-submitBot added this pull request to the merge queueFeb 20, 2026
Merged via the queue into flutter:master with commit f38a3e0Feb 20, 2026
74 checks passed
@flutter-dashboardflutter-dashboardBot removed the autosubmit Merge PR when tree becomes green via auto submit App label Feb 20, 2026
auto-submitBot pushed a commit to flutter/packages that referenced this pull request Feb 23, 2026
flutter/flutter@91b2d41...dad6f9d
2026-02-23 engine-flutter-autoroll@skia.org Roll Packages from 9da22bf to 12b43a1 (19 revisions) (flutter/flutter#182758)
2026-02-23 engine-flutter-autoroll@skia.org Roll Skia from 55fae1660572 to 9a5a3c92c336 (7 revisions) (flutter/flutter#182749)
2026-02-23 engine-flutter-autoroll@skia.org Roll Skia from 256e2b47b303 to 55fae1660572 (1 revision) (flutter/flutter#182741)
2026-02-22 engine-flutter-autoroll@skia.org Roll Skia from 141ed451f007 to 256e2b47b303 (1 revision) (flutter/flutter#182732)
2026-02-22 engine-flutter-autoroll@skia.org Roll Skia from e59de8a12e7e to 141ed451f007 (1 revision) (flutter/flutter#182729)
2026-02-22 engine-flutter-autoroll@skia.org Roll Skia from f6ea7ef42d14 to e59de8a12e7e (1 revision) (flutter/flutter#182726)
2026-02-22 engine-flutter-autoroll@skia.org Roll Skia from 34fa7b2373f3 to f6ea7ef42d14 (1 revision) (flutter/flutter#182721)
2026-02-21 engine-flutter-autoroll@skia.org Roll Skia from 3ca547c8b816 to 34fa7b2373f3 (2 revisions) (flutter/flutter#182711)
2026-02-21 engine-flutter-autoroll@skia.org Roll Skia from c91ad88e89f8 to 3ca547c8b816 (9 revisions) (flutter/flutter#182696)
2026-02-21 victorsanniay@gmail.com Shortcircuit if Tooltip message and richMessage are empty (flutter/flutter#182524)
2026-02-21 50643541+Mairramer@users.noreply.github.com Add fields getter to FormState (flutter/flutter#180815)
2026-02-20 1961493+harryterkelsen@users.noreply.github.com fix(web_ui): use static whitelist for image codec tests (flutter/flutter#182648)
2026-02-20 victorsanniay@gmail.com Add cupertino docimports for CupertinoPageTransitionsBuilder and fix typos (flutter/flutter#182685)
2026-02-20 katelovett@google.com Fix Chat invite link (flutter/flutter#182675)
2026-02-20 engine-flutter-autoroll@skia.org Roll Skia from ce5854495a3a to c91ad88e89f8 (58 revisions) (flutter/flutter#182678)
2026-02-20 30870216+gaaclarke@users.noreply.github.com Manual dart sdk flutter 174bcc79 25ff 4267 8e26 d0e902f18681 1771486449 (flutter/flutter#182624)
2026-02-20 97480502+b-luk@users.noreply.github.com Don't compile shaders to SkSL unless --sksl arg is present (flutter/flutter#182519)
2026-02-20 katelovett@google.com Correct PerformanceOverlay optionsMask checks and add tests (flutter/flutter#182309)
2026-02-20 jason-simmons@users.noreply.github.com [Impeller] libImpeller: Dispose thread local caches on each Vulkan frame (flutter/flutter#182402)
2026-02-20 31859944+LongCatIsLooong@users.noreply.github.com Update CHANGELOG for 3.41.2 stable hotfix (flutter/flutter#182647)
If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages
Please CC louisehsu@google.com,stuartmorgan@google.com on the revert to ensure that a human
is aware of the problem.
To file a bug in Packages: 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
ahmedsameha1 pushed a commit to ahmedsameha1/flutter that referenced this pull request Feb 27, 2026
…182309)
This re-stages the changes from
flutter#174814
That PR had some outstanding feedback to resolve, this is now done and
we can get this change in, with thanks to @jihanurrahman33 !
From the original PR: > Fix bitmask checks in RenderPerformanceOverlay._intrinsicHeight:
> > Use bitwise AND (&) and compare against 0 instead of bitwise OR (|).
> This ensures the intrinsic height is 0 when no options are enabled,
80.0 for one graph,
> and 160.0 when both rasterizer and engine graphs are enabled.
> Add tests in rendering/performance_overlay_test.dart to verify
intrinsic height for
> various masks.
## Pre-launch Checklist
- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide], including [Features
we expect every widget to implement].
- [x] I signed the [CLA].
- [ ] I listed at least one issue that this PR fixes in the description
above.
- [x] I updated/added relevant documentation (doc comments with `///`).
- [x] I added new tests to check the change I am making, or this PR is
[test-exempt].
- [x] I followed the [breaking change policy] and added [Data Driven
Fixes] where supported.
- [x] All existing and new tests are passing.
If you need help, consider asking for advice on the #hackers-new channel
on [Discord].
**Note**: The Flutter team is currently trialing the use of [Gemini Code
Assist for
GitHub](https://developers.google.com/gemini-code-assist/docs/review-github-code).
Comments from the `gemini-code-assist` bot should not be taken as
authoritative feedback from the Flutter team. If you find its comments
useful you can update your code accordingly, but if you are unsure or
disagree with the feedback, please feel free to wait for a Flutter team
member's review for guidance on which automated comments should be
addressed.
<!-- Links -->
[Contributor Guide]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#overview
[Tree Hygiene]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md
[test-exempt]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#tests
[Flutter Style Guide]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md
[Features we expect every widget to implement]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md#features-we-expect-every-widget-to-implement
[CLA]: https://cla.developers.google.com/
[flutter/tests]: https://github.com/flutter/tests
[breaking change policy]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#handling-breaking-changes
[Discord]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Chat.md
[Data Driven Fixes]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Data-driven-Fixes.md
okorohelijah pushed a commit to okorohelijah/packages that referenced this pull request Mar 26, 2026
…r#11102)
flutter/flutter@91b2d41...dad6f9d
2026-02-23 engine-flutter-autoroll@skia.org Roll Packages from 9da22bf to 12b43a1 (19 revisions) (flutter/flutter#182758)
2026-02-23 engine-flutter-autoroll@skia.org Roll Skia from 55fae1660572 to 9a5a3c92c336 (7 revisions) (flutter/flutter#182749)
2026-02-23 engine-flutter-autoroll@skia.org Roll Skia from 256e2b47b303 to 55fae1660572 (1 revision) (flutter/flutter#182741)
2026-02-22 engine-flutter-autoroll@skia.org Roll Skia from 141ed451f007 to 256e2b47b303 (1 revision) (flutter/flutter#182732)
2026-02-22 engine-flutter-autoroll@skia.org Roll Skia from e59de8a12e7e to 141ed451f007 (1 revision) (flutter/flutter#182729)
2026-02-22 engine-flutter-autoroll@skia.org Roll Skia from f6ea7ef42d14 to e59de8a12e7e (1 revision) (flutter/flutter#182726)
2026-02-22 engine-flutter-autoroll@skia.org Roll Skia from 34fa7b2373f3 to f6ea7ef42d14 (1 revision) (flutter/flutter#182721)
2026-02-21 engine-flutter-autoroll@skia.org Roll Skia from 3ca547c8b816 to 34fa7b2373f3 (2 revisions) (flutter/flutter#182711)
2026-02-21 engine-flutter-autoroll@skia.org Roll Skia from c91ad88e89f8 to 3ca547c8b816 (9 revisions) (flutter/flutter#182696)
2026-02-21 victorsanniay@gmail.com Shortcircuit if Tooltip message and richMessage are empty (flutter/flutter#182524)
2026-02-21 50643541+Mairramer@users.noreply.github.com Add fields getter to FormState (flutter/flutter#180815)
2026-02-20 1961493+harryterkelsen@users.noreply.github.com fix(web_ui): use static whitelist for image codec tests (flutter/flutter#182648)
2026-02-20 victorsanniay@gmail.com Add cupertino docimports for CupertinoPageTransitionsBuilder and fix typos (flutter/flutter#182685)
2026-02-20 katelovett@google.com Fix Chat invite link (flutter/flutter#182675)
2026-02-20 engine-flutter-autoroll@skia.org Roll Skia from ce5854495a3a to c91ad88e89f8 (58 revisions) (flutter/flutter#182678)
2026-02-20 30870216+gaaclarke@users.noreply.github.com Manual dart sdk flutter 174bcc79 25ff 4267 8e26 d0e902f18681 1771486449 (flutter/flutter#182624)
2026-02-20 97480502+b-luk@users.noreply.github.com Don't compile shaders to SkSL unless --sksl arg is present (flutter/flutter#182519)
2026-02-20 katelovett@google.com Correct PerformanceOverlay optionsMask checks and add tests (flutter/flutter#182309)
2026-02-20 jason-simmons@users.noreply.github.com [Impeller] libImpeller: Dispose thread local caches on each Vulkan frame (flutter/flutter#182402)
2026-02-20 31859944+LongCatIsLooong@users.noreply.github.com Update CHANGELOG for 3.41.2 stable hotfix (flutter/flutter#182647)
If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages
Please CC louisehsu@google.com,stuartmorgan@google.com on the revert to ensure that a human
is aware of the problem.
To file a bug in Packages: 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
mboetger pushed a commit to mboetger/flutter that referenced this pull request Mar 26, 2026
…182309)
This re-stages the changes from
flutter#174814
That PR had some outstanding feedback to resolve, this is now done and
we can get this change in, with thanks to @jihanurrahman33 !
From the original PR: > Fix bitmask checks in RenderPerformanceOverlay._intrinsicHeight:
> > Use bitwise AND (&) and compare against 0 instead of bitwise OR (|).
> This ensures the intrinsic height is 0 when no options are enabled,
80.0 for one graph,
> and 160.0 when both rasterizer and engine graphs are enabled.
> Add tests in rendering/performance_overlay_test.dart to verify
intrinsic height for
> various masks.
## Pre-launch Checklist
- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide], including [Features
we expect every widget to implement].
- [x] I signed the [CLA].
- [ ] I listed at least one issue that this PR fixes in the description
above.
- [x] I updated/added relevant documentation (doc comments with `///`).
- [x] I added new tests to check the change I am making, or this PR is
[test-exempt].
- [x] I followed the [breaking change policy] and added [Data Driven
Fixes] where supported.
- [x] All existing and new tests are passing.
If you need help, consider asking for advice on the #hackers-new channel
on [Discord].
**Note**: The Flutter team is currently trialing the use of [Gemini Code
Assist for
GitHub](https://developers.google.com/gemini-code-assist/docs/review-github-code).
Comments from the `gemini-code-assist` bot should not be taken as
authoritative feedback from the Flutter team. If you find its comments
useful you can update your code accordingly, but if you are unsure or
disagree with the feedback, please feel free to wait for a Flutter team
member's review for guidance on which automated comments should be
addressed.
<!-- Links -->
[Contributor Guide]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#overview
[Tree Hygiene]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md
[test-exempt]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#tests
[Flutter Style Guide]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md
[Features we expect every widget to implement]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md#features-we-expect-every-widget-to-implement
[CLA]: https://cla.developers.google.com/
[flutter/tests]: https://github.com/flutter/tests
[breaking change policy]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#handling-breaking-changes
[Discord]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Chat.md
[Data Driven Fixes]:
https://github.com/flutter/flutter/blob/main/docs/contributing/Data-driven-Fixes.md
creatorpiyush pushed a commit to creatorpiyush/packages that referenced this pull request Jun 10, 2026
…r#11102)
flutter/flutter@91b2d41...dad6f9d
2026-02-23 engine-flutter-autoroll@skia.org Roll Packages from 9da22bf to 12b43a1 (19 revisions) (flutter/flutter#182758)
2026-02-23 engine-flutter-autoroll@skia.org Roll Skia from 55fae1660572 to 9a5a3c92c336 (7 revisions) (flutter/flutter#182749)
2026-02-23 engine-flutter-autoroll@skia.org Roll Skia from 256e2b47b303 to 55fae1660572 (1 revision) (flutter/flutter#182741)
2026-02-22 engine-flutter-autoroll@skia.org Roll Skia from 141ed451f007 to 256e2b47b303 (1 revision) (flutter/flutter#182732)
2026-02-22 engine-flutter-autoroll@skia.org Roll Skia from e59de8a12e7e to 141ed451f007 (1 revision) (flutter/flutter#182729)
2026-02-22 engine-flutter-autoroll@skia.org Roll Skia from f6ea7ef42d14 to e59de8a12e7e (1 revision) (flutter/flutter#182726)
2026-02-22 engine-flutter-autoroll@skia.org Roll Skia from 34fa7b2373f3 to f6ea7ef42d14 (1 revision) (flutter/flutter#182721)
2026-02-21 engine-flutter-autoroll@skia.org Roll Skia from 3ca547c8b816 to 34fa7b2373f3 (2 revisions) (flutter/flutter#182711)
2026-02-21 engine-flutter-autoroll@skia.org Roll Skia from c91ad88e89f8 to 3ca547c8b816 (9 revisions) (flutter/flutter#182696)
2026-02-21 victorsanniay@gmail.com Shortcircuit if Tooltip message and richMessage are empty (flutter/flutter#182524)
2026-02-21 50643541+Mairramer@users.noreply.github.com Add fields getter to FormState (flutter/flutter#180815)
2026-02-20 1961493+harryterkelsen@users.noreply.github.com fix(web_ui): use static whitelist for image codec tests (flutter/flutter#182648)
2026-02-20 victorsanniay@gmail.com Add cupertino docimports for CupertinoPageTransitionsBuilder and fix typos (flutter/flutter#182685)
2026-02-20 katelovett@google.com Fix Chat invite link (flutter/flutter#182675)
2026-02-20 engine-flutter-autoroll@skia.org Roll Skia from ce5854495a3a to c91ad88e89f8 (58 revisions) (flutter/flutter#182678)
2026-02-20 30870216+gaaclarke@users.noreply.github.com Manual dart sdk flutter 174bcc79 25ff 4267 8e26 d0e902f18681 1771486449 (flutter/flutter#182624)
2026-02-20 97480502+b-luk@users.noreply.github.com Don't compile shaders to SkSL unless --sksl arg is present (flutter/flutter#182519)
2026-02-20 katelovett@google.com Correct PerformanceOverlay optionsMask checks and add tests (flutter/flutter#182309)
2026-02-20 jason-simmons@users.noreply.github.com [Impeller] libImpeller: Dispose thread local caches on each Vulkan frame (flutter/flutter#182402)
2026-02-20 31859944+LongCatIsLooong@users.noreply.github.com Update CHANGELOG for 3.41.2 stable hotfix (flutter/flutter#182647)
If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages
Please CC louisehsu@google.com,stuartmorgan@google.com on the revert to ensure that a human
is aware of the problem.
To file a bug in Packages: 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 freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

frameworkflutter/packages/flutter repository. See also f: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@Piinks@justinmc@dkwingsmt