radv: remove redundant drirc for incorrect dual-source blending

The pass that lowers PS outputs has been rewritten since 45d8cd037a
("ac/nir: rewrite ac_nir_lower_ps epilog to fix dual src blending
with mono PS") to handle invalid uses of dual-source blending.

This drirc used to workaround game bugs on GFX11 only should no longer
be necessary.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32514>
This commit is contained in:
Samuel Pitoiset
2024-12-05 18:05:47 +01:00
committed by Marge Bot
parent e1bb53bb3c
commit 6b671d4dab
8 changed files with 0 additions and 36 deletions
-4
View File
@@ -185,7 +185,6 @@ static const driOptionDescription radv_dri_options[] = {
DRI_CONF_RADV_RT_WAVE64(false)
DRI_CONF_RADV_LEGACY_SPARSE_BINDING(false)
DRI_CONF_RADV_FORCE_PSTATE_PEAK_GFX11_DGPU(false)
DRI_CONF_DUAL_COLOR_BLEND_BY_LOCATION(false)
DRI_CONF_RADV_OVERRIDE_GRAPHICS_SHADER_VERSION(0)
DRI_CONF_RADV_OVERRIDE_COMPUTE_SHADER_VERSION(0)
DRI_CONF_RADV_OVERRIDE_RAY_TRACING_SHADER_VERSION(0)
@@ -257,9 +256,6 @@ radv_init_dri_options(struct radv_instance *instance)
instance->drirc.force_rt_wave64 = driQueryOptionb(&instance->drirc.options, "radv_rt_wave64");
instance->drirc.dual_color_blend_by_location =
driQueryOptionb(&instance->drirc.options, "dual_color_blend_by_location");
instance->drirc.legacy_sparse_binding = driQueryOptionb(&instance->drirc.options, "radv_legacy_sparse_binding");
instance->drirc.force_pstate_peak_gfx11_dgpu =
-1
View File
@@ -64,7 +64,6 @@ struct radv_instance {
bool ssbo_non_uniform;
bool flush_before_timestamp_write;
bool force_rt_wave64;
bool dual_color_blend_by_location;
bool legacy_sparse_binding;
bool force_pstate_peak_gfx11_dgpu;
bool clear_lds;
-1
View File
@@ -219,7 +219,6 @@ radv_physical_device_init_cache_key(struct radv_physical_device *pdev)
key->disable_aniso_single_level = instance->drirc.disable_aniso_single_level && pdev->info.gfx_level < GFX8;
key->disable_shrink_image_store = instance->drirc.disable_shrink_image_store;
key->disable_sinking_load_input_fs = instance->drirc.disable_sinking_load_input_fs;
key->dual_color_blend_by_location = instance->drirc.dual_color_blend_by_location;
key->emulate_rt = !!(instance->perftest_flags & RADV_PERFTEST_EMULATE_RT);
key->ge_wave32 = pdev->ge_wave_size == 32;
key->invariant_geom = !!(instance->debug_flags & RADV_DEBUG_INVARIANT_GEOM);
-1
View File
@@ -50,7 +50,6 @@ struct radv_physical_device_cache_key {
uint32_t disable_aniso_single_level : 1;
uint32_t disable_shrink_image_store : 1;
uint32_t disable_sinking_load_input_fs : 1;
uint32_t dual_color_blend_by_location : 1;
uint32_t emulate_rt : 1;
uint32_t ge_wave32 : 1;
uint32_t invariant_geom : 1;
-2
View File
@@ -2593,8 +2593,6 @@ radv_graphics_shaders_compile(struct radv_device *device, struct vk_pipeline_cac
if (!stages[s].nir) {
struct radv_spirv_to_nir_options options = {
.lower_view_index_to_zero = !gfx_state->has_multiview_view_index,
.fix_dual_src_mrt1_export =
gfx_state->ps.epilog.mrt0_is_dual_src && instance->drirc.dual_color_blend_by_location,
.lower_view_index_to_device_index = stages[s].key.view_index_from_device_index,
};
blake3_hash key;
-21
View File
@@ -306,24 +306,6 @@ radv_compiler_debug(void *private_data, enum aco_compiler_debug_level level, con
vk_debug_report(&instance->vk, vk_flags[level] | VK_DEBUG_REPORT_DEBUG_BIT_EXT, NULL, 0, 0, "radv", message);
}
/* If the shader doesn't have an index=1 output, then assume that it meant for a location=1 to be used. This works on
* some older hardware because the MRT1 target is used for both location=1 and index=1, but GFX11 works differently.
*/
static void
fix_dual_src_mrt1_export(nir_shader *nir)
{
nir_foreach_shader_out_variable (var, nir) {
if (var->data.location == FRAG_RESULT_DATA0 && var->data.index == 1)
return;
}
nir_variable *loc1_var = nir_find_variable_with_location(nir, nir_var_shader_out, FRAG_RESULT_DATA1);
if (loc1_var) {
loc1_var->data.location = FRAG_RESULT_DATA0;
loc1_var->data.index = 1;
}
}
nir_shader *
radv_shader_spirv_to_nir(struct radv_device *device, const struct radv_shader_stage *stage,
const struct radv_spirv_to_nir_options *options, bool is_internal)
@@ -457,9 +439,6 @@ radv_shader_spirv_to_nir(struct radv_device *device, const struct radv_shader_st
NIR_PASS(_, nir, nir_remove_dead_variables,
nir_var_shader_in | nir_var_shader_out | nir_var_system_value | nir_var_mem_shared, &dead_vars_opts);
if (nir->info.stage == MESA_SHADER_FRAGMENT && options->fix_dual_src_mrt1_export)
fix_dual_src_mrt1_export(nir);
/* Variables can make nir_propagate_invariant more conservative
* than it needs to be.
*/
-1
View File
@@ -112,7 +112,6 @@ struct radv_ps_epilog_key {
struct radv_spirv_to_nir_options {
uint32_t lower_view_index_to_zero : 1;
uint32_t fix_dual_src_mrt1_export : 1;
uint32_t lower_view_index_to_device_index : 1;
};
-5
View File
@@ -97,7 +97,6 @@ Application bugs worked around in this file:
<option name="radv_override_uniform_offset_alignment" value="16" />
<option name="radv_disable_shrink_image_store" value="true" />
<option name="radv_invariant_geom" value="true" />
<option name="dual_color_blend_by_location" value="true" />
</application>
<application name="DOOM VFR" application_name_match="DOOM_VFR">
@@ -203,10 +202,6 @@ Application bugs worked around in this file:
<option name="radv_zero_vram" value="true" />
</application>
<application name="Half-Life Alyx" application_name_match="hlvr">
<option name="dual_color_blend_by_location" value="true" />
</application>
<application name="Enshrouded" executable="enshrouded.exe">
<option name="radv_zero_vram" value="true"/>
</application>