radv: fix re-emitting some dynamic states when the previous FS is NULL

If the previous FS is NULL, some dynamic states still need to be
re-emitted.

Doesn't fix anything known.

Cc: mesa-stable
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23494>
(cherry picked from commit 00968f38ca)
This commit is contained in:
Samuel Pitoiset 2023-06-07 10:26:38 +02:00 committed by Eric Engestrom
parent d1f7f07fcb
commit 2c81fbf6d9
2 changed files with 3 additions and 3 deletions

View file

@ -409,7 +409,7 @@
"description": "radv: fix re-emitting some dynamic states when the previous FS is NULL",
"nominated": true,
"nomination_type": 0,
"resolution": 0,
"resolution": 1,
"main_sha": null,
"because_sha": null
},

View file

@ -6577,11 +6577,11 @@ radv_bind_fragment_shader(struct radv_cmd_buffer *cmd_buffer, const struct radv_
}
/* Re-emit the conservative rasterization mode because inner coverage is different. */
if (previous_ps && previous_ps->info.ps.reads_fully_covered != ps->info.ps.reads_fully_covered)
if (!previous_ps || previous_ps->info.ps.reads_fully_covered != ps->info.ps.reads_fully_covered)
cmd_buffer->state.dirty |= RADV_CMD_DIRTY_DYNAMIC_CONSERVATIVE_RAST_MODE;
if (gfx_level >= GFX10_3 &&
previous_ps && previous_ps->info.ps.reads_sample_mask_in != ps->info.ps.reads_sample_mask_in)
(!previous_ps || previous_ps->info.ps.reads_sample_mask_in != ps->info.ps.reads_sample_mask_in))
cmd_buffer->state.dirty |= RADV_CMD_DIRTY_DYNAMIC_RASTERIZATION_SAMPLES;
if (cmd_buffer->state.ms.sample_shading_enable != ps->info.ps.uses_sample_shading ||