Mesa (master): radv: do VGT_FLUSH when switching NGG -> legacy on Sienna Cichlid

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Tue Nov 17 10:45:58 UTC 2020


Module: Mesa
Branch: master
Commit: 0790105f2f0d1813dc2ecaf5e12e7131730a8bc1
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=0790105f2f0d1813dc2ecaf5e12e7131730a8bc1

Author: Samuel Pitoiset <samuel.pitoiset at gmail.com>
Date:   Wed Nov 11 09:02:31 2020 +0100

radv: do VGT_FLUSH when switching NGG -> legacy on Sienna Cichlid

Ported from RadeonSI.

Cc: 20.2
Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas at basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7566>

---

 src/amd/vulkan/radv_cmd_buffer.c | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/src/amd/vulkan/radv_cmd_buffer.c b/src/amd/vulkan/radv_cmd_buffer.c
index f0a4d05fc6f..51467db62eb 100644
--- a/src/amd/vulkan/radv_cmd_buffer.c
+++ b/src/amd/vulkan/radv_cmd_buffer.c
@@ -4179,14 +4179,15 @@ void radv_CmdBindPipeline(
 		/* Prefetch all pipeline shaders at first draw time. */
 		cmd_buffer->state.prefetch_L2_mask |= RADV_PREFETCH_SHADERS;
 
-		if (cmd_buffer->device->physical_device->rad_info.chip_class == GFX10 &&
+		if ((cmd_buffer->device->physical_device->rad_info.chip_class == GFX10 ||
+		     cmd_buffer->device->physical_device->rad_info.family == CHIP_SIENNA_CICHLID) &&
 		    cmd_buffer->state.emitted_pipeline &&
 		    radv_pipeline_has_ngg(cmd_buffer->state.emitted_pipeline) &&
 		    !radv_pipeline_has_ngg(cmd_buffer->state.pipeline)) {
 			/* Transitioning from NGG to legacy GS requires
-			 * VGT_FLUSH on Navi10-14.  VGT_FLUSH is also emitted
-			 * at the beginning of IBs when legacy GS ring pointers
-			 * are set.
+			 * VGT_FLUSH on GFX10 and Sienna Cichlid. VGT_FLUSH
+			 * is also emitted at the beginning of IBs when legacy
+			 * GS ring pointers are set.
 			 */
 			cmd_buffer->state.flush_bits |= RADV_CMD_FLAG_VGT_FLUSH;
 		}



More information about the mesa-commit mailing list