Commit 7e255881 authored by vaclav's avatar vaclav
Browse files

- Merge remote-tracking branch 'remotes/origin/main' into voiceage/harm_gsc

parents 9ea5d5d8 d3508f9d
Loading
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
@@ -1375,7 +1375,11 @@ void pca_enc_s3_fx(

    q_ang_2surv_fx( ph1_fx, n1, ph1_q_fx, ind1 );

#ifdef FIX_2254_IMPROV_PRECISION_OR_COMPLEXITY_NON_BE
    tmp = mac_r( L_mac( L_mult( q_fx[1], q_fx[1] ), q_fx[2], q_fx[2] ), q_fx[3], q_fx[3] ); // Q15 + Q15 - Q15 -> Q15
#else
    tmp = add( add( mult( q_fx[1], q_fx[1] ), mult( q_fx[2], q_fx[2] ) ), mult( q_fx[3], q_fx[3] ) ); // Q15 + Q15 - Q15 -> Q15
#endif
    r_e = 0;
    move16();
    r_fx = Sqrt16( tmp, &r_e );
@@ -1429,8 +1433,11 @@ void pca_enc_s3_fx(
        q_ang_2surv_fx( ph2_fx, n2[i], ph2_q_fx + 2 * i, ind2 + 2 * i );
    }

#ifdef FIX_2254_IMPROV_PRECISION_OR_COMPLEXITY_NON_BE
    r_fx = Sqrt16( mac_r( L_mult( q_fx[2], q_fx[2] ), q_fx[3], q_fx[3] ), &r_e );
#else
    r_fx = Sqrt16( add( mult( q_fx[2], q_fx[2] ), mult( q_fx[3], q_fx[3] ) ), &r_e );

#endif

    v_fx = BASOP_Util_Divide1616_Scale( q_fx[2], r_fx, &v_e );
    v_e = add( v_e, sub( 0, r_e ) );
+1 −0
Original line number Diff line number Diff line
@@ -1884,6 +1884,7 @@ void GenShapedWBExcitation_ivas_fx(
    Word16 *mem_genSHBexc_filt_down3,                           /* i/o : memory                        Q_bwe_exc*/
    Word16 *state_lpc_syn,                                      /* i/o : memory                        Q_bwe_exc*/
    const Word16 coder_type,                                    /* i : coding type                              */
    const Word16 element_mode,                                  /* i : element mode                             */
    const Word16 *bwe_exc_extended,                             /* i : bwidth extended exciatation     Q_bwe_exc*/
    const Word16 Q_bwe_exc,
    Word16 bwe_seed[],                                          /* i/o : random number generator seed           */
+6 −0
Original line number Diff line number Diff line
@@ -88,6 +88,7 @@
#define FIX_1435_MOVE_STEREO_PANNING                    /* VA: issue 1435: do the EVS stereo panning in the renderer */
#define FIX_2252_SCALING_SAVE_HB_SYNTH                  /* VA: issue 2252: fix use-of-uninit-value in save_hb_synth_fx[] scaling in FOA decoding with bitstream that starts with an SID */
#define FIX_2248_EVS_ASSERT                             /* VA: Include _sat in an EVS related part of the code */
#define FIX_2254_IMPROV_COMPLEXITY_BE                   /* VA: BE small complexity reduction  */
#define FIX_1904_HARM_GSC_ENC                           /* VA: #1904 Harmonization of EVS and IVAS GSC code */

/* #################### End BE switches ################################## */
@@ -99,6 +100,10 @@
#define FIX_1461_CNG_BW_SWITCHING                       /* Eri: float issue 1461: Stereo parameters are not updated when SID/NODATA forces BW to stay the same */
#define FIX_2041_SPECTRAL_GAPS_FOR_INACTIVE_FRAMES      /* FhG: Using rounding in multiplication to improve precision in cngNoiseLevel[] */
#define FIX_2264_OUT_OF_BOUND_READING_IN_LOG2_NORM_LC   /* VA: Fix issue 2264 by adding a proper safeguard in log2 and by adding a missing normalization in swb_pre_proc_ivas_fx()*/
#define FIX_2250_LARGE_DIFFERENCES_BETWEEN_BASOP_AND_FLOAT  /* Dolby: Issue 2250:  random vector generation in GenShapedSHBExcitation() */
#define FIX_2254_IMPROV_PRECISION_OR_COMPLEXITY_NON_BE  /* VA: Precision improvement without increasing complexity, or complexity reduction that might be not BE on the LSB */
#define FIX_2252_LP_CNG_STARTS_SID                      /* VA: issues 2251 and 2252: fix LP CNG uninitialized value in bitstream that starts with an SID */

/* ##################### End NON-BE switches ########################### */

/* ################## End MAINTENANCE switches ######################### */
@@ -116,4 +121,5 @@

/* #################### End BASOP optimization switches ############################ */


#endif
+5 −0
Original line number Diff line number Diff line
@@ -58,8 +58,13 @@ void pred_lt4_ivas_fx(
            FOR( i = 0; i < nb_coef; i++ )
            {
                /*s += (*x1--) * (*c1) + (*x2++) * (*c2);*/
#ifdef FIX_2254_IMPROV_COMPLEXITY_BE
                s64 = W_mac_32_16( s64, ( *c1 ), *x1-- ); /* Q_exc + Q32 */
                s64 = W_mac_32_16( s64, ( *c2 ), *x2++ ); /* Q_exc + Q32 */
#else
                s64 = W_mac_32_32( s64, L_deposit_l( *x1-- ), ( *c1 ) ); /* Q_exc + Q32 */
                s64 = W_mac_32_32( s64, L_deposit_l( *x2++ ), ( *c2 ) ); /* Q_exc + Q32 */
#endif
                c1 += up_sample;
                c2 += up_sample;
            }
+2 −0
Original line number Diff line number Diff line
@@ -3004,6 +3004,7 @@ void GenShapedWBExcitation_fx(
    Word16 *mem_genSHBexc_filt_down3, /* i/o : memory                                 */
    Word16 *state_lpc_syn,            /* i/o : memory                                 */
    const Word16 coder_type,          /* i   : coding type                            */
    const Word16 element_mode,        /* i :   element mode                           */
    const Word16 *bwe_exc_extended,   /* i   : bandwidth extended exciatation         */
    const Word16 Q_bwe_exc,
    Word16 bwe_seed[],            /* i/o : random number generator seed           */
@@ -3026,6 +3027,7 @@ void GenShapedSHBExcitation_fx(
    Word16 *mem_genSHBexc_filt_down_shb, /* i/o: memory */
    Word16 *state_lpc_syn,               /* i/o: memory */
    const Word16 coder_type,             /* i : coding type */
    const Word16 element_mode,           /* i : element mode */
    const Word16 *bwe_exc_extended,      /* i : bandwidth extended excitation */
    Word16 bwe_seed[],                   /* i/o: random number generator seed */
    Word16 voice_factors[],              /* i : voicing factor*/
Loading