>> +#define randomize_buffers(buf, size)            \
>> +    do {                                        \
>> +        int j;                                  \
>> +        for (j = 0; j < size; j++) {            \
>> +            int16_t r = rnd();                  \
>> +            AV_WN16A(buf + j, r >> 3);          \
>> +        }                                       \
>> +    } while (0)
>
> We should stop duplicating these between checkasm modules some day.
> You're welcome to help me refactor.

As Martin already pointed out, all the ramdomize buffers are slightly
different for all of hevc tests
>
>> +#define randomize_buffers2(buf, size)     \
>> +    do {                                 \
>> +        int j;                           \
>> +        for (j = 0; j < size; j++)       \
>> +            AV_WN16A(buf + j * 2, (rnd() & 0xFF));       \
>
> pointless (), align the \
>
> What is the reason for writing 16-bits and throwing the upper half away?

I'll better use 0x3FF.
>
>> +void checkasm_check_hevc_add_res(void)
>> +{
>> +    int bit_depth;
>> +
>> +    for (bit_depth = 8; bit_depth <= 10; bit_depth++) {
>> +        HEVCDSPContext h;
>> +
>> +        ff_hevc_dsp_init(&h, bit_depth);
>> +        check_add_res(h, bit_depth);
>> +    }
>
> I didn't see you add 9-bit versions of the assembly functions, why do
> you test 9 bits?
>
Because there's no 9 bit SIMD function, it's not tested but the code
looks simpler this way.
_______________________________________________
libav-devel mailing list
libav-devel@libav.org
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to