/external/speex/libspeexdsp/ |
D | fixed_generic.h | 75 #define MULT16_16(a,b) (((spx_word32_t)(spx_word16_t)(a))*((spx_word32_t)(spx_word16_t)(b))) macro 77 #define MAC16_16(c,a,b) (ADD32((c),MULT16_16((a),(b)))) 78 #define MULT16_32_Q12(a,b) ADD32(MULT16_16((a),SHR((b),12)), SHR(MULT16_16((a),((b)&0x00000fff)),12… 79 #define MULT16_32_Q13(a,b) ADD32(MULT16_16((a),SHR((b),13)), SHR(MULT16_16((a),((b)&0x00001fff)),13… 80 #define MULT16_32_Q14(a,b) ADD32(MULT16_16((a),SHR((b),14)), SHR(MULT16_16((a),((b)&0x00003fff)),14… 82 #define MULT16_32_Q11(a,b) ADD32(MULT16_16((a),SHR((b),11)), SHR(MULT16_16((a),((b)&0x000007ff)),11… 83 #define MAC16_32_Q11(c,a,b) ADD32(c,ADD32(MULT16_16((a),SHR((b),11)), SHR(MULT16_16((a),((b)&0x0000… 85 #define MULT16_32_P15(a,b) ADD32(MULT16_16((a),SHR((b),15)), PSHR(MULT16_16((a),((b)&0x00007fff)),1… 86 #define MULT16_32_Q15(a,b) ADD32(MULT16_16((a),SHR((b),15)), SHR(MULT16_16((a),((b)&0x00007fff)),15… 87 #define MAC16_32_Q15(c,a,b) ADD32(c,ADD32(MULT16_16((a),SHR((b),15)), SHR(MULT16_16((a),((b)&0x0000… [all …]
|
D | filterbank.c | 46 … toBARK(n) (MULT16_16(26829,spx_atan(SHR32(MULT16_16(97,n),2))) + MULT16_16(4588,spx_atan(MULT16… 62 df = DIV32(SHL32(sampling,15),MULT16_16(2,len)); in filterbank_new() 165 tmp = MULT16_16(mel[id1],bank->filter_left[i]); in filterbank_compute_psd16() 166 tmp += MULT16_16(mel[id2],bank->filter_right[i]); in filterbank_compute_psd16()
|
D | preprocess.c | 88 #define SQR16(x) (MULT16_16((x),(x))) 258 spx_word16_t x = DIV32_16(MULT16_16(32767,i),len); in conj_window() 260 spx_word16_t x = DIV32_16(MULT16_16(QCONST16(4.f,13),i),len); in conj_window() 307 …return SHL32(DIV32_16(PSHR32(MULT16_16(Q15_ONE-frac,table[ind]) + MULT16_16(frac,table[ind+1]),7),… in hypergeom_gain() 324 …noise_gain = EXTRACT16(MIN32(Q15_ONE,SHR32(spx_exp(MULT16_16(QCONST16(0.11513,11),noise_suppress))… in compute_gain_floor() 325 …gain_ratio = EXTRACT16(MIN32(Q15_ONE,SHR32(spx_exp(MULT16_16(QCONST16(.2302585f,11),effective_echo… in compute_gain_floor() 334 …echo_gain = EXTRACT16(MIN32(Q15_ONE,SHR32(spx_exp(MULT16_16(QCONST16(0.11513,11),effective_echo_su… in compute_gain_floor() 335 …gain_ratio = EXTRACT16(MIN32(Q15_ONE,SHR32(spx_exp(MULT16_16(QCONST16(.2302585f,11),noise_suppress… in compute_gain_floor() 651 ps[0]=MULT16_16(st->ft[0],st->ft[0]); in preprocess_analysis() 653 ps[i]=MULT16_16(st->ft[2*i-1],st->ft[2*i-1]) + MULT16_16(st->ft[2*i],st->ft[2*i]); in preprocess_analysis() [all …]
|
D | mdf.c | 237 ps[0]=MULT16_16(X[0],X[0]); in power_spectrum() 240 ps[j] = MULT16_16(X[i],X[i]) + MULT16_16(X[i+1],X[i+1]); in power_spectrum() 242 ps[j]=MULT16_16(X[i],X[i]); in power_spectrum() 249 ps[0]+=MULT16_16(X[0],X[0]); in power_spectrum_accum() 252 ps[j] += MULT16_16(X[i],X[i]) + MULT16_16(X[i+1],X[i+1]); in power_spectrum_accum() 254 ps[j]+=MULT16_16(X[i],X[i]); in power_spectrum_accum() 273 … tmp1 = SUB32(MAC16_16(tmp1, X[j*N+i],TOP16(Y[j*N+i])), MULT16_16(X[j*N+i+1],TOP16(Y[j*N+i+1]))); in spectral_mul_accum() 300 tmp1 = SUB32(MAC16_16(tmp1, X[j*N+i],Y[j*N+i]), MULT16_16(X[j*N+i+1],Y[j*N+i+1])); in spectral_mul_accum16() 342 prod[0] = FLOAT_MUL32(W,MULT16_16(X[0],Y[0])); in weighted_spectral_mul_conj() 346 prod[i] = FLOAT_MUL32(W,MAC16_16(MULT16_16(X[i],Y[i]), X[i+1],Y[i+1])); in weighted_spectral_mul_conj() [all …]
|
D | resample.c | 311 …interp[0] = PSHR32(MULT16_16(QCONST16(-0.16667f, 15),x) + MULT16_16(QCONST16(0.16667f, 15),x3),15); in cubic_coef() 313 …interp[3] = PSHR32(MULT16_16(QCONST16(-0.33333f, 15),x) + MULT16_16(QCONST16(.5f,15),x2) - MULT16_… in cubic_coef() 354 for(j=0;j<N;j++) sum += MULT16_16(sinct[j], iptr[j]); in resampler_basic_direct_single() 471 accum[0] += MULT16_16(curr_in,st->sinc_table[4+(j+1)*st->oversample-offset-2]); in resampler_basic_interpolate_single() 472 accum[1] += MULT16_16(curr_in,st->sinc_table[4+(j+1)*st->oversample-offset-1]); in resampler_basic_interpolate_single() 473 accum[2] += MULT16_16(curr_in,st->sinc_table[4+(j+1)*st->oversample-offset]); in resampler_basic_interpolate_single() 474 accum[3] += MULT16_16(curr_in,st->sinc_table[4+(j+1)*st->oversample-offset+1]); in resampler_basic_interpolate_single() 534 accum[0] += MULT16_16(curr_in,st->sinc_table[4+(j+1)*st->oversample-offset-2]); in resampler_basic_interpolate_double() 535 accum[1] += MULT16_16(curr_in,st->sinc_table[4+(j+1)*st->oversample-offset-1]); in resampler_basic_interpolate_double() 536 accum[2] += MULT16_16(curr_in,st->sinc_table[4+(j+1)*st->oversample-offset]); in resampler_basic_interpolate_double() [all …]
|
D | fixed_arm5e.h | 38 #undef MULT16_16 39 static inline spx_word32_t MULT16_16(spx_word16_t x, spx_word16_t y) { in MULT16_16() function
|
D | kiss_fftr.c | 243 …twr = SHR32(SUB32(MULT16_16(f2k.r,st->super_twiddles[k].r),MULT16_16(f2k.i,st->super_twiddles[k].i… in kiss_fftr2() 244 …twi = SHR32(ADD32(MULT16_16(f2k.i,st->super_twiddles[k].r),MULT16_16(f2k.r,st->super_twiddles[k].i… in kiss_fftr2()
|
D | fixed_debug.h | 253 #define MULT16_16(a, b) _MULT16_16(a, b, __FILE__, __LINE__) macro 268 #define MAC16_16(c,a,b) (spx_mips--,ADD32((c),MULT16_16((a),(b)))) 269 #define MAC16_16_Q11(c,a,b) (EXTRACT16(ADD16((c),EXTRACT16(SHR32(MULT16_16((a),(b)),11))))) 270 #define MAC16_16_Q13(c,a,b) (EXTRACT16(ADD16((c),EXTRACT16(SHR32(MULT16_16((a),(b)),13))))) 271 #define MAC16_16_P13(c,a,b) (EXTRACT16(ADD32((c),SHR32(ADD32(4096,MULT16_16((a),(b))),13))))
|
D | kiss_fft.c | 54 tr = SHR32(SUB32(MULT16_16(Fout2->r , tw1->r),MULT16_16(Fout2->i , tw1->i)), 1); in kf_bfly2() 55 ti = SHR32(ADD32(MULT16_16(Fout2->i , tw1->r),MULT16_16(Fout2->r , tw1->i)), 1); in kf_bfly2()
|
D | math_approx.h | 126 res = MULT16_16(EXTRACT16(SHR32(*seed,16)),std); in speex_rand()
|
D | arch.h | 178 #define MULT16_16(a,b) ((spx_word32_t)(a)*(spx_word32_t)(b)) macro
|
/external/libopus/celt/ |
D | fixed_generic.h | 43 #define MULT16_32_Q16(a,b) ADD32(MULT16_16((a),SHR((b),16)), SHR(MULT16_16SU((a),((b)&0x0000ffff)),… 50 #define MULT16_32_P16(a,b) ADD32(MULT16_16((a),SHR((b),16)), PSHR(MULT16_16SU((a),((b)&0x0000ffff))… 57 #define MULT16_32_Q15(a,b) ADD32(SHL(MULT16_16((a),SHR((b),16)),1), SHR(MULT16_16SU((a),((b)&0x0000… 64 #define MULT32_32_Q31(a,b) ADD32(ADD32(SHL(MULT16_16(SHR((a),16),SHR((b),16)),1), SHR(MULT16_16SU(S… 136 #define MULT16_16(a,b) (((opus_val32)(opus_val16)(a))*((opus_val32)(opus_val16)(b))) macro 139 #define MAC16_16(c,a,b) (ADD32((c),MULT16_16((a),(b)))) 143 #define MAC16_32_Q15(c,a,b) ADD32((c),ADD32(MULT16_16((a),SHR((b),15)), SHR(MULT16_16((a),((b)&0x00… 147 #define MAC16_32_Q16(c,a,b) ADD32((c),ADD32(MULT16_16((a),SHR((b),16)), SHR(MULT16_16SU((a),((b)&0x… 149 #define MULT16_16_Q11_32(a,b) (SHR(MULT16_16((a),(b)),11)) 150 #define MULT16_16_Q11(a,b) (SHR(MULT16_16((a),(b)),11)) [all …]
|
D | vq.c | 55 Xptr[stride] = EXTRACT16(PSHR32(MAC16_16(MULT16_16(c, x2), s, x1), 15)); in exp_rotation1() 56 *Xptr++ = EXTRACT16(PSHR32(MAC16_16(MULT16_16(c, x1), ms, x2), 15)); in exp_rotation1() 64 Xptr[stride] = EXTRACT16(PSHR32(MAC16_16(MULT16_16(c, x2), s, x1), 15)); in exp_rotation1() 65 *Xptr-- = EXTRACT16(PSHR32(MAC16_16(MULT16_16(c, x1), ms, x2), 15)); in exp_rotation1() 83 gain = celt_div((opus_val32)MULT16_16(Q15_ONE,len),(opus_val32)(len+factor*K)); in exp_rotation() 135 X[i] = EXTRACT16(PSHR32(MULT16_16(g, iy[i]), k+1)); in normalise_residual() 295 if (opus_unlikely(MULT16_16(best_den, Rxy) > MULT16_16(Ryy, best_num))) in op_pvq_search_c() 399 *xptr = EXTRACT16(PSHR32(MULT16_16(g, *xptr), k+1)); in renormalise_vector()
|
D | celt_lpc.c | 145 sum -= MULT16_16(den[j],mem[j]); in celt_iir() 200 sum -= MULT16_16(rden[j],y[i+j]); in celt_iir() 248 if (n&1) ac0 += SHR32(MULT16_16(xptr[0],xptr[0]),9); in _celt_autocorr() 251 ac0 += SHR32(MULT16_16(xptr[i],xptr[i]),9); in _celt_autocorr() 252 ac0 += SHR32(MULT16_16(xptr[i+1],xptr[i+1]),9); in _celt_autocorr()
|
D | pitch.c | 69 Syy = ADD32(Syy, SHR32(MULT16_16(y[j],y[j]), yshift)); in find_best_pitch() 100 Syy += SHR32(MULT16_16(y[i+len],y[i+len]),yshift) - SHR32(MULT16_16(y[i],y[i]),yshift); in find_best_pitch() 359 sum += SHR32(MULT16_16(x_lp[j],y[i+j]), shift); in pitch_search() 407 x2y2 = SHR32(MULT16_16(VSHR32(xx, sx), VSHR32(yy, sy)), 14); in compute_pitch_gain() 462 yy = yy+MULT16_16(x[-i],x[-i])-MULT16_16(x[N-i],x[N-i]); in remove_doubling()
|
D | quant_bands.c | 194 f = SHL32(EXTEND32(x),7) - PSHR32(MULT16_16(coef,oldE), 8) - prev[c]; in quant_coarse_energy_impl() 250 tmp = PSHR32(MULT16_16(coef,oldE),8) + prev[c] + SHL32(q,7); in quant_coarse_energy_impl() 255 prev[c] = prev[c] + SHL32(q,7) - MULT16_16(beta,PSHR32(q,8)); in quant_coarse_energy_impl() 483 tmp = PSHR32(MULT16_16(coef,oldEBands[i+c*m->nbEBands]),8) + prev[c] + SHL32(q,7); in unquant_coarse_energy() 488 prev[c] = prev[c] + SHL32(q,7) - MULT16_16(beta,PSHR32(q,8)); in unquant_coarse_energy()
|
D | bands.c | 254 *f++ = SHL32(MULT16_16(*x++, g), -shift); in denormalise_bands() 260 *f++ = SHR32(MULT16_16(*x++, g), shift); in denormalise_bands() 400 norm = EPSILON + celt_sqrt(EPSILON+MULT16_16(left,left)+MULT16_16(right,right)); in intensity_stereo() 408 X[j] = EXTRACT16(SHR32(MAC16_16(MULT16_16(a1, l), a2, r), 14)); in intensity_stereo() 419 l = MULT16_16(QCONST16(.70710678f, 15), X[j]); in stereo_split() 420 r = MULT16_16(QCONST16(.70710678f, 15), Y[j]); in stereo_split() 443 El = MULT16_16(mid2, mid2) + side - 2*xp; in stereo_merge() 444 Er = MULT16_16(mid2, mid2) + side + 2*xp; in stereo_merge() 473 X[j] = EXTRACT16(PSHR32(MULT16_16(lgain, SUB16(l,r)), kl+1)); in stereo_merge() 474 Y[j] = EXTRACT16(PSHR32(MULT16_16(rgain, ADD16(l,r)), kr+1)); in stereo_merge() [all …]
|
D | celt_encoder.c | 320 opus_val16 x2 = PSHR32(MULT16_16(tmp[2*i],tmp[2*i]) + MULT16_16(tmp[2*i+1],tmp[2*i+1]),16); in transient_analysis() 356 mean = MULT16_16(celt_sqrt(mean), celt_sqrt(MULT16_16(maxE,len2>>1))); in transient_analysis() 400 …*tf_estimate = celt_sqrt(MAX32(0, SHL32(MULT16_16(QCONST16(0.0069,14),MIN16(163,tf_max)),14)-QCONS… in transient_analysis() 516 m = SHR32(MULT16_16(coef0, x), 15-SIG_SHIFT); in celt_preemphasis() 550 tmp = MULT16_16(coef2, x); in celt_preemphasis() 563 m = SHR32(MULT16_16(coef0, x), 15-SIG_SHIFT); in celt_preemphasis() 830 logXC = celt_log2(QCONST32(1.001f, 20)-MULT16_16(sum, sum)); in alloc_trim_analysis() 832 logXC2 = MAX16(HALF16(logXC), celt_log2(QCONST32(1.001f, 20)-MULT16_16(minXC, minXC))); in alloc_trim_analysis() 991 noise_floor[i] = MULT16_16(QCONST16(0.0625f, DB_SHIFT),logN[i]) in dynalloc_analysis() 993 +MULT16_16(QCONST16(.0062,DB_SHIFT),(i+5)*(i+5)); in dynalloc_analysis() [all …]
|
D | fixed_debug.h | 45 #define MULT32_32_Q31(a,b) ADD32(ADD32(SHL32(MULT16_16(SHR32((a),16),SHR((b),16)),1), SHR32(MULT16_… 48 #define MULT16_32_Q16(a,b) ADD32(MULT16_16((a),SHR32((b),16)), SHR32(MULT16_16SU((a),((b)&0x0000fff… 413 #define MULT16_16(a, b) MULT16_16_(a, b, __FILE__, __LINE__) macro 436 #define MAC16_16(c,a,b) (celt_mips-=2,ADD32((c),MULT16_16((a),(b))))
|
D | fixed_c5x.h | 71 #define MULT16_32_Q15(a,b) ADD32(SHL(MULT16_16((a),SHR((b),16)),1), SHR(MULT16_16SU((a),(b)),15))
|
D | celt_decoder.c | 695 E1 += SHR32(MULT16_16(e, e), shift); in celt_decode_lost() 697 E2 += SHR32(MULT16_16(e, e), shift); in celt_decode_lost() 732 S1 += SHR32(MULT16_16(tmp, tmp), 10); in celt_decode_lost() 759 S2 += SHR32(MULT16_16(tmp, tmp), 10); in celt_decode_lost()
|
D | arch.h | 249 #define MULT16_16(a,b) ((opus_val32)(a)*(opus_val32)(b)) macro
|
/external/libopus/celt/mips/ |
D | vq_mipsr1.h | 54 Xptr[stride] = EXTRACT16(PSHR32(MAC16_16(MULT16_16(c, x2), s, x1), 15)); in exp_rotation1() 55 *Xptr++ = EXTRACT16(PSHR32(MAC16_16(MULT16_16(c, x1), ms, x2), 15)); in exp_rotation1() 63 Xptr[stride] = EXTRACT16(PSHR32(MAC16_16(MULT16_16(c, x2), s, x1), 15)); in exp_rotation1() 64 *Xptr-- = EXTRACT16(PSHR32(MAC16_16(MULT16_16(c, x1), ms, x2), 15)); in exp_rotation1() 116 *xptr = EXTRACT16(PSHR32(MULT16_16(g, *xptr), k+1)); in renormalise_vector_mips()
|
/external/libopus/celt/arm/ |
D | fixed_armv5e.h | 119 #undef MULT16_16 131 #define MULT16_16(a, b) (MULT16_16_armv5e(a, b)) macro
|
/external/libopus/src/ |
D | opus_encoder.c | 460 g = SHR32(MAC16_16(MULT16_16(w,g2), in stereo_fade() 492 g = SHR32(MAC16_16(MULT16_16(w,g2), in gain_fade() 501 g = SHR32(MAC16_16(MULT16_16(w,g2), in gain_fade() 646 short_alpha = Q15ONE - MULT16_16(25, Q15ONE)/IMAX(50,frame_rate); in compute_stereo_width() 659 pxx = SHR32(MULT16_16(x,x),2); in compute_stereo_width() 660 pxy = SHR32(MULT16_16(x,y),2); in compute_stereo_width() 661 pyy = SHR32(MULT16_16(y,y),2); in compute_stereo_width() 664 pxx += SHR32(MULT16_16(x,x),2); in compute_stereo_width() 665 pxy += SHR32(MULT16_16(x,y),2); in compute_stereo_width() 666 pyy += SHR32(MULT16_16(y,y),2); in compute_stereo_width() [all …]
|