radv/aco: disable NGG GS support because it randomly hangs the GPU
Disable ACO NGG GS until the random GPU hangs are fixed (one CTS run == one GPU hang here). No hangs so far after 5 full CTS runs with this disabled. Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Acked-by: Timur Kristóf <timur.kristof@gmail.com> Reviewed-by: Daniel Schürmann <daniel@schuermann.dev> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7108>
This commit is contained in:
@@ -402,6 +402,8 @@ radv_physical_device_try_create(struct radv_instance *instance,
|
|||||||
device->rad_info.has_dedicated_vram &&
|
device->rad_info.has_dedicated_vram &&
|
||||||
!(device->instance->debug_flags & RADV_DEBUG_NO_NGG);
|
!(device->instance->debug_flags & RADV_DEBUG_NO_NGG);
|
||||||
|
|
||||||
|
/* FIXME: ACO NGG GS randomly hangs the GPU with CTS. */
|
||||||
|
device->use_ngg_gs = device->use_ngg && device->use_llvm;
|
||||||
device->use_ngg_streamout = false;
|
device->use_ngg_streamout = false;
|
||||||
|
|
||||||
/* Determine the number of threads per wave for all stages. */
|
/* Determine the number of threads per wave for all stages. */
|
||||||
|
@@ -2577,6 +2577,15 @@ radv_fill_shader_keys(struct radv_device *device,
|
|||||||
keys[MESA_SHADER_TESS_EVAL].vs_common_out.as_ngg = false;
|
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;
|
gl_shader_stage last_xfb_stage = MESA_SHADER_VERTEX;
|
||||||
|
|
||||||
for (int i = MESA_SHADER_VERTEX; i <= MESA_SHADER_GEOMETRY; i++) {
|
for (int i = MESA_SHADER_VERTEX; i <= MESA_SHADER_GEOMETRY; i++) {
|
||||||
|
@@ -299,6 +299,9 @@ struct radv_physical_device {
|
|||||||
/* Whether to enable NGG. */
|
/* Whether to enable NGG. */
|
||||||
bool use_ngg;
|
bool use_ngg;
|
||||||
|
|
||||||
|
/* Whether to enable NGG GS. */
|
||||||
|
bool use_ngg_gs;
|
||||||
|
|
||||||
/* Whether to enable NGG streamout. */
|
/* Whether to enable NGG streamout. */
|
||||||
bool use_ngg_streamout;
|
bool use_ngg_streamout;
|
||||||
|
|
||||||
|
@@ -1134,7 +1134,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
|
* TODO: fix use of NGG GS and non-NGG GS inside the same begin/end
|
||||||
* query.
|
* 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);
|
(pool->pipeline_stats_mask & VK_QUERY_PIPELINE_STATISTIC_GEOMETRY_SHADER_PRIMITIVES_BIT);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -557,7 +557,7 @@ radv_shader_compile_to_nir(struct radv_device *device,
|
|||||||
if (nir->info.stage == MESA_SHADER_GEOMETRY) {
|
if (nir->info.stage == MESA_SHADER_GEOMETRY) {
|
||||||
unsigned nir_gs_flags = nir_lower_gs_intrinsics_per_stream;
|
unsigned nir_gs_flags = nir_lower_gs_intrinsics_per_stream;
|
||||||
|
|
||||||
if (device->physical_device->use_ngg && !radv_use_llvm_for_stage(device, stage)) {
|
if (device->physical_device->use_ngg_gs && !radv_use_llvm_for_stage(device, stage)) {
|
||||||
/* ACO needs NIR to do some of the hard lifting */
|
/* ACO needs NIR to do some of the hard lifting */
|
||||||
nir_gs_flags |= nir_lower_gs_intrinsics_count_primitives |
|
nir_gs_flags |= nir_lower_gs_intrinsics_count_primitives |
|
||||||
nir_lower_gs_intrinsics_count_vertices_per_primitive |
|
nir_lower_gs_intrinsics_count_vertices_per_primitive |
|
||||||
|
Reference in New Issue
Block a user