Commit 104a9f52 authored by Fabian Bauer's avatar Fabian Bauer
Browse files

lib_com/lpc_tools_fx.c

lib_com/lsf_tools_fx.c
lib_com/lsp_conv_poly_fx.c
lib_com/math_op.c
lib_com/modif_fs_fx.c : completed overflow op replacement and fix warnings
parent d1e2bf27
Loading
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -823,7 +823,11 @@ Word16 E_LPC_lev_dur_stab_ivas_fx( const Word16 Rh[], const Word16 Rl[], Word16
        L_Extract( t2, &Ah[i], &Al[i] ); /* An[i] in Q27                   */

        /* Alpha = Alpha * (1-K**2) */
#ifdef ISSUE_1836_replace_overflow_libcom
        t1 = L_mult_sat( Kh, Kh ); /* K*K      in Q31 */          //??sat
#else
        t1 = L_mult_o( Kh, Kh, &Overflow ); /* K*K      in Q31 */
#endif
        t0 = L_mac( t1, mult( Kh, Kl ), 2 );
        t0 = L_abs( t0 );                       /* Some case <0 !! */
        t0 = L_sub( (Word32) 0x7fffffffL, t0 ); /* 1 - K*K  in Q31 */
@@ -859,7 +863,11 @@ Word16 E_LPC_lev_dur_stab_ivas_fx( const Word16 Rh[], const Word16 Rl[], Word16
    FOR( i = 1; i <= order; i++ )
    {
        t0 = L_Comp( Ah[i], Al[i] );
#ifdef ISSUE_1836_replace_overflow_libcom
        A[i] = round_fx_sat( L_shl_sat( t0, k ) );  //??sat
#else
        A[i] = round_fx_o( L_shl_o( t0, k, &Overflow ), &Overflow );
#endif
        move16();
    }

+3 −3
Original line number Diff line number Diff line
@@ -1875,9 +1875,9 @@ void a2rc_fx( const Word16 *a, /* i: can be any Q */
        {
            L_tmp1 = L_mult( denom_mant, f_fx[j] ); /* denom*f[j]. Q15*Q12 = Q28 (floating with exp) */
#ifdef ISSUE_1836_replace_overflow_libcom
            L_tmp1 = L_mac_sat( L_tmp1, tmp, f_fx[j], &Overflow ); /* denom*f[j]+km*denom*f[j] in Q28 (floating with exp) */ //??sat
            L_tmp1 = L_mac_sat( L_tmp1, tmp, f_fx[j] ); /* denom*f[j]+km*denom*f[j] in Q28 (floating with exp) */ //??sat
            L_tmp1 = L_shr_sat( L_tmp1, exp ); /* bringing to true Q28 */                                         //??sat
            f_fx[j] = round_fx_sat( L_tmp1, &Overflow ); /* extracting in q_a */                                             //??sat
            f_fx[j] = round_fx_sat( L_tmp1 ); /* extracting in q_a */                                             //??sat
            move16();
#else
            L_tmp1 = L_mac_o( L_tmp1, tmp, f_fx[j], &Overflow ); /* denom*f[j]+km*denom*f[j] in Q28 (floating with exp) */
+2 −2
Original line number Diff line number Diff line
@@ -336,7 +336,7 @@ static Word32 b_inv_sq(
    Word16 m_den, exp_den;
    Word16 div_out;
    Word32 Ltmp;
#ifdef ISSUE_1836_replace_overflow_libcom
#ifndef ISSUE_1836_replace_overflow_libcom
#ifdef BASOP_NOGLOB_DECLARE_LOCAL
    Flag Overflow = 0;
#endif
@@ -373,7 +373,7 @@ static Word32 inv_pow(
    Word32 mh;
    UWord16 ml;
    Word32 r0, s0;
#ifdef ISSUE_1836_replace_overflow_libcom
#ifndef ISSUE_1836_replace_overflow_libcom
#ifdef BASOP_NOGLOB_DECLARE_LOCAL
    Flag Overflow = 0;
#endif
+23 −7
Original line number Diff line number Diff line
@@ -228,20 +228,30 @@ Word32 Energy_scale( /* (o) : Q31: normalized result (1 < val
{
    Word16 i, sft, tmp;
    Word32 L_sum;
#ifndef ISSUE_1836_replace_overflow_libcom
#ifdef BASOP_NOGLOB_DECLARE_LOCAL
    Flag Overflow = 0;
#endif
#endif


    L_sum = 0; /* just to avoid superflous compiler warning about uninitialized use of L_sum */

    IF( expi == 0 )
    {
#ifdef ISSUE_1836_replace_overflow_libcom
        L_sum = L_mac_sat( 1, x[0], x[0] );         //??sat
        FOR( i = 1; i < lg; i++ )
        {
            L_sum = L_mac_sat( L_sum, x[i], x[i] ); //??sat
        }
#else
        L_sum = L_mac_o( 1, x[0], x[0], &Overflow );
        FOR( i = 1; i < lg; i++ )
        {
            L_sum = L_mac_o( L_sum, x[i], x[i], &Overflow );
        }
#endif
    }
    IF( expi < 0 )
    {
@@ -251,26 +261,32 @@ Word32 Energy_scale( /* (o) : Q31: normalized result (1 < val
        FOR( i = 1; i < lg; i++ )
        {
            tmp = mult_r( x[i], sft );
#ifdef ISSUE_1836_replace_overflow_libcom
            L_sum = L_mac_sat( L_sum, tmp, tmp );     //??sat
#else
            L_sum = L_mac_o( L_sum, tmp, tmp, &Overflow );
#endif
        }
    }
    IF( expi > 0 )
    {
#ifdef ISSUE_1796_replace_shl_o
        tmp = shl_sat( x[0], expi );
#ifdef ISSUE_1836_replace_overflow_libcom
        tmp = shl_sat( x[0], expi );                  //??sat
        L_sum = L_mac_sat( 1, tmp, tmp );             //??sat
        FOR( i = 1; i < lg; i++ )
        {
            tmp = shl_sat( x[i], expi );          //??sat
            L_sum = L_mac_sat( L_sum, tmp, tmp ); //??sat
        }
#else
        tmp = shl_o( x[0], expi, &Overflow );
#endif
        L_sum = L_mac_o( 1, tmp, tmp, &Overflow );
        FOR( i = 1; i < lg; i++ )
        {
#ifdef ISSUE_1796_replace_shl_o
            tmp = shl_sat( x[i], expi );
#else
            tmp = shl_o( x[i], expi, &Overflow );
#endif
            L_sum = L_mac_o( L_sum, tmp, tmp, &Overflow );
        }
#endif
    }

    /* Normalize acc in Q31 */
+126 −7
Original line number Diff line number Diff line
@@ -75,7 +75,7 @@ Word16 modify_Fs_ivas_fx( /* o : length of output Q
    Word16 flag_low_order = 0;
    move16();
    Word16 filt_len_tmp;
#ifndef ISSUE_1796_replace_shl_o
#ifndef ISSUE_1836_replace_overflow_libcom
#ifdef BASOP_NOGLOB_DECLARE_LOCAL
    Flag Overflow = 0;
    move32();
@@ -279,8 +279,8 @@ Word16 modify_Fs_ivas_fx( /* o : length of output Q
                test();
                IF( GT_32( fin, 16000 ) && ( EQ_16( lg_out, L_FRAME ) || EQ_16( lg_out, L_FRAME16k ) || EQ_16( lg_out, 512 ) ) )
                {
#ifdef ISSUE_1796_replace_shl_o
                    num_den = shl_sat( num_den, 1 );
#ifdef ISSUE_1836_replace_overflow_libcom
                    num_den = shl_sat( num_den, 1 );        //??sat
#else
                    num_den = shl_o( num_den, 1, &Overflow );
#endif
@@ -364,7 +364,7 @@ Word16 modify_Fs_fx( /* o : length of output Q0 */
    Word16 flag_low_order = 0;
    move16();
    Word16 filt_len_tmp;
#ifndef ISSUE_1796_replace_shl_o
#ifndef ISSUE_1836_replace_overflow_libcom
#ifdef BASOP_NOGLOB_DECLARE_LOCAL
    Flag Overflow = 0;
    move32();
@@ -565,8 +565,8 @@ Word16 modify_Fs_fx( /* o : length of output Q0 */
                if ( GT_32( fin, 16000 ) && ( EQ_16( lg_out, L_FRAME ) || EQ_16( lg_out, L_FRAME16k ) || EQ_16( lg_out, 512 ) ) )
                {
#ifdef BASOP_NOGLOB_DECLARE_LOCAL
#ifdef ISSUE_1796_replace_shl_o
                    num_den = shl_sat( num_den, 1 );
#ifdef ISSUE_1836_replace_overflow_libcom
                    num_den = shl_sat( num_den, 1 );          //??sat
#else
                    num_den = shl_o( num_den, 1, &Overflow );
#endif
@@ -941,9 +941,11 @@ void Decimate_allpass_steep_fx(
    Word32 Lacc, Lacc1;
    Word16 temp1, temp2;
    Word16 sum = 0;
#ifndef ISSUE_1836_replace_overflow_libcom
#ifdef BASOP_NOGLOB_DECLARE_LOCAL
    Flag Overflow = 0;
    move32();
#endif
#endif
    move16();

@@ -954,20 +956,34 @@ void Decimate_allpass_steep_fx(
    {

        Lacc = L_deposit_h( mem[0] );                                     /* Q(16+x)   */
#ifdef ISSUE_1836_replace_overflow_libcom
        Lacc = L_mac_sat( Lacc, AP1_STEEP_FX[0], in_fx[2 * k] );          /* Q(16+x)   */ //??sat
        Lacc1 = L_deposit_h( in_fx[2 * k] );                              /* Q16+Qx    */
        temp1 = extract_h( Lacc );                                        /* Qx        */
        Lacc1 = L_msu_sat( Lacc1, AP1_STEEP_FX[0], temp1 );               /* Q16+Qx    */ //??sat
#else
        Lacc = L_mac_o( Lacc, AP1_STEEP_FX[0], in_fx[2 * k], &Overflow ); /* Q(16+x)   */
        Lacc1 = L_deposit_h( in_fx[2 * k] );                              /* Q16+Qx    */
        temp1 = extract_h( Lacc );                                        /* Qx        */
        Lacc1 = L_msu_o( Lacc1, AP1_STEEP_FX[0], temp1, &Overflow );      /* Q16+Qx    */
#endif
        mem[0] = extract_h( Lacc1 );                                      /* Qx        */
        temp[0] = temp1;
        move16();
        move16();

        Lacc1 = L_deposit_h( mem[1] );                             /* Q16+Qx    */
#ifdef ISSUE_1836_replace_overflow_libcom
        Lacc1 = ( L_mac_sat( Lacc1, AP1_STEEP_FX[1], temp1 ) );    /* Q16+Qx    */  //??sat

        temp2 = extract_h( Lacc1 );                                /* Qx        */
        Lacc = L_msu_sat( Lacc, AP1_STEEP_FX[1], temp2 );          /* Q16+Qx    */  //??sat
#else
        Lacc1 = ( L_mac_o( Lacc1, AP1_STEEP_FX[1], temp1, &Overflow ) ); /* Q16+Qx    */

        temp2 = extract_h( Lacc1 );                                /* Qx        */
        Lacc = L_msu_o( Lacc, AP1_STEEP_FX[1], temp2, &Overflow ); /* Q16+Qx    */
#endif
        mem[1] = extract_h( Lacc );                                /* Qx        */
        temp[1] = temp2;
        move16();
@@ -975,37 +991,67 @@ void Decimate_allpass_steep_fx(


        Lacc = L_deposit_h( mem[ALLPASSSECTIONS_STEEP - 1] );                                                /* Q(16+x)              */
#ifdef ISSUE_1836_replace_overflow_libcom
        out_fx[k] = extract_h( L_mac_sat( Lacc, AP1_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], temp2 ) );          /* Qx format            */   //??sat
        move16();
        mem[ALLPASSSECTIONS_STEEP - 1] = extract_h( L_msu_sat( Lacc1, AP1_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], out_fx[k] ) ); /* Qx  */   //??sat
        move16();
#else
        out_fx[k] = extract_h( L_mac_o( Lacc, AP1_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], temp2, &Overflow ) ); /* Qx format            */
        move16();
        mem[ALLPASSSECTIONS_STEEP - 1] = extract_h( L_msu_o( Lacc1, AP1_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], out_fx[k], &Overflow ) ); /* Qx    */
        move16();
#endif

    }

    /* lower allpass filter chain  */

    Lacc = L_deposit_h( mem[ALLPASSSECTIONS_STEEP] );                                   /*  Q(16+x)     */
#ifdef ISSUE_1836_replace_overflow_libcom
    Lacc = L_mac_sat( Lacc, AP2_STEEP_FX[0], mem[2 * ALLPASSSECTIONS_STEEP] );          /*  Q(16+x)     */  //??sat
    Lacc1 = L_deposit_h( mem[2 * ALLPASSSECTIONS_STEEP] );                              /*  Q(16+x)     */
    temp1 = extract_h( Lacc );                                                          /*  Qx          */
    Lacc1 = L_msu_sat( Lacc1, AP2_STEEP_FX[0], temp1 );                                 /*  Q(16+x)     */  //??sat
#else
    Lacc = L_mac_o( Lacc, AP2_STEEP_FX[0], mem[2 * ALLPASSSECTIONS_STEEP], &Overflow ); /*Q(16+x)   */
    Lacc1 = L_deposit_h( mem[2 * ALLPASSSECTIONS_STEEP] );                              /*  Q(16+x)     */
    temp1 = extract_h( Lacc );                                                          /*  Qx          */
    Lacc1 = L_msu_o( Lacc1, AP2_STEEP_FX[0], temp1, &Overflow );                        /*  Q(16+x)     */
#endif
    mem[ALLPASSSECTIONS_STEEP] = extract_h( Lacc1 );
    temp[0] = temp1;
    move16();

    Lacc1 = L_deposit_h( mem[ALLPASSSECTIONS_STEEP + 1] );       /*   Q(16+x) */
#ifdef ISSUE_1836_replace_overflow_libcom
    Lacc1 = L_mac_sat( Lacc1, AP2_STEEP_FX[1], temp1 );          /*  Q(16+x) */ //??sat
    temp2 = extract_h( Lacc1 );                                  /*  Qx      */
    temp[1] = temp2;
    move16();
    Lacc = L_msu_sat( Lacc, AP2_STEEP_FX[1], temp2 );            /*  Q(16+x) */ //??sat
#else
    Lacc1 = L_mac_o( Lacc1, AP2_STEEP_FX[1], temp1, &Overflow ); /*  Q(16+x) */
    temp2 = extract_h( Lacc1 );                                  /*  Qx      */
    temp[1] = temp2;
    move16();
    Lacc = L_msu_o( Lacc, AP2_STEEP_FX[1], temp2, &Overflow ); /*  Q(16+x) */
#endif
    mem[ALLPASSSECTIONS_STEEP + 1] = extract_h( Lacc );        /*  Qx      */
    move16();

    Lacc = L_deposit_h( mem[2 * ALLPASSSECTIONS_STEEP - 1] );                          /* Q(16+x)  */
#ifdef ISSUE_1836_replace_overflow_libcom
    Lacc = L_mac_sat( Lacc, AP2_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], temp2 );          /* Q(16+x) temp[ALLPASSSECTIONS_STEEP-1] */  //??sat
    temp[2] = extract_h( Lacc );                                                       /* temp[2] in Qx  */
    move16();
    Lacc1 = L_msu_sat( Lacc1, AP2_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], temp[2] );      /*   Q(16+x) */  //??sat
#else
    Lacc = L_mac_o( Lacc, AP2_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], temp2, &Overflow ); /* Q(16+x) temp[ALLPASSSECTIONS_STEEP-1] */
    temp[2] = extract_h( Lacc );                                                       /* temp[2] in Qx  */
    move16();
    Lacc1 = L_msu_o( Lacc1, AP2_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], temp[2], &Overflow ); /*   Q(16+x) */
#endif
    mem[2 * ALLPASSSECTIONS_STEEP - 1] = extract_h( Lacc1 );                               /*   Qx      */
    move16();
    sum = mult_r( out_fx[0], 16384 );                                             /* Qx */
@@ -1018,10 +1064,17 @@ void Decimate_allpass_steep_fx(


        Lacc = L_deposit_h( mem[ALLPASSSECTIONS_STEEP] );                     /* Q(16+x)           */
#ifdef ISSUE_1836_replace_overflow_libcom
        Lacc = L_mac_sat( Lacc, AP2_STEEP_FX[0], in_fx[2 * k - 1] );          /* Q(16+x):temp[0]   */ //??sat
        Lacc1 = L_deposit_h( in_fx[2 * k - 1] );                              /* Q(16+x)           */
        temp1 = extract_h( Lacc );                                            /* Qx                */
        Lacc1 = L_msu_sat( Lacc1, AP2_STEEP_FX[0], temp1 );                   /* Q(16+x)           */ //??sat
#else
        Lacc = L_mac_o( Lacc, AP2_STEEP_FX[0], in_fx[2 * k - 1], &Overflow ); /* Q(16+x):temp[0]   */
        Lacc1 = L_deposit_h( in_fx[2 * k - 1] );                              /* Q(16+x)           */
        temp1 = extract_h( Lacc );                                            /* Qx                */
        Lacc1 = L_msu_o( Lacc1, AP2_STEEP_FX[0], temp1, &Overflow );          /* Q(16+x)           */
#endif

        mem[ALLPASSSECTIONS_STEEP] = extract_h( Lacc1 ); /* Qx */
        move16();
@@ -1030,6 +1083,20 @@ void Decimate_allpass_steep_fx(


        Lacc1 = L_deposit_h( mem[ALLPASSSECTIONS_STEEP + 1] );       /* Q(16+x)  */
#ifdef ISSUE_1836_replace_overflow_libcom
        Lacc1 = L_mac_sat( Lacc1, AP2_STEEP_FX[1], temp1 );          /* Q(16+x)  */ //??sat
        temp2 = extract_h( Lacc1 );                                  /* Qx       */
        temp[1] = temp2;
        move16();
        Lacc = L_msu_sat( Lacc, AP2_STEEP_FX[1], temp2 );            /* Q(16+x)  */ //??sat
        mem[ALLPASSSECTIONS_STEEP + 1] = extract_h( Lacc );              /* Qx       */


        Lacc = L_deposit_h( mem[2 * ALLPASSSECTIONS_STEEP - 1] );                              /* Q(16+x) */
        Lacc = L_mac_sat( Lacc, AP2_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], temp[1] );   //??sat  /* Q(16+x) temp[ALLPASSSECTIONS_STEEP-1] */
        temp[2] = extract_h( Lacc );                                                           /*temp[2] in Qx  */
        Lacc1 = L_msu_sat( Lacc1, AP2_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], temp[2] ); //??sat  /* Q(16+x) */  
#else
        Lacc1 = L_mac_o( Lacc1, AP2_STEEP_FX[1], temp1, &Overflow ); /* Q(16+x)  */
        temp2 = extract_h( Lacc1 );                                  /* Qx       */
        temp[1] = temp2;
@@ -1042,6 +1109,8 @@ void Decimate_allpass_steep_fx(
        Lacc = L_mac_o( Lacc, AP2_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], temp[1], &Overflow );   /* Q(16+x) temp[ALLPASSSECTIONS_STEEP-1] */
        temp[2] = extract_h( Lacc );                                                           /*temp[2] in Qx  */
        Lacc1 = L_msu_o( Lacc1, AP2_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], temp[2], &Overflow ); /* Q(16+x) */
#endif

        mem[2 * ALLPASSSECTIONS_STEEP - 1] = extract_h( Lacc1 );                               /* Qx  */


@@ -1158,9 +1227,11 @@ void Interpolate_allpass_steep_fx(
    Word16 k;
    Word32 Lacc = 0, Lacc1 = 0;
    Word16 temp1, temp2;
#ifndef ISSUE_1836_replace_overflow_libcom
#ifdef BASOP_NOGLOB_DECLARE_LOCAL
    Flag Overflow = 0;
    move32();
#endif
#endif
    /*** State in Q0,in_fx Q0, AP1_STEEP in Q15 AP2_STEEP in Q15  OP in Q0 ************/
    /*upper allpass filter chain     */
@@ -1169,6 +1240,30 @@ void Interpolate_allpass_steep_fx(
    {

        Lacc = L_deposit_h( mem[0] );                                 /* Q(16+x) */
#ifdef ISSUE_1836_replace_overflow_libcom
        Lacc = L_mac_sat( Lacc, AP2_STEEP_FX[0], in_fx[k] );          /* Q(16+x):temp[0] */ //??sat
        Lacc1 = L_deposit_h( in_fx[k] );                              /* Q(16+x) */
        temp1 = round_fx_sat( Lacc );                                 /* Qx */              //??sat
        Lacc1 = L_msu_sat( Lacc1, AP2_STEEP_FX[0], temp1 );           /* Q(16+x)  */        //??sat

        mem[0] = round_fx_sat( Lacc1 );                                                     //??sat
        move16();
        Lacc1 = L_deposit_h( mem[1] );                                /* Q(16+x) */         //??sat
        Lacc1 = ( L_mac_sat( Lacc1, AP2_STEEP_FX[1], temp1 ) );       /* Q(16+x):temp[1] */ //??sat
        Lacc = L_deposit_h( temp1 );

        temp2 = round_fx_sat( Lacc1 );                                /* Qx */              //??sat
        Lacc = L_msu_sat( Lacc, AP2_STEEP_FX[1], temp2 );             /* Q(16+x) */         //??sat
        mem[1] = round_fx_sat( Lacc );                                /* Qx */              //??sat
        move16();

        Lacc1 = L_deposit_h( temp2 );
        Lacc = L_deposit_h( mem[ALLPASSSECTIONS_STEEP - 1] );                                                   /* Q(16+x)   */ //??sat
        out_fx[2 * k + 1] = round_fx_sat( L_mac_sat( Lacc, AP2_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], temp2 ) );  /* Qx format */ //??sat
        move16();
        mem[ALLPASSSECTIONS_STEEP - 1] = round_fx_sat( L_msu_sat( Lacc1, AP2_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], out_fx[2 * k + 1] ) ); /* Qx  */  //??sat //??sat
        move16();
#else
        Lacc = L_mac_o( Lacc, AP2_STEEP_FX[0], in_fx[k], &Overflow ); /* Q(16+x):temp[0] */
        Lacc1 = L_deposit_h( in_fx[k] );                              /* Q(16+x) */
        temp1 = round_fx_o( Lacc, &Overflow );                        /* Qx */
@@ -1191,6 +1286,7 @@ void Interpolate_allpass_steep_fx(
        move16();
        mem[ALLPASSSECTIONS_STEEP - 1] = round_fx_o( L_msu_o( Lacc1, AP2_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], out_fx[2 * k + 1], &Overflow ), &Overflow ); /* Qx  */
        move16();
#endif
    }

    /*  lower allpass filter chain    */
@@ -1198,6 +1294,28 @@ void Interpolate_allpass_steep_fx(
    FOR( k = 0; k < N; k++ )
    {
        Lacc = L_deposit_h( mem[ALLPASSSECTIONS_STEEP] );             /* Q(16+x) */
#ifdef ISSUE_1836_replace_overflow_libcom
        Lacc = L_mac_sat( Lacc, AP1_STEEP_FX[0], in_fx[k] );          /* Q(16+x):temp[0] */  //??sat
        Lacc1 = L_deposit_h( in_fx[k] );                              /* Q(16+x) */
        temp1 = round_fx_sat( Lacc );                                 /* Qx */                //??sat
        Lacc1 = L_msu_sat( Lacc1, AP1_STEEP_FX[0], temp1 );           /* Q(16+x)  */          //??sat

        mem[ALLPASSSECTIONS_STEEP] = round_fx_sat( Lacc1 );                                   //??sat
        Lacc1 = L_deposit_h( mem[ALLPASSSECTIONS_STEEP + 1] );        /* Q(16+x) */
        Lacc1 = L_mac_sat( Lacc1, AP1_STEEP_FX[1], temp1 );           /* Q(16+x):temp[1] */   //??sat

        temp2 = round_fx_sat( Lacc1 );                                /* Qx */                //??sat
        Lacc = L_deposit_h( temp1 );
        Lacc = L_msu_sat( Lacc, AP1_STEEP_FX[1], temp2 );             /* Q(16+x) */           //??sat
        mem[ALLPASSSECTIONS_STEEP + 1] = round_fx_sat( Lacc );        /* Qx */                //??sat

        Lacc = L_deposit_h( mem[2 * ALLPASSSECTIONS_STEEP - 1] ); /* Q(16+x) */
        Lacc1 = L_deposit_h( temp2 );
        out_fx[2 * k] = round_fx_sat( L_mac_sat( Lacc, AP1_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], temp2 ) ); /* Qx format */  //??sat //??sat
        move16();
        mem[2 * ALLPASSSECTIONS_STEEP - 1] = round_fx_sat( L_msu_sat( Lacc1, AP1_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], out_fx[2 * k] ) ); /* Qx */ //??sat //??sat
        move16();
#else
        Lacc = L_mac_o( Lacc, AP1_STEEP_FX[0], in_fx[k], &Overflow ); /* Q(16+x):temp[0] */
        Lacc1 = L_deposit_h( in_fx[k] );                              /* Q(16+x) */
        temp1 = round_fx_o( Lacc, &Overflow );                        /* Qx */
@@ -1218,6 +1336,7 @@ void Interpolate_allpass_steep_fx(
        move16();
        mem[2 * ALLPASSSECTIONS_STEEP - 1] = round_fx_o( L_msu_o( Lacc1, AP1_STEEP_FX[ALLPASSSECTIONS_STEEP - 1], out_fx[2 * k], &Overflow ), &Overflow ); /* Qx */
        move16();
#endif
    }

    return;