Skip to content

Replace carry/overflow-using 32-bit operators by 64-bit version (II.)

In the legacy code, some array energies are computed using rather deprecated operators like

  • L_add_c/L_add_co
  • L_macNs_co, L_msu_co that have to handle pointers to "Carry" and "Overflow" in sophisticated way. In this context also a function norm_llQ31 is used to normalize those results.

Meanwhile, there are 64-bit operators and functions, that are much easier to handle.

  • basop_util.c: Dot_productSq16HQ computes the 16-bit array energy, incl. start sum
  • basop_util.c: w_norm_llQ31: Normalizes 64-bit dotProduct

Similar to issue 1817 (Files dec_tcx_fx.c, fd_cng_dec_fx.c), there are more files to correct:

  • lib_com/basop_util.c () : L_add_co()
  • lib_com/igf_base_fx.c : L_add_co(), L_macNs_co()
  • lib_dec/arith_coder_dec_fx.c : L_macNs_co()
  • lib_dec/er_dec_tcx_fx.c: L_macNs_co()
  • lib_dec/igf_dec_fx.c : L_add_co(), L_macNs_co()
  • lib_enc/arith_coder_enc_fx.c: L_macNs_co()
  • lib_enc/cod_tcx_fx.c : L_macNs_co()
  • lib_enc/enc_acelp_fx.c : L_add_co()
  • lib_enc/igf_enc_fx.c : L_add_co(), L_macNs_co()