Commit 94bfc2bd authored by Sandesh Venkatesh's avatar Sandesh Venkatesh
Browse files

Merge branch '3gpp_issue_1722_fix' into 'main'

Fix for 3GPP issue 1722: Assert in BASOP renderer when rendering ISM to certain custom LS setup

See merge request !1717
parents b4c3b18f 9281becb
Loading
Loading
Loading
Loading
+4 −3
Original line number Diff line number Diff line
@@ -2490,7 +2490,8 @@ static Word16 in_tri_fx(
    Word32 tmpDot1[2], tmpDot2[2];
    Word32 matInv[2][2];
    Word32 invFactor;
    Word16 tmp16, tmp_e;
    Word16 tmp_e;
    Word32 tmp32;
    Word64 S[2];
    /* Threshold adjusted */
    Word64 thresh_int = 35184640; // 1e-6f in Q45
@@ -2520,8 +2521,8 @@ static Word16 in_tri_fx(
    }

    /* invFactor = 1.f / invFactor; */
    tmp16 = BASOP_Util_Divide3232_Scale( ONE_IN_Q13, invFactor, &tmp_e ); /*15-tmp_e*/
    invFactor = L_shl_sat( tmp16, add( Q16, tmp_e ) );                    /* Q31 */
    tmp32 = BASOP_Util_Divide3232_Scale_newton( ONE_IN_Q13, invFactor, &tmp_e ); /*31-tmp_e*/
    invFactor = L_shl_sat( tmp32, tmp_e );                                       /* Q31 */

    Word16 invFactor_exp = norm_l( invFactor );
    invFactor = L_shl( invFactor, invFactor_exp ); // 31+invFactor_exp