radv: fix geometry shader primitives query with ACO on GFX10
Fixes
dEQP-VK.query_pool.statistics_query.*.geometry_shader_primitives.*.
Fixes: c24d9522da
("radv: Enable ACO for NGG VS/TES, but disable NGG for ACO GS.")
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4593>
This commit is contained in:
parent
f7d620f47d
commit
fd6e44236c
|
@ -412,6 +412,8 @@ radv_physical_device_init(struct radv_physical_device *device,
|
|||
device->rad_info.family != CHIP_NAVI14 &&
|
||||
!(device->instance->debug_flags & RADV_DEBUG_NO_NGG);
|
||||
|
||||
/* TODO: Implement NGG GS with ACO. */
|
||||
device->use_ngg_gs = device->use_ngg && !device->use_aco;
|
||||
device->use_ngg_streamout = false;
|
||||
|
||||
/* Determine the number of threads per wave for all stages. */
|
||||
|
|
|
@ -2461,17 +2461,13 @@ radv_fill_shader_keys(struct radv_device *device,
|
|||
keys[MESA_SHADER_TESS_EVAL].vs_common_out.as_ngg = false;
|
||||
}
|
||||
|
||||
if (device->physical_device->use_aco) {
|
||||
/* Disable NGG GS when ACO is used */
|
||||
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;
|
||||
}
|
||||
|
||||
/* NGG streamout not yet supported by ACO */
|
||||
assert(!device->physical_device->use_ngg_streamout);
|
||||
}
|
||||
|
||||
gl_shader_stage last_xfb_stage = MESA_SHADER_VERTEX;
|
||||
|
|
|
@ -327,6 +327,9 @@ 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;
|
||||
|
||||
|
|
|
@ -1265,7 +1265,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 &&
|
||||
return device->physical_device->use_ngg_gs &&
|
||||
(pool->pipeline_stats_mask & VK_QUERY_PIPELINE_STATISTIC_GEOMETRY_SHADER_PRIMITIVES_BIT);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue