diff options
author | Nicolai Hähnle <[email protected]> | 2015-12-08 06:49:12 -0500 |
---|---|---|
committer | Nicolai Hähnle <[email protected]> | 2015-12-12 15:23:34 -0500 |
commit | b86d5ccae2b6280ad26d1060295fcc4963e90011 (patch) | |
tree | f421764e0841d420989f9623be6ef06e924f2baf /src/gallium/drivers/ddebug/dd_screen.c | |
parent | af7ba989fb5a39925a0a1261ed281fe7f48a16cf (diff) |
gallium/ddebug: add GALLIUM_DDEBUG_SKIP option
When we know that hangs occur only very late in a reproducible run (e.g.
apitrace), we can save a lot of debugging time by skipping the flush and hang
detection for earlier draw calls.
Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/gallium/drivers/ddebug/dd_screen.c')
-rw-r--r-- | src/gallium/drivers/ddebug/dd_screen.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/gallium/drivers/ddebug/dd_screen.c b/src/gallium/drivers/ddebug/dd_screen.c index a776580c9bb..2716845f58f 100644 --- a/src/gallium/drivers/ddebug/dd_screen.c +++ b/src/gallium/drivers/ddebug/dd_screen.c @@ -290,6 +290,9 @@ ddebug_screen_create(struct pipe_screen *screen) puts(" $HOME/"DD_DIR"/ when a hang is detected."); puts(" If 'noflush' is specified, only detect hangs in pipe->flush."); puts(""); + puts(" GALLIUM_DDEBUG_SKIP=[count]"); + puts(" Skip flush and hang detection for the given initial number of draw calls."); + puts(""); exit(0); } @@ -349,5 +352,11 @@ ddebug_screen_create(struct pipe_screen *screen) assert(0); } + dscreen->skip_count = debug_get_num_option("GALLIUM_DDEBUG_SKIP", 0); + if (dscreen->skip_count > 0) { + fprintf(stderr, "Gallium debugger skipping the first %u draw calls.\n", + dscreen->skip_count); + } + return &dscreen->base; } |