diff options
author | Dave Airlie <[email protected]> | 2017-08-04 02:13:55 +0100 |
---|---|---|
committer | Andres Gomez <[email protected]> | 2017-08-19 13:46:04 +0300 |
commit | ad07debbd9c936cd64bea4c5372ff8f39379c729 (patch) | |
tree | e0745940a255750f3b3567b20fa1a52ec58716bc /src | |
parent | 0cfd8879b17dcc9920956630f9889305fef85b78 (diff) |
radv: avoid GPU hangs if someone does a resolve with non-multisample src (v2)
This is a bug in the app, but I'd rather avoid hanging the GPU,
esp if someone is running in validation and it takes out their
development environment.
v2: get it right, reverse the polarity.
Reviewed-by: Bas Nieuwenhuizen <[email protected]>
Cc: <[email protected]>
Signed-off-by: Dave Airlie <[email protected]>
(cherry picked from commit 36a1b61321561634c6b243cf876c347fef73dfa4)
[Andres Gomez: resolve trivial conflicts]
Signed-off-by: Andres Gomez <[email protected]>
Conflicts:
src/amd/vulkan/radv_meta_resolve.c
Diffstat (limited to 'src')
-rw-r--r-- | src/amd/vulkan/radv_meta_resolve.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/amd/vulkan/radv_meta_resolve.c b/src/amd/vulkan/radv_meta_resolve.c index 52f7246f6e3..a21cbe5bd27 100644 --- a/src/amd/vulkan/radv_meta_resolve.c +++ b/src/amd/vulkan/radv_meta_resolve.c @@ -436,6 +436,11 @@ void radv_CmdResolveImage( radv_meta_save_graphics_reset_vport_scissor(&saved_state, cmd_buffer); assert(src_image->samples > 1); + if (src_image->samples <= 1) { + /* this causes GPU hangs if we get past here */ + fprintf(stderr, "radv: Illegal resolve operation (src not multisampled), will hang GPU."); + return; + } assert(dest_image->samples == 1); if (src_image->samples >= 16) { |