diff options
author | Timur Kristóf <[email protected]> | 2019-09-18 14:39:10 +0200 |
---|---|---|
committer | Connor Abbott <[email protected]> | 2019-09-26 13:36:49 +0000 |
commit | 30f0c0ea7db129dafb2e879de8faad6907a09791 (patch) | |
tree | 280a0dd7c814a412154d453baaef73ac06446903 /src/amd/vulkan/radv_shader.c | |
parent | a4fd8ba7e39f7571a2a08e3c602b4d08566f3a09 (diff) |
radv: Add debug option to dump meta shaders.
This new option can help debug shader compiler problems when
there are issues with the meta shaders.
Signed-off-by: Timur Kristóf <[email protected]>
Reviewed-by: Bas Nieuwenhuizen <[email protected]>
Diffstat (limited to 'src/amd/vulkan/radv_shader.c')
-rw-r--r-- | src/amd/vulkan/radv_shader.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/amd/vulkan/radv_shader.c b/src/amd/vulkan/radv_shader.c index eb0886bd1f8..086f7cd8616 100644 --- a/src/amd/vulkan/radv_shader.c +++ b/src/amd/vulkan/radv_shader.c @@ -119,9 +119,11 @@ radv_can_dump_shader(struct radv_device *device, { if (!(device->instance->debug_flags & RADV_DEBUG_DUMP_SHADERS)) return false; + if (module) + return !module->nir || + (device->instance->debug_flags & RADV_DEBUG_DUMP_META_SHADERS); - /* Only dump non-meta shaders, useful for debugging purposes. */ - return (module && !module->nir) || is_gs_copy_shader; + return is_gs_copy_shader; } bool |