From: Yi Luo Date: Tue, 7 Jun 2016 01:25:25 +0000 (-0700) Subject: Move prototype wrapper function X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=485425aa6ec9cc2d188013597f008f999a57fb2d;p=libvpx Move prototype wrapper function - Found after setting height on command line change, HorizP turns to be slower. The change include moving this wrapper function. This change restores it. This is a mystery now. --- diff --git a/convolve/horiz_filter.c b/convolve/horiz_filter.c index 35be482eb..3f13b104d 100644 --- a/convolve/horiz_filter.c +++ b/convolve/horiz_filter.c @@ -297,6 +297,24 @@ void horiz_filter_ssse3(const uint8_t *src, const struct Filter fData, } } +// C prototype wrapper function +void run_prototype_filter(uint8_t *src, int width, int height, int stride, + const int16_t *filter, int flen, uint8_t *dst) { + uint32_t start, end; + int count = 0; + + start = readtsc(); + do { + convolve(src, width, filter, flen, dst); + src += stride; + dst += stride; + count++; + } while (count < height); + end = readtsc(); + + printf("C version cycles:\t%d\n", end - start); +} + // sub-pixel 4x4 method static void transpose4x4_to_dst(const uint8_t *src, ptrdiff_t src_stride, uint8_t *dst, ptrdiff_t dst_stride) { @@ -400,23 +418,6 @@ static void filter_horiz_w4_ssse3(const uint8_t *src_ptr, ptrdiff_t src_pitch, // Testing wrapper functions -void run_prototype_filter(uint8_t *src, int width, int height, int stride, - const int16_t *filter, int flen, uint8_t *dst) { - uint32_t start, end; - int count = 0; - - start = readtsc(); - do { - convolve(src, width, filter, flen, dst); - src += stride; - dst += stride; - count++; - } while (count < height); - end = readtsc(); - - printf("C version cycles:\t%d\n", end - start); -} - void run_target_filter(uint8_t *src, int width, int height, int stride, struct Filter filter, uint8_t *dst) { uint32_t start, end;