diff options
author | Samuel Pitoiset <[email protected]> | 2018-03-14 12:01:49 +0100 |
---|---|---|
committer | Samuel Pitoiset <[email protected]> | 2018-03-15 17:19:52 +0100 |
commit | 5be2757c3506004d9913ad2ea3ad4fbe6af70dce (patch) | |
tree | 82b2148fc6fe9319c6d71a8260a7a46b7a179872 /src | |
parent | 6332893594924a14e984aee2b75f7a5263816b19 (diff) |
radv: only display options that are enabled
Signed-off-by: Samuel Pitoiset <[email protected]>
Reviewed-by: Bas Nieuwenhuizen <[email protected]>
Diffstat (limited to 'src')
-rw-r--r-- | src/amd/vulkan/radv_debug.c | 28 |
1 files changed, 16 insertions, 12 deletions
diff --git a/src/amd/vulkan/radv_debug.c b/src/amd/vulkan/radv_debug.c index c8794d06ea8..f3b79004f69 100644 --- a/src/amd/vulkan/radv_debug.c +++ b/src/amd/vulkan/radv_debug.c @@ -598,23 +598,27 @@ radv_dump_enabled_options(struct radv_device *device, FILE *f) { uint64_t mask; - fprintf(f, "Enabled debug options: "); + if (device->instance->debug_flags) { + fprintf(f, "Enabled debug options: "); - mask = device->instance->debug_flags; - while (mask) { - int i = u_bit_scan64(&mask); - fprintf(f, "%s, ", radv_get_debug_option_name(i)); + mask = device->instance->debug_flags; + while (mask) { + int i = u_bit_scan64(&mask); + fprintf(f, "%s, ", radv_get_debug_option_name(i)); + } + fprintf(f, "\n"); } - fprintf(f, "\n"); - fprintf(f, "Enabled perftest options: "); + if (device->instance->perftest_flags) { + fprintf(f, "Enabled perftest options: "); - mask = device->instance->perftest_flags; - while (mask) { - int i = u_bit_scan64(&mask); - fprintf(f, "%s, ", radv_get_perftest_option_name(i)); + mask = device->instance->perftest_flags; + while (mask) { + int i = u_bit_scan64(&mask); + fprintf(f, "%s, ", radv_get_perftest_option_name(i)); + } + fprintf(f, "\n"); } - fprintf(f, "\n"); } static void |