mesa/src/compiler/nir/tests
Sviatoslav Peleshko 6b0bfdfa9e nir: Use alu source components count in nir_alu_srcs_negative_equal
When we use source from ALU instruction directly, the default swizzle array
should be populated with the same amount of components as the src has.

Otherwise, if we use nir_ssa_alu_instr_src_components, it can return
the destination components count that is lower than component index
actually used in that source. This can lead to false equality
between 0 (uninitialized) and 0 (.x) in swizzle comparison below.

Fixes: c6ee46a7 ("nir: Add nir_alu_srcs_negative_equal")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8704
Signed-off-by: Sviatoslav Peleshko <sviatoslav.peleshko@globallogic.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22655>
2024-01-17 08:05:30 +00:00
..
algebraic_parser_test.py nir/algebraic: Move relocations for expression conds to a table. 2021-12-07 07:09:00 +00:00
algebraic_tests.cpp nir/algebraic: optimize vkd3d-proton's MSAD 2024-01-05 18:55:22 +00:00
builder_tests.cpp nir: Use glsl_type C helpers 2023-12-22 06:44:23 -08:00
comparison_pre_tests.cpp nir: Use alu source components count in nir_alu_srcs_negative_equal 2024-01-17 08:05:30 +00:00
control_flow_tests.cpp nir/tests: Refactor boilerplate into a common header 2023-07-24 11:44:46 +00:00
core_tests.cpp nir: nir_foreach_ssa_def() -> nir_foreach_def() 2023-08-13 17:12:52 +00:00
dce_tests.cpp nir: Take a nir_def * in nir_phi_instr_add_src() 2023-08-18 01:00:14 +00:00
load_store_vectorizer_tests.cpp nir: Drop nir_dest 2023-08-14 21:22:53 +00:00
loop_analyze_tests.cpp nir/loop_analyze: Don't test non-positive iterations count 2023-12-19 12:53:52 +00:00
loop_unroll_tests.cpp nir/tests: Reenable tests that failed on big-endian 2024-01-10 21:47:30 +00:00
lower_alu_width_tests.cpp nir: Drop nir_dest 2023-08-14 21:22:53 +00:00
mod_analysis_tests.cpp nir s/nir_get_ssa_scalar/nir_get_scalar/ 2023-08-15 17:44:27 +00:00
negative_equal_tests.cpp nir: Drop "SSA" from NIR language 2023-08-12 16:44:41 -04:00
nir_test.h nir/algebraic: optimize vkd3d-proton's MSAD 2024-01-05 18:55:22 +00:00
opt_if_tests.cpp nir: Take a nir_def * in nir_phi_instr_add_src() 2023-08-18 01:00:14 +00:00
opt_peephole_select.cpp nir/opt_peephole_select: handle speculative ubo loads 2024-01-03 20:02:25 +00:00
opt_shrink_vectors_tests.cpp nir: Take a nir_def * in nir_phi_instr_add_src() 2023-08-18 01:00:14 +00:00
range_analysis_tests.cpp nir: Take a nir_def * in nir_phi_instr_add_src() 2023-08-18 01:00:14 +00:00
serialize_tests.cpp nir: Drop "SSA" from NIR language 2023-08-12 16:44:41 -04:00
vars_tests.cpp nir: Use glsl_type C helpers 2023-12-22 06:44:23 -08:00