Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shader analysis with malioc #39005

Merged
merged 1 commit into from
Jan 19, 2023
Merged

Shader analysis with malioc #39005

merged 1 commit into from
Jan 19, 2023

Conversation

zanderso
Copy link
Member

This PR adds logic to the GN build to analyze shaders and output the analysis results in the build output directory unconditionally when the build is configured with the path to malioc using the --malioc-path flag passed to the gn script. malioc is quite fast, so this does not affect build times.

This PR also adds a script impeller/tools/malioc_diff.py that detects before/after changes in the results of malioc's analysis, or generate a analysis results golden file. In a subsequent PR, the plan is to check in such a golden file, and then compare shader analysis results on PRs/commits against the golden file in CI.

Copy link
Member

@jonahwilliams jonahwilliams left a comment

Choose a reason for hiding this comment

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

how does this handle the SSBO shaders?

LGTM

}

template("malioc_analyze_shaders") {
# TODO(zra): Check that gles_language_version is in the supported set. For now
Copy link
Member Author

Choose a reason for hiding this comment

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

@jonahwilliams ssbos requires a higher language version, so when any language version is set, analysis is skipped. This TODO is for tightening this logic to match what the analyzer supports.

Copy link
Member

Choose a reason for hiding this comment

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

makes sense!

@zanderso zanderso merged commit f2536ce into flutter:main Jan 19, 2023
@zanderso zanderso deleted the malioc branch January 19, 2023 20:42
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jan 19, 2023
auto-submit bot pushed a commit to flutter/flutter that referenced this pull request Jan 19, 2023
…118839)

* f2536ce8d Shader analysis with malioc (flutter/engine#39005)

* dd8c259bb [Impeller] Account for the transform in DLVerticesGeometry coverage (flutter/engine#38998)

* 26b6609c6 Remove unused variables and import (flutter/engine#38971)
ricardoamador pushed a commit to ricardoamador/engine that referenced this pull request Jan 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants