checkasm: test the noise case of sbrdsp.hf_apply_noise

The tested functions treat s_m[i] == 0 as a special case. Other than
that, the functions are slightly complicated vector additions.

This actually makes the zero case happen pseudorandomly.
This commit is contained in:
Rémi Denis-Courmont 2023-11-10 21:17:43 +02:00
parent 6d60cc7baf
commit 20e6195c54

View File

@ -233,7 +233,10 @@ static void test_hf_apply_noise(const SBRDSPContext *sbrdsp)
int kx, int m_max);
randomize((INTFLOAT *)ref, 128 * 2);
randomize((INTFLOAT *)s_m, 128);
for (int i = 0; i < 128; i++)
s_m[i] = (rnd() & 1) ? ((INTFLOAT)rnd() / UINT_MAX) : (INTFLOAT)0;
randomize((INTFLOAT *)q_filt, 128);
for (i = 0; i < 4; i++) {