radv: remove an useless check when emitting the index buffer

index_type is uint32_t, so this checks is always FALSE.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/41159>
This commit is contained in:
Samuel Pitoiset 2026-04-24 16:10:00 +02:00 committed by Marge Bot
parent 4f2de63a27
commit dc816ce4ac

View file

@ -5863,11 +5863,6 @@ radv_emit_index_buffer(struct radv_cmd_buffer *cmd_buffer)
uint32_t max_index_count = state->max_index_count;
uint64_t index_va = state->index_va;
/* With indirect generated commands the index buffer bind may be part of the
* indirect command buffer, in which case the app may not have bound any yet. */
if (state->index_type < 0)
return;
/* Handle indirect draw calls with NULL index buffer if the GPU doesn't support them. */
if (!max_index_count && pdev->info.has_zero_index_buffer_bug) {
radv_handle_zero_index_buffer_bug(cmd_buffer, &index_va, &max_index_count);