radv/aco: Enable NGG GS by default.
authorTimur Kristóf <timur.kristof@gmail.com>
Thu, 1 Oct 2020 14:59:18 +0000 (16:59 +0200)
committerTimur Kristóf <timur.kristof@gmail.com>
Fri, 9 Oct 2020 13:26:15 +0000 (15:26 +0200)
ACO NGG GS now supports everything we need except streamout
(aka. transform feedback), but we don't use NGG anyway when
streamout is needed.

Also add a note to the new features txt.

Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6964>

docs/relnotes/new_features.txt
src/amd/vulkan/radv_device.c
src/amd/vulkan/radv_pipeline.c
src/amd/vulkan/radv_private.h
src/amd/vulkan/radv_query.c

index e2c9ff1..c845953 100644 (file)
@@ -8,3 +8,4 @@ VK_PRESENT_MODE_FIFO_RELAXED on X11
 GLX_EXT_swap_control for DRI2 and DRI3
 GLX_EXT_swap_control_tear for DRI3
 VK_KHR_copy_commands2 on RADV
+NGG GS support in ACO
index 162dbab..55fb83a 100644 (file)
@@ -402,8 +402,6 @@ radv_physical_device_try_create(struct radv_instance *instance,
                          device->rad_info.has_dedicated_vram &&
                          !(device->instance->debug_flags & RADV_DEBUG_NO_NGG);
 
-       /* TODO: Implement NGG GS with ACO. */
-       device->use_ngg_gs = device->use_ngg && device->use_llvm;
        device->use_ngg_streamout = false;
 
        /* Determine the number of threads per wave for all stages. */
index 32b8511..1f02622 100644 (file)
@@ -2552,15 +2552,6 @@ radv_fill_shader_keys(struct radv_device *device,
                        keys[MESA_SHADER_TESS_EVAL].vs_common_out.as_ngg = false;
                }
 
-               if (!device->physical_device->use_ngg_gs) {
-                       if (nir[MESA_SHADER_GEOMETRY]) {
-                               if (nir[MESA_SHADER_TESS_CTRL])
-                                       keys[MESA_SHADER_TESS_EVAL].vs_common_out.as_ngg = false;
-                               else
-                                       keys[MESA_SHADER_VERTEX].vs_common_out.as_ngg = false;
-                       }
-               }
-
                gl_shader_stage last_xfb_stage = MESA_SHADER_VERTEX;
 
                for (int i = MESA_SHADER_VERTEX; i <= MESA_SHADER_GEOMETRY; i++) {
index 1643650..c8f2578 100644 (file)
@@ -299,9 +299,6 @@ struct radv_physical_device {
        /* Whether to enable NGG. */
        bool use_ngg;
 
-       /* Whether to enable NGG GS. */
-       bool use_ngg_gs;
-
        /* Whether to enable NGG streamout. */
        bool use_ngg_streamout;
 
index 1353141..ccff1f7 100644 (file)
@@ -1133,7 +1133,7 @@ radv_query_pool_needs_gds(struct radv_device *device,
         * TODO: fix use of NGG GS and non-NGG GS inside the same begin/end
         * query.
         */
-       return device->physical_device->use_ngg_gs &&
+       return device->physical_device->use_ngg &&
               (pool->pipeline_stats_mask & VK_QUERY_PIPELINE_STATISTIC_GEOMETRY_SHADER_PRIMITIVES_BIT);
 }