diff --git a/libcelt/tests/mathops-test.c b/libcelt/tests/mathops-test.c index 56ac5b76..d15fcebf 100644 --- a/libcelt/tests/mathops-test.c +++ b/libcelt/tests/mathops-test.c @@ -3,7 +3,12 @@ #endif #include "mathops.c" +#include "entenc.c" +#include "entdec.c" #include "entcode.c" +#include "bands.c" +#include "vq.c" +#include "cwrs.c" #include #include @@ -57,6 +62,59 @@ void testsqrt(void) } } +void testbitexactcos(void) +{ + int i; + opus_int32 min_d,max_d,last,chk; + chk=max_d=0; + last=min_d=32767; + for(i=0;i<16385;i++) + { + opus_int32 d; + opus_int32 q=bitexact_cos(i); + chk ^= q*i; + d = last - q; + if (d>max_d)max_d=d; + if (dmax_d)max_d=d; + if (d