When stencil is enabled and it isn't non-op, Early-Z must be disabled.
The condition that checks this for stencil[0] is correct, but the one
for stencil[1] is wrong: it uses an "and" instead of "or" condition.
This affects dEQP-GLES3.functional.fragment_ops.interaction.basic_shader.14
Signed-off-by: Juan A. Suarez Romero <jasuarez@igalia.com>
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22081>
(cso->stencil[0].zfail_op != PIPE_STENCIL_OP_KEEP ||
cso->stencil[0].func != PIPE_FUNC_ALWAYS ||
(cso->stencil[1].enabled &&
- (cso->stencil[1].zfail_op != PIPE_STENCIL_OP_KEEP &&
+ (cso->stencil[1].zfail_op != PIPE_STENCIL_OP_KEEP ||
cso->stencil[1].func != PIPE_FUNC_ALWAYS)))) {
so->ez_state = V3D_EZ_DISABLED;
}