Remove leftover dead code.
Fix defect reported by Coverity Scan.
Logically dead code (DEADCODE)
dead_error_line: Execution cannot reach this statement: return;.
Fixes: bdf93f4e3b
("v3dv/cmd_buffer: return early for draw commands if there is nothing to draw")
Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9890>
This commit is contained in:
parent
3d1022382c
commit
ddab996589
|
@ -4484,16 +4484,13 @@ v3dv_CmdDrawIndirect(VkCommandBuffer commandBuffer,
|
|||
uint32_t drawCount,
|
||||
uint32_t stride)
|
||||
{
|
||||
/* drawCount is the number of draws to execute, and can be zero. */
|
||||
if (drawCount == 0)
|
||||
return;
|
||||
|
||||
V3DV_FROM_HANDLE(v3dv_cmd_buffer, cmd_buffer, commandBuffer);
|
||||
V3DV_FROM_HANDLE(v3dv_buffer, buffer, _buffer);
|
||||
|
||||
/* drawCount is the number of draws to execute, and can be zero. */
|
||||
if (drawCount == 0)
|
||||
return;
|
||||
|
||||
cmd_buffer_emit_pre_draw(cmd_buffer);
|
||||
|
||||
struct v3dv_job *job = cmd_buffer->state.job;
|
||||
|
@ -4522,16 +4519,13 @@ v3dv_CmdDrawIndexedIndirect(VkCommandBuffer commandBuffer,
|
|||
uint32_t drawCount,
|
||||
uint32_t stride)
|
||||
{
|
||||
/* drawCount is the number of draws to execute, and can be zero. */
|
||||
if (drawCount == 0)
|
||||
return;
|
||||
|
||||
V3DV_FROM_HANDLE(v3dv_cmd_buffer, cmd_buffer, commandBuffer);
|
||||
V3DV_FROM_HANDLE(v3dv_buffer, buffer, _buffer);
|
||||
|
||||
/* drawCount is the number of draws to execute, and can be zero. */
|
||||
if (drawCount == 0)
|
||||
return;
|
||||
|
||||
cmd_buffer_emit_pre_draw(cmd_buffer);
|
||||
|
||||
struct v3dv_job *job = cmd_buffer->state.job;
|
||||
|
|
Loading…
Reference in New Issue