aco: add ACO_DEBUG=liveinfo

Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9599>
This commit is contained in:
Rhys Perry 2021-03-15 14:17:14 +00:00 committed by Marge Bot
parent 8e409abf96
commit e2cdbb25c7
4 changed files with 7 additions and 0 deletions

View File

@ -667,6 +667,8 @@ RADV driver environment variables
disable instructions scheduling
``perfinfo``
print information used to calculate some pipeline statistics
``liveinfo``
print liveness and register demand information before scheduling
radeonsi driver environment variables
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

View File

@ -131,6 +131,9 @@ void aco_compile_shader(unsigned shader_count,
if (program->collect_statistics)
aco::collect_presched_stats(program.get());
if ((aco::debug_flags & aco::DEBUG_LIVE_INFO) && args->options->dump_shader)
aco_print_program(program.get(), stderr, live_vars, aco::print_live_vars | aco::print_kill);
if (!args->is_trap_handler_shader) {
if (!args->options->disable_optimizations &&
!(aco::debug_flags & aco::DEBUG_NO_SCHED))

View File

@ -39,6 +39,7 @@ static const struct debug_control aco_debug_options[] = {
{"noopt", DEBUG_NO_OPT},
{"nosched", DEBUG_NO_SCHED},
{"perfinfo", DEBUG_PERF_INFO},
{"liveinfo", DEBUG_LIVE_INFO},
{NULL, 0}
};

View File

@ -56,6 +56,7 @@ enum {
DEBUG_NO_OPT = 0x20,
DEBUG_NO_SCHED = 0x40,
DEBUG_PERF_INFO = 0x80,
DEBUG_LIVE_INFO = 0x100,
};
/**