Commit 5ee8decc authored by Mohammadreza Naghibzadeh's avatar Mohammadreza Naghibzadeh
Browse files

Replace extract_l(L_shr(...)) with extract_h(L_shl(...))

parent 2a4d33a2
Loading
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -800,8 +800,8 @@ ivas_error ivas_param_mc_dec_reconfig_fx(
                        term_m = Mpy_32_16_1( term_m, parameter_band_mapping.source_band_factor_fx[new_param_band_idx][source_param_idx] ); /* * factor (Q15) */
                        acc_m = BASOP_Util_Add_Mant32Exp( acc_m, acc_e, term_m, term_e, &acc_e );
                    }
                    /* log2 term is Q25; Mpy_32_16_1( Q25, Q13 ) -> Q(25+13-15) = Q23; L_shr( Q23, 15 ) -> Q8 */
                    *p_ild_new_fx = extract_l( L_shr( Mpy_32_16_1( L_add( BASOP_Util_Log2( acc_m ), L_shl( acc_e, Q25 ) ), 24660 /*10*log10(2) in Q13*/ ), 15 ) ); // Q8
                    /* log2 term is Q25; Mpy_32_16_1( Q25, Q13 ) -> Q(25+13-15) = Q23; L_shl( Q23, 1 ) -> Q24 - Q16 = Q8 */
                    *p_ild_new_fx = extract_h( L_shl( Mpy_32_16_1( L_add( BASOP_Util_Log2( acc_m ), L_shl( acc_e, Q25 ) ), 24660 /*10*log10(2) in Q13*/ ), 1 ) ); // Q8
                    move16();
#else
                    *p_ild_new_fx = 0;