diff options
author | Matt Turner <[email protected]> | 2017-04-25 10:00:19 -0700 |
---|---|---|
committer | Matt Turner <[email protected]> | 2017-05-15 11:42:41 -0700 |
commit | 8ca8ebbf78d6e5eacbd42dc245f503e0c9787268 (patch) | |
tree | dc6e84990f54efd95b88caa471d0759125ebde44 /src/mesa/drivers/dri/i965/intel_screen.h | |
parent | 0aa578714e9d664ab15d2bfb70102505928d8119 (diff) |
i965: Mark shader programs for capture in the error state.
When the GPU hangs, the kernel saves some state for us. Until now it has
not included the shader programs, which are very often the reason the
GPU hang occurred. With the programs saved in the error state, we should
be more capable of debugging hangs.
Thanks to Chris Wilson and Ben Widawsky who provided the kernel support
for this feature ("drm/i915: Copy user requested buffers into the error
state"), which will be in kernel v4.13.
Reviewed-by: Topi Pohjolainen <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri/i965/intel_screen.h')
-rw-r--r-- | src/mesa/drivers/dri/i965/intel_screen.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i965/intel_screen.h b/src/mesa/drivers/dri/i965/intel_screen.h index fe0e0444b2d..f9c1db6df12 100644 --- a/src/mesa/drivers/dri/i965/intel_screen.h +++ b/src/mesa/drivers/dri/i965/intel_screen.h @@ -74,6 +74,7 @@ struct intel_screen #define KERNEL_ALLOWS_MI_MATH_AND_LRR (1<<2) #define KERNEL_ALLOWS_HSW_SCRATCH1_AND_ROW_CHICKEN3 (1<<3) #define KERNEL_ALLOWS_COMPUTE_DISPATCH (1<<4) +#define KERNEL_ALLOWS_EXEC_CAPTURE (1<<5) struct brw_bufmgr *bufmgr; @@ -155,6 +156,12 @@ can_do_predicate_writes(const struct intel_screen *screen) return screen->kernel_features & KERNEL_ALLOWS_PREDICATE_WRITES; } +static inline bool +can_do_exec_capture(const struct intel_screen *screen) +{ + return screen->kernel_features & KERNEL_ALLOWS_EXEC_CAPTURE; +} + #ifdef __cplusplus } #endif |