radeonsi/gfx10: prefetch HW GS when NGG is used
authorMarek Olšák <marek.olsak@amd.com>
Tue, 28 May 2019 22:55:30 +0000 (18:55 -0400)
committerMarek Olšák <marek.olsak@amd.com>
Wed, 3 Jul 2019 19:51:13 +0000 (15:51 -0400)
Acked-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
src/gallium/drivers/radeonsi/si_cp_dma.c

index e9ddfe6f49d2c84e1e6b7baca591725e8fcb39b3..d1b44b894b14337d3355df2fdf80ef873a77e454 100644 (file)
@@ -455,7 +455,7 @@ void cik_emit_prefetch_L2(struct si_context *sctx, bool vertex_stage_only)
        /* Prefetch shaders and VBO descriptors to TC L2. */
        if (sctx->chip_class >= GFX9) {
                /* Choose the right spot for the VBO prefetch. */
-               if (sctx->tes_shader.cso) {
+               if (sctx->queued.named.hs) {
                        if (mask & SI_PREFETCH_HS)
                                cik_prefetch_shader_async(sctx, sctx->queued.named.hs);
                        if (mask & SI_PREFETCH_VBO_DESCRIPTORS)
@@ -470,7 +470,7 @@ void cik_emit_prefetch_L2(struct si_context *sctx, bool vertex_stage_only)
                                cik_prefetch_shader_async(sctx, sctx->queued.named.gs);
                        if (mask & SI_PREFETCH_VS)
                                cik_prefetch_shader_async(sctx, sctx->queued.named.vs);
-               } else if (sctx->gs_shader.cso) {
+               } else if (sctx->queued.named.gs) {
                        if (mask & SI_PREFETCH_GS)
                                cik_prefetch_shader_async(sctx, sctx->queued.named.gs);
                        if (mask & SI_PREFETCH_VBO_DESCRIPTORS)