From ee65190753b420d0562ab3165569a8fbb312c585 Mon Sep 17 00:00:00 2001 From: Chinmay Garde Date: Mon, 31 Jul 2023 16:43:01 -0700 Subject: [PATCH] [Impeller] Add documentation on how to enable Metal Profiling HUD without Xcode. (flutter/engine#44196) --- .../flutter/impeller/docs/metal_validation.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/engine/src/flutter/impeller/docs/metal_validation.md b/engine/src/flutter/impeller/docs/metal_validation.md index dde2ce1362..c322a3240e 100644 --- a/engine/src/flutter/impeller/docs/metal_validation.md +++ b/engine/src/flutter/impeller/docs/metal_validation.md @@ -21,3 +21,21 @@ export MTL_SHADER_VALIDATION=1 These environment variable are good defaults but there are more validation related knobs and dials to turn. See `man MetalValidation`. + +# Enable Metal Profiling HUD without Xcode + +Applications can optionally display a HUD that displays real-time information +about Metal related performance. + +![Profiling HUD](assets/metal_validation/performance_hud.png) + +More documentation about the specific elements of the HUD is present on the +[Apple developer site](https://developer.apple.com/documentation/xcode/monitoring-your-metal-apps-graphics-performance). + +The Profiling HUD is separate from Metal Validation and can be enabled for apps +that are launched from the command like (like Impeller Playgrounds) using +environment variables. Add the following to your `.rc` file. + +```sh +export MTL_HUD_ENABLED=1 +```