From: Corentin Noël Date: Mon, 11 Sep 2023 14:53:03 +0000 (+0200) Subject: llvmpipe: make sure to initialize the lp_setup_context slots with the default values X-Git-Tag: upstream/23.3.3~2117 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=010147cd642cf8a5213b5a368b16a8299b04e590;p=platform%2Fupstream%2Fmesa.git llvmpipe: make sure to initialize the lp_setup_context slots with the default values As 0 is an actual valid value, this can lead to issues when we actually want to use them. This fixes `spec@arb_cull_distance@basic-cull-3` crashes for instance. Cc: mesa-stable Signed-off-by: Corentin Noël Reviewed-by: Mike Blumenkrantz Part-of: --- diff --git a/src/gallium/drivers/llvmpipe/ci/llvmpipe-fails.txt b/src/gallium/drivers/llvmpipe/ci/llvmpipe-fails.txt index 4793cd3..8b584ca 100644 --- a/src/gallium/drivers/llvmpipe/ci/llvmpipe-fails.txt +++ b/src/gallium/drivers/llvmpipe/ci/llvmpipe-fails.txt @@ -198,6 +198,3 @@ spec@intel_shader_atomic_float_minmax@execution@ssbo-atomiccompswap-float-nan,Cr spec@intel_shader_atomic_float_minmax@execution@ssbo-atomiccompswap-float-negative-zero,Crash spec@!opengl 1.1@line-flat-clip-color,Fail spec@intel_shader_atomic_float_minmax@execution@shared-atomiccompswap-float,Crash -spec@arb_cull_distance@basic-cull-3,Crash -spec@arb_cull_distance@basic-cull-4,Crash -spec@arb_cull_distance@vs-cull-distance-vertex-outside-cull-volume,Crash diff --git a/src/gallium/drivers/llvmpipe/lp_setup.c b/src/gallium/drivers/llvmpipe/lp_setup.c index 9b58e71..26081a4 100644 --- a/src/gallium/drivers/llvmpipe/lp_setup.c +++ b/src/gallium/drivers/llvmpipe/lp_setup.c @@ -1336,6 +1336,11 @@ lp_setup_create(struct pipe_context *pipe, lp_setup_init_vbuf(setup); + setup->psize_slot = -1; + setup->viewport_index_slot = -1; + setup->layer_slot = -1; + setup->face_slot = -1; + /* Used only in update_state(): */ setup->pipe = pipe; diff --git a/src/gallium/drivers/virgl/ci/virpipe-gl-fails.txt b/src/gallium/drivers/virgl/ci/virpipe-gl-fails.txt index ec4661c..47b73dd 100644 --- a/src/gallium/drivers/virgl/ci/virpipe-gl-fails.txt +++ b/src/gallium/drivers/virgl/ci/virpipe-gl-fails.txt @@ -678,6 +678,3 @@ spec@arb_viewport_array@display-list,Fail spec@arb_gl_spirv@execution@ssbo@unsized-array,Fail spec@arb_pipeline_statistics_query@arb_pipeline_statistics_query-frag,Fail spec@!opengl 1.1@line-flat-clip-color,Fail -spec@arb_cull_distance@basic-cull-3,Crash -spec@arb_cull_distance@basic-cull-4,Crash -spec@arb_cull_distance@vs-cull-distance-vertex-outside-cull-volume,Crash