From 6225b9111f290e057e68da17ffef961f33c3b3e6 Mon Sep 17 00:00:00 2001 From: Tapani Pihlajakuja Date: Fri, 16 Jan 2026 13:10:43 +0200 Subject: [PATCH] Fix basop issue 2327 by correcting loop end condition. --- lib_com/options.h | 1 + lib_rend/ivas_omasa_ana_fx.c | 8 ++++++++ 2 files changed, 9 insertions(+) diff --git a/lib_com/options.h b/lib_com/options.h index ffac0ff4e..38ca61c41 100644 --- a/lib_com/options.h +++ b/lib_com/options.h @@ -101,6 +101,7 @@ #define HARM_CORECODER_UPDT /* VA: basop issue 2342: Remove duplicated code in core-coder common update functions */ #define HARM_CORE_SW /* VA: basop issue 2314: Remove duplicated code in the core switching */ #define HARM_PREPROC /* VA: basop issue 2339: Remove duplicated code in the core-coder DTX */ +#define FIX_BASOP_2327_WRONG_LOOP_END /* Nokia: basop inssue 2327: Correct loop end to solve MSAN error */ /* #################### End BE switches ################################## */ diff --git a/lib_rend/ivas_omasa_ana_fx.c b/lib_rend/ivas_omasa_ana_fx.c index b1405a309..c3ce78d64 100644 --- a/lib_rend/ivas_omasa_ana_fx.c +++ b/lib_rend/ivas_omasa_ana_fx.c @@ -719,7 +719,11 @@ static void ivas_omasa_dmx_fx( } max_e = in_e[0]; move16(); +#ifdef FIX_BASOP_2327_WRONG_LOOP_END + FOR( l = 1; l < input_frame; l++ ) +#else FOR( l = 1; l < L_FRAME48k; l++ ) +#endif { IF( LT_16( max_e, in_e[l] ) ) { @@ -728,7 +732,11 @@ static void ivas_omasa_dmx_fx( } } +#ifdef FIX_BASOP_2327_WRONG_LOOP_END + FOR( l = 0; l < input_frame; l++ ) +#else FOR( l = 0; l < L_FRAME48k; l++ ) +#endif { data_out_f_fx[j][l] = L_shr( data_out_f_fx[j][l], sub( max_e, in_e[l] ) ); // exponent: max_e, Q: ( 15 - max_e ) move32(); -- GitLab