From 7985598f04c553d362ff11d726e71d768eb98683 Mon Sep 17 00:00:00 2001 From: nilfm Date: Wed, 1 Nov 2023 12:41:19 +0000 Subject: [PATCH] Fix vif_neon segmentation fault --- libvmaf/src/feature/arm64/vif_neon.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/libvmaf/src/feature/arm64/vif_neon.c b/libvmaf/src/feature/arm64/vif_neon.c index 60ecb8eed..d9412fa77 100644 --- a/libvmaf/src/feature/arm64/vif_neon.c +++ b/libvmaf/src/feature/arm64/vif_neon.c @@ -360,8 +360,8 @@ void vif_subsample_rd_8_neon(VifBuffer buf, unsigned int w, unsigned int h) accum_ref += fcoeff * buf.tmp.ref_convol[jj_check]; accum_dis += fcoeff * buf.tmp.dis_convol[jj_check]; } - buf.mu1[i * i_dst_stride + j] = (uint16_t)(accum_ref >> 16); - buf.mu2[i * i_dst_stride + j] = (uint16_t)(accum_dis >> 16); + buf.mu1[i_dst_stride + j] = (uint16_t)(accum_ref >> 16); + buf.mu2[i_dst_stride + j] = (uint16_t)(accum_dis >> 16); } } @@ -496,8 +496,8 @@ void vif_subsample_rd_16_neon(VifBuffer buf, unsigned int w, unsigned int h, int accum_ref += fcoeff * buf.tmp.ref_convol[jj_check]; accum_dis += fcoeff * buf.tmp.dis_convol[jj_check]; } - buf.mu1[i * i_dst_stride + j] = (uint16_t)(accum_ref >> 16); - buf.mu2[i * i_dst_stride + j] = (uint16_t)(accum_dis >> 16); + buf.mu1[i_dst_stride + j] = (uint16_t)(accum_ref >> 16); + buf.mu2[i_dst_stride + j] = (uint16_t)(accum_dis >> 16); } }