summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2016-07-30 14:57:20 +0200
committerMarek Olšák <[email protected]>2016-08-03 17:46:46 +0200
commitc2a0e991694f1fa84f24aacd2c2d47eecbd4da0f (patch)
treecb19b6027cb4464f3a7ed801bb44489a28acf7d5
parent6573ad69ef836118c006acd7ccd3506e5c023b6e (diff)
radeonsi: print the command line to VM fault reports (v2)
v2: rebase on top of Brian's commit Reviewed-by: Nicolai Hähnle <[email protected]>
-rw-r--r--src/gallium/drivers/radeonsi/si_debug.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gallium/drivers/radeonsi/si_debug.c b/src/gallium/drivers/radeonsi/si_debug.c
index e030f487542..ae11b2c7519 100644
--- a/src/gallium/drivers/radeonsi/si_debug.c
+++ b/src/gallium/drivers/radeonsi/si_debug.c
@@ -805,6 +805,7 @@ void si_check_vm_faults(struct r600_common_context *ctx,
struct pipe_screen *screen = sctx->b.b.screen;
FILE *f;
uint32_t addr;
+ char cmd_line[4096];
if (!si_vm_fault_occured(sctx, &addr))
return;
@@ -814,6 +815,8 @@ void si_check_vm_faults(struct r600_common_context *ctx,
return;
fprintf(f, "VM fault report.\n\n");
+ if (os_get_command_line(cmd_line, sizeof(cmd_line)))
+ fprintf(f, "Command: %s\n", cmd_line);
fprintf(f, "Driver vendor: %s\n", screen->get_vendor(screen));
fprintf(f, "Device vendor: %s\n", screen->get_device_vendor(screen));
fprintf(f, "Device name: %s\n\n", screen->get_name(screen));