radv: allocate enough space in radv_cmd_buffer_after_draw()
authorSamuel Pitoiset <samuel.pitoiset@gmail.com>
Wed, 25 Jul 2018 15:01:46 +0000 (17:01 +0200)
committerSamuel Pitoiset <samuel.pitoiset@gmail.com>
Fri, 27 Jul 2018 12:31:29 +0000 (14:31 +0200)
The driver might emit up to 4 dwords when RADV_TRACE_FILE is
used.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
src/amd/vulkan/radv_cmd_buffer.c

index 2fb64d91d8e951d1a764ba5133cebf4f8e5eec73..e0222d0b50b1aa13747b4227ae073590746f00e9 100644 (file)
@@ -482,6 +482,8 @@ radv_cmd_buffer_after_draw(struct radv_cmd_buffer *cmd_buffer,
                        ptr = &cmd_buffer->gfx9_fence_idx;
                }
 
+               radeon_check_space(cmd_buffer->device->ws, cmd_buffer->cs, 4);
+
                /* Force wait for graphics or compute engines to be idle. */
                si_cs_emit_cache_flush(cmd_buffer->cs,
                                       cmd_buffer->device->physical_device->rad_info.chip_class,