Loading lib_dec/igf_dec_fx.c +17 −14 Original line number Diff line number Diff line Loading @@ -2905,7 +2905,6 @@ static void IGF_getWhiteSpectralData_ivas( Word16 tmp_e; Word16 out_e_arr[IGF_START_MX + MAX_IGF_SFB_LEN]; Word16 max_out_e; Word64 window_sum; assert( LT_16( stop, IGF_START_MX + MAX_IGF_SFB_LEN ) ); /* inits */ Loading @@ -2931,18 +2930,15 @@ static void IGF_getWhiteSpectralData_ivas( ak_e = add( tmp_e, sub( shl( sub( in_e, s_l ), 1 ), 15 ) ); // tmp_e + 2 * (in_e - s_l) - 15 ak_e = sub( ak_e, 1 ); window_sum = 0; FOR( i = start; i < stop - level; i++ ) { Word64 temp = 0; move64(); FOR( j = start - level; j < start + level; j++ ) FOR( j = i - level; j < i + level + 1; j++ ) { window_sum = W_mac_32_32( window_sum, in[j], in[j] ); temp = W_mac_32_32( temp, in[j], in[j] ); } FOR( i = start; i < stop - level; i++ ) { window_sum = W_mac_32_32( window_sum, in[i + level], in[i + level] ); /* add the right one */ ak = Mult_32_16( W_shl_sat_l( window_sum, shift ), quo ); // add( shl( level, 1 ), 1 ), &tmp_e ) ); window_sum = W_sub( window_sum, W_mult_32_32( in[i - level], in[i - level] ) ); /* subtract the left one */ ak = Mult_32_16( W_shl_sat_l( temp, shift ), quo ); // add( shl( level, 1 ), 1 ), &tmp_e ) ); n = sub( ak_e, norm_l( ak ) ); Loading @@ -2955,8 +2951,15 @@ static void IGF_getWhiteSpectralData_ivas( FOR( ; i < stop; i++ ) { ak = L_deposit_h( BASOP_Util_Divide3216_Scale( W_shl_sat_l( window_sum, shift ), sub( stop, sub( i, level ) ), &tmp_e ) ); window_sum = W_sub( window_sum, W_mult_32_32( in[i - level], in[i - level] ) ); /* subtract the left one */ Word64 temp = 0; move64(); FOR( j = i - level; j < stop; j++ ) { temp = W_mac_32_32( temp, in[j], in[j] ); } ak = L_deposit_h( BASOP_Util_Divide3216_Scale( W_shl_sat_l( temp, shift ), sub( stop, sub( i, level ) ), &tmp_e ) ); ak_e = add( tmp_e, eff_e ); // tmp_e + 2 * (in_e - s_l) - 15 n = sub( ak_e, add( norm_l( ak ), 1 ) ); n = shr( n, 1 ); Loading Loading
lib_dec/igf_dec_fx.c +17 −14 Original line number Diff line number Diff line Loading @@ -2905,7 +2905,6 @@ static void IGF_getWhiteSpectralData_ivas( Word16 tmp_e; Word16 out_e_arr[IGF_START_MX + MAX_IGF_SFB_LEN]; Word16 max_out_e; Word64 window_sum; assert( LT_16( stop, IGF_START_MX + MAX_IGF_SFB_LEN ) ); /* inits */ Loading @@ -2931,18 +2930,15 @@ static void IGF_getWhiteSpectralData_ivas( ak_e = add( tmp_e, sub( shl( sub( in_e, s_l ), 1 ), 15 ) ); // tmp_e + 2 * (in_e - s_l) - 15 ak_e = sub( ak_e, 1 ); window_sum = 0; FOR( i = start; i < stop - level; i++ ) { Word64 temp = 0; move64(); FOR( j = start - level; j < start + level; j++ ) FOR( j = i - level; j < i + level + 1; j++ ) { window_sum = W_mac_32_32( window_sum, in[j], in[j] ); temp = W_mac_32_32( temp, in[j], in[j] ); } FOR( i = start; i < stop - level; i++ ) { window_sum = W_mac_32_32( window_sum, in[i + level], in[i + level] ); /* add the right one */ ak = Mult_32_16( W_shl_sat_l( window_sum, shift ), quo ); // add( shl( level, 1 ), 1 ), &tmp_e ) ); window_sum = W_sub( window_sum, W_mult_32_32( in[i - level], in[i - level] ) ); /* subtract the left one */ ak = Mult_32_16( W_shl_sat_l( temp, shift ), quo ); // add( shl( level, 1 ), 1 ), &tmp_e ) ); n = sub( ak_e, norm_l( ak ) ); Loading @@ -2955,8 +2951,15 @@ static void IGF_getWhiteSpectralData_ivas( FOR( ; i < stop; i++ ) { ak = L_deposit_h( BASOP_Util_Divide3216_Scale( W_shl_sat_l( window_sum, shift ), sub( stop, sub( i, level ) ), &tmp_e ) ); window_sum = W_sub( window_sum, W_mult_32_32( in[i - level], in[i - level] ) ); /* subtract the left one */ Word64 temp = 0; move64(); FOR( j = i - level; j < stop; j++ ) { temp = W_mac_32_32( temp, in[j], in[j] ); } ak = L_deposit_h( BASOP_Util_Divide3216_Scale( W_shl_sat_l( temp, shift ), sub( stop, sub( i, level ) ), &tmp_e ) ); ak_e = add( tmp_e, eff_e ); // tmp_e + 2 * (in_e - s_l) - 15 n = sub( ak_e, add( norm_l( ak ), 1 ) ); n = shr( n, 1 ); Loading