ANGLE‘s Metal backend provides a couple of features for inspecting the Metal Shading Language (MSL) produced by ANGLE’s shader translator.
The printMetalShaders feature, which can be enabled in Chromium via the command line argument --enable-angle-features=printMetalShaders, dumps the blob cache key and translated MSL for all shaders compiled by ANGLE. This is currently used to regenerate precompiled shaders shipped with Chrome.
Setting the environment variable ANGLE_METAL_PRINT_MSL_ENABLE to 1 indicates to the Metal backend to print the translated shaders as they're compiled.