diff options
author | Rémi Verschelde <remi@verschelde.fr> | 2016-05-03 19:14:24 +0200 |
---|---|---|
committer | Rémi Verschelde <remi@verschelde.fr> | 2016-05-03 19:14:24 +0200 |
commit | c90bc695447b5d74227ed7c0d0bc19b7141dc835 (patch) | |
tree | 808af09d82e51698b9b7ba18795ba3a210a1d8f0 /drivers/opus/celt/fixed_debug.h | |
parent | 4e23ba5f37e21021c47e3aecf544afc9485e311b (diff) | |
parent | 7c59d819a7ebb936d51ca032e66a2489e4080d08 (diff) |
Merge pull request #4532 from vnen/pr-update-opus-1.1.2
Update Opus driver to 1.1.2
Diffstat (limited to 'drivers/opus/celt/fixed_debug.h')
-rw-r--r-- | drivers/opus/celt/fixed_debug.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/drivers/opus/celt/fixed_debug.h b/drivers/opus/celt/fixed_debug.h index 0ed16baa17..3b8d5ef7a9 100644 --- a/drivers/opus/celt/fixed_debug.h +++ b/drivers/opus/celt/fixed_debug.h @@ -496,6 +496,7 @@ static OPUS_INLINE int MULT16_32_PX_(int a, opus_int64 b, int Q, char *file, int #define MULT16_32_Q15(a,b) MULT16_32_QX(a,b,15) #define MAC16_32_Q15(c,a,b) (celt_mips-=2,ADD32((c),MULT16_32_Q15((a),(b)))) +#define MAC16_32_Q16(c,a,b) (celt_mips-=2,ADD32((c),MULT16_32_Q16((a),(b)))) static OPUS_INLINE int SATURATE(int a, int b) { @@ -767,6 +768,16 @@ static OPUS_INLINE int DIV32_(opus_int64 a, opus_int64 b, char *file, int line) return res; } +static OPUS_INLINE opus_val16 SIG2WORD16_generic(celt_sig x) +{ + x = PSHR32(x, SIG_SHIFT); + x = MAX32(x, -32768); + x = MIN32(x, 32767); + return EXTRACT16(x); +} +#define SIG2WORD16(x) (SIG2WORD16_generic(x)) + + #undef PRINT_MIPS #define PRINT_MIPS(file) do {fprintf (file, "total complexity = %llu MIPS\n", celt_mips);} while (0); |