Commit fd2e4320 authored by vaillancour's avatar vaillancour
Browse files

Basop fix for Hi-level content FEC

parent da3bd7a8
Loading
Loading
Loading
Loading
Loading
+10 −1
Original line number Diff line number Diff line
@@ -3341,12 +3341,21 @@ void ifft3_fx(const Word16 Z[], Word16 X[], const Word16 n)
    pX = X;
    FOR (i = 0; i < m; i++)
    {
#ifdef BASOP_NOGLOB
        *pX++ = shl_sat( mult_r( *y0++, FFT3_ONE_THIRD ), 1 );
        move16();
        *pX++ = shl_sat( mult_r( *y1++, FFT3_ONE_THIRD ), 1 );
        move16();
        *pX++ = shl_sat( mult_r( *y2++, FFT3_ONE_THIRD ), 1 );
        move16();
#else
        *pX++ = shl( mult_r( *y0++, FFT3_ONE_THIRD ), 1 );
        move16();
        *pX++ = shl(mult_r(*y1++, FFT3_ONE_THIRD), 1);
        move16();
        *pX++ = shl(mult_r(*y2++, FFT3_ONE_THIRD), 1);
        move16();
#endif
    }

    return;
+10 −3
Original line number Diff line number Diff line
@@ -3319,7 +3319,11 @@ void fir_dwn_fx(

        FOR (j = 1; j <= i; j++)
        {
#ifdef BASOP_NOGLOB
            s = L_mac0_sat( s, *ptr_h++, *ptr_x-- );
#else
            s = L_mac0( s, *ptr_h++, *ptr_x-- );
#endif
        }

#ifdef BASOP_NOGLOB
@@ -3633,8 +3637,11 @@ void sin_cos_est_fx(Word32 phi, Word16 *cosfreq, Word16 *sinfreq)
    tmp = L_shl(Mult_32_16(delta, cosb),1); /*Q31 */
    sinv = L_add(L_deposit_h(sinb), tmp);
    tmp = L_shl(Mult_32_16(delta, sinb),1); /*Q31 */
#ifdef BASOP_NOGLOB
    cosv = L_sub_sat( L_deposit_h( cosb ), tmp );
#else
    cosv = L_sub( L_deposit_h( cosb ), tmp );

#endif
#ifdef BASOP_NOGLOB
    *sinfreq = round_fx_sat(sinv);
    *cosfreq = round_fx_sat(cosv);
+5 −1
Original line number Diff line number Diff line
@@ -379,7 +379,11 @@ void FEC_scale_syn_fx(
                /*rr0 = dotp( h1, h1, L_FRAME/2-1 ) + 0.1f;*/
                /*rr1 = dotp( h1, h1+1, L_FRAME/2-1 );*/
                /*tilt = rr1 / rr0;*/
#ifdef BASOP_NOGLOB
                tilt = extract_h( L_shl_sat( get_gain( h1 + 1, h1, L_FRAME / 2 - 1 ), 15 ) );
#else
                tilt = extract_h( L_shl( get_gain( h1 + 1, h1, L_FRAME / 2 - 1 ), 15 ) );
#endif
                test();
                test();
                test();
+6 −1
Original line number Diff line number Diff line
@@ -317,8 +317,13 @@ ivas_error decod_gen_voic_fx(
        prev_spch_nrg = L_deposit_l(1);
        FOR( i=0; i<rint_bfi_pitch; i++ )
        {
#ifdef BASOP_NOGLOB
            prev_res_nrg = L_mac0_sat( prev_res_nrg, *p_exc, *p_exc );   /* 2*st_fx->prev_Q_exc_fr */
            prev_spch_nrg = L_mac0_sat(prev_spch_nrg, *p_syn, *p_syn); /* 2*st_fx->prev_Q_syn_fr */
#else
            prev_res_nrg = L_mac0( prev_res_nrg, *p_exc, *p_exc );   /* 2*st_fx->prev_Q_exc_fr */
            prev_spch_nrg = L_mac0(prev_spch_nrg, *p_syn, *p_syn); /* 2*st_fx->prev_Q_syn_fr */
#endif
            p_exc++;
            p_syn++;
        }
+5 −1
Original line number Diff line number Diff line
@@ -854,7 +854,11 @@ PMTE()
#endif
        FOR (i = hTonalMDCTConc->nSamplesCore; i < nSamples; i++)
        {
#ifdef BASOP_NOGLOB
            powerSpectrum[i] = L_shl_sat( Mpy_32_16_1( powerSpectrum[i], invScaleFactors[FDNS_NPTS - 1] ), invScaleFactors_exp[FDNS_NPTS - 1] );
#else
            powerSpectrum[i] = L_shl( Mpy_32_16_1( powerSpectrum[i], invScaleFactors[FDNS_NPTS - 1] ), invScaleFactors_exp[FDNS_NPTS - 1] );
#endif
            move32();
        }