Commit e195b40a authored by Fabian Bauer's avatar Fabian Bauer
Browse files

delete FIX_1072_SPEEDUP_output_synthesis_procSlot

parent b27584a6
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -56,7 +56,7 @@

#define SUPPORT_JBM_TRACEFILE                   /* Support for JBM tracefile, which is needed for 3GPP objective/subjective testing, but not relevant for real-world implementations */

/*#define WMOPS*/                                   /* Activate complexity and memory counters */
#define WMOPS                                   /* Activate complexity and memory counters */
#ifdef WMOPS
/*#define WMOPS_PER_FRAME*/                     /* Output per-frame complexity (writes one float value per frame to the file "wmops_analysis") */
/*#define WMOPS_DETAIL*/                        /* Output detailed complexity printout for every function. Increases runtime overhead */
@@ -170,6 +170,5 @@

#define FIX_1072_SPEEDUP_gainpanning            /* FhG: WMOPS tuning, in development*/
#define FIX_1072_SPEEDUP_COMPUTEDIFUSENESSB     /* "-" */
#define FIX_1072_SPEEDUP_output_synthesis_procSlot  /* "-" */

#endif
 No newline at end of file
+20 −13
Original line number Diff line number Diff line
@@ -942,28 +942,27 @@ void ivas_dirac_dec_output_synthesis_process_slot_fx(
                                b = BASOP_Util_Divide3232_Scale( reference_power[k + num_freq_bands], reference_power[k + ( ch_idx + 1 ) * num_freq_bands], &b_exp ); /*q(15-b_exp)*/
                            }
                        }
#define FIX_1072_SPEEDUP_output_synthesis_procSlot
#ifdef FIX_1072_SPEEDUP_output_synthesis_procSlot
                        q_diff_aab = add( h_dirac_output_synthesis_state->direct_responses_q + sub( sub( 15, b_exp ), 15 ), add( sub( h_dirac_output_synthesis_state->direct_responses_q, 31 ), sub( q_diffuseness, 31 ) ) );
                        q_diff_c = sub( q_diffuseness, 4 );

                        mpy_a_a_b = Mpy_32_32( a, Mpy_32_16_1( a, b ) );                                           // Q = (h_dirac_output_synthesis_state->q_direct_responses + (15 - b_exp) - 15) + (h_dirac_output_synthesis_state->q_direct_responses) - 31
                        mpy_diff_aab = Mpy_32_32( L_sub( L_shl( 1, q_diffuseness ), diffuseness[k] ), mpy_a_a_b ); // Q = 2*(h_dirac_output_synthesis_state->q_direct_responses) - b_exp - 31 + q_diffuseness -31
                        mpy_diff_c = Mpy_32_32( diffuseness[k], c );                                               // Q = q_diffuseness - 4

                        /*Todo: simplify so that mpy+add can be merged to madd*/

                        //sqr_inp = BASOP_Util_Add_Mant32Exp( mpy_diff_c, sub( 31, q_diff_c ), mpy_diff_aab, sub( 31, q_diff_aab ), &sqr_exp ); /*q(31-sqr_exp)*/

                        {
                            Word16 mpy_diff_c_exp = sub( 31, q_diff_c );
                            Word16 q_diff_aab_exp = sub( 31, q_diff_aab );

                            Word32 L_tmp;
                            Word32 L_tmp, L_tmp1, L_tmp2;
                            Word16 shift;

                            if ( !mpy_diff_c )
                                mpy_diff_c_exp = add( q_diff_aab_exp, 0 );
                            mpy_a_a_b = Mpy_32_32( a, Mpy_32_16_1( a, b ) );                                           // Q = (h_dirac_output_synthesis_state->q_direct_responses + (15 - b_exp) - 15) + (h_dirac_output_synthesis_state->q_direct_responses) - 31
                            mpy_diff_aab = Mpy_32_32( L_sub( L_shl( 1, q_diffuseness ), diffuseness[k] ), mpy_a_a_b ); // Q = 2*(h_dirac_output_synthesis_state->q_direct_responses) - b_exp - 31 + q_diffuseness -31
                            
                            L_tmp = L_add( diffuseness[k], 0 );

                            if ( !diffuseness[k] )
                                mpy_diff_c_exp = add( q_diff_aab_exp, 0 );
                            if ( !c )
                                mpy_diff_c_exp = add( q_diff_aab_exp, 0 );
                            if ( !mpy_diff_aab )
                                q_diff_aab_exp = add( mpy_diff_c_exp, 0 );

@@ -973,7 +972,7 @@ void ivas_dirac_dec_output_synthesis_process_slot_fx(
                            if ( shift < 0 )
                            {
                                /* exponent of b is greater than exponent of a, shr mpy_diff_c */
                                mpy_diff_c = L_shl( mpy_diff_c, shift );
                                L_tmp = L_shl( L_tmp, shift );
                            }
                            if ( shift > 0 )
                            {
@@ -981,7 +980,15 @@ void ivas_dirac_dec_output_synthesis_process_slot_fx(
                                mpy_diff_aab = L_shr( mpy_diff_aab, shift );
                            }
                            mpy_diff_c_exp = add( s_max( mpy_diff_c_exp, q_diff_aab_exp ), 1 );
                            L_tmp = L_add( L_shr( mpy_diff_c, 1 ), L_shr( mpy_diff_aab, 1 ) );
                            L_tmp = L_shr( L_tmp, 1 );
                            L_tmp1 = L_shr( mpy_diff_aab, 1 );

                            L_tmp = Madd_32_32( L_tmp1, L_tmp, c ); // Q = q_diffuseness - 4

                            /*Todo: simplify so that mpy+add can be merged to madd*/

                            // sqr_inp = BASOP_Util_Add_Mant32Exp( mpy_diff_c, sub( 31, q_diff_c ), mpy_diff_aab, sub( 31, q_diff_aab ), &sqr_exp ); /*q(31-sqr_exp)*/

                            shift = norm_l( L_tmp );
                            if ( shift )
                                L_tmp = L_shl( L_tmp, shift );