mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-24 11:00:11 +01:00
intel/vec4: fix valgrind errors with vf_values array
Fixes valgrind errors introduced since commita8ec4082. Closes: https://gitlab.freedesktop.org/mesa/mesa/issues/2346 Fixes:a8ec4082("nir+vtn: vec8+vec16 support") Signed-off-by: Tapani Pälli <tapani.palli@intel.com> Reviewed-by: Matt Turner <mattst88@gmail.com> Tested-by: Marge Bot <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3691> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3691>
This commit is contained in:
parent
1572e8f3e1
commit
da76dfb515
1 changed files with 2 additions and 1 deletions
|
|
@ -1030,7 +1030,8 @@ try_immediate_source(const nir_alu_instr *instr, src_reg *op,
|
|||
} else {
|
||||
uint8_t vf_values[4] = { 0, 0, 0, 0 };
|
||||
|
||||
for (unsigned i = 0; i < NIR_MAX_VEC_COMPONENTS; i++) {
|
||||
for (unsigned i = 0; i < ARRAY_SIZE(vf_values); i++) {
|
||||
|
||||
if (op[idx].abs)
|
||||
f[i] = fabs(f[i]);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue