OSDN Git Service

ddebug: implement pipelined hang detection mode
authorMarek Olšák <marek.olsak@amd.com>
Tue, 19 Jul 2016 16:28:24 +0000 (18:28 +0200)
committerMarek Olšák <marek.olsak@amd.com>
Tue, 26 Jul 2016 21:06:46 +0000 (23:06 +0200)
commitb47727a83ad6b5386f27b2c174a5c0f110a61038
tree162d39a05a9467160d23cc903bc49f2786193330
parent0795a3d54f7748d27020851f2e9b4b7637597590
ddebug: implement pipelined hang detection mode

For good performance while being able to generate decent hang reports.
The report doesn't contain the parsed IB and the buffer list, but it
isolates the draw call and dumps shaders while not having to flush
the context.

This is for GPU hangs that are harder to reproduce and require interactive
playing for minutes or even hours.

dd_pipe.h explains some implementation details. Initializing, copying
(recording) and clearing states is most of the code.

The performance should be at least 50% of the normal performance depending
on the circumstances. (i.e. 50% is expected to be the worst case scenario,
not the best case) The majority of time is spent in
dump_debug_state(PIPE_DUMP_CURRENT_SHADERS) and that's after all
the optimizations in later patches. There is no obvious way to optimize
that further.

Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
src/gallium/drivers/ddebug/dd_context.c
src/gallium/drivers/ddebug/dd_draw.c
src/gallium/drivers/ddebug/dd_pipe.h
src/gallium/drivers/ddebug/dd_screen.c