[FFmpeg-devel] [PATCH 2/3] avcodec/gdv: Optimize and factorize scaling loops
Carl Eugen Hoyos
ceffmpeg at gmail.com
Sat Jan 12 17:07:42 EET 2019
2019-01-04 20:22 GMT+01:00, Michael Niedermayer <michael at niedermayer.cc>:
> +static void scaledown(uint8_t *dst, const uint8_t *src, int w)
> +{
> + int x;
> + for (x = 0; x < w - 7; x+=8) {
> + dst[x + 0] = src[2*x + 0];
> + dst[x + 1] = src[2*x + 2];
> + dst[x + 2] = src[2*x + 4];
> + dst[x + 3] = src[2*x + 6];
> + dst[x + 4] = src[2*x + 8];
> + dst[x + 5] = src[2*x +10];
> + dst[x + 6] = src[2*x +12];
> + dst[x + 7] = src[2*x +14];
Could you add to the commit message the information
which compiler is able to optimize this?
(Assuming this is a reason for the speedup)
Sorry for the late comment, Carl Eugen
More information about the ffmpeg-devel
mailing list