VPX: remove step == 16 and filter[3] != 128 checks
from FUN_CONV_1D and FUN_CONV_2D macros. The functions will not be called with these inputs. Change-Id: I67ec75e4edafc0acee70190521a80ea85dfa521b
This commit is contained in:
parent
4e6b5079c6
commit
a229dbc1f0
@ -32,75 +32,74 @@ typedef void filter8_1dfunction (
|
|||||||
const int16_t *filter_y, int y_step_q4, \
|
const int16_t *filter_y, int y_step_q4, \
|
||||||
int w, int h) { \
|
int w, int h) { \
|
||||||
assert(filter[3] != 128); \
|
assert(filter[3] != 128); \
|
||||||
if (step_q4 == 16 && filter[3] != 128) { \
|
assert(step_q4 == 16); \
|
||||||
if (filter[0] || filter[1] || filter[2]) { \
|
if (filter[0] || filter[1] || filter[2]) { \
|
||||||
while (w >= 16) { \
|
while (w >= 16) { \
|
||||||
vpx_filter_block1d16_##dir##8_##avg##opt(src_start, \
|
vpx_filter_block1d16_##dir##8_##avg##opt(src_start, \
|
||||||
src_stride, \
|
src_stride, \
|
||||||
dst, \
|
dst, \
|
||||||
dst_stride, \
|
dst_stride, \
|
||||||
h, \
|
h, \
|
||||||
filter); \
|
filter); \
|
||||||
src += 16; \
|
src += 16; \
|
||||||
dst += 16; \
|
dst += 16; \
|
||||||
w -= 16; \
|
w -= 16; \
|
||||||
} \
|
} \
|
||||||
while (w >= 8) { \
|
while (w >= 8) { \
|
||||||
vpx_filter_block1d8_##dir##8_##avg##opt(src_start, \
|
vpx_filter_block1d8_##dir##8_##avg##opt(src_start, \
|
||||||
src_stride, \
|
src_stride, \
|
||||||
dst, \
|
dst, \
|
||||||
dst_stride, \
|
dst_stride, \
|
||||||
h, \
|
h, \
|
||||||
filter); \
|
filter); \
|
||||||
src += 8; \
|
src += 8; \
|
||||||
dst += 8; \
|
dst += 8; \
|
||||||
w -= 8; \
|
w -= 8; \
|
||||||
} \
|
} \
|
||||||
while (w >= 4) { \
|
while (w >= 4) { \
|
||||||
vpx_filter_block1d4_##dir##8_##avg##opt(src_start, \
|
vpx_filter_block1d4_##dir##8_##avg##opt(src_start, \
|
||||||
src_stride, \
|
src_stride, \
|
||||||
dst, \
|
dst, \
|
||||||
dst_stride, \
|
dst_stride, \
|
||||||
h, \
|
h, \
|
||||||
filter); \
|
filter); \
|
||||||
src += 4; \
|
src += 4; \
|
||||||
dst += 4; \
|
dst += 4; \
|
||||||
w -= 4; \
|
w -= 4; \
|
||||||
} \
|
} \
|
||||||
} else { \
|
} else { \
|
||||||
while (w >= 16) { \
|
while (w >= 16) { \
|
||||||
vpx_filter_block1d16_##dir##2_##avg##opt(src, \
|
vpx_filter_block1d16_##dir##2_##avg##opt(src, \
|
||||||
src_stride, \
|
src_stride, \
|
||||||
dst, \
|
dst, \
|
||||||
dst_stride, \
|
dst_stride, \
|
||||||
h, \
|
h, \
|
||||||
filter); \
|
filter); \
|
||||||
src += 16; \
|
src += 16; \
|
||||||
dst += 16; \
|
dst += 16; \
|
||||||
w -= 16; \
|
w -= 16; \
|
||||||
} \
|
} \
|
||||||
while (w >= 8) { \
|
while (w >= 8) { \
|
||||||
vpx_filter_block1d8_##dir##2_##avg##opt(src, \
|
vpx_filter_block1d8_##dir##2_##avg##opt(src, \
|
||||||
src_stride, \
|
src_stride, \
|
||||||
dst, \
|
dst, \
|
||||||
dst_stride, \
|
dst_stride, \
|
||||||
h, \
|
h, \
|
||||||
filter); \
|
filter); \
|
||||||
src += 8; \
|
src += 8; \
|
||||||
dst += 8; \
|
dst += 8; \
|
||||||
w -= 8; \
|
w -= 8; \
|
||||||
} \
|
} \
|
||||||
while (w >= 4) { \
|
while (w >= 4) { \
|
||||||
vpx_filter_block1d4_##dir##2_##avg##opt(src, \
|
vpx_filter_block1d4_##dir##2_##avg##opt(src, \
|
||||||
src_stride, \
|
src_stride, \
|
||||||
dst, \
|
dst, \
|
||||||
dst_stride, \
|
dst_stride, \
|
||||||
h, \
|
h, \
|
||||||
filter); \
|
filter); \
|
||||||
src += 4; \
|
src += 4; \
|
||||||
dst += 4; \
|
dst += 4; \
|
||||||
w -= 4; \
|
w -= 4; \
|
||||||
} \
|
|
||||||
} \
|
} \
|
||||||
} \
|
} \
|
||||||
}
|
}
|
||||||
@ -115,25 +114,25 @@ void vpx_convolve8_##avg##opt(const uint8_t *src, ptrdiff_t src_stride, \
|
|||||||
assert(filter_y[3] != 128); \
|
assert(filter_y[3] != 128); \
|
||||||
assert(w <= 64); \
|
assert(w <= 64); \
|
||||||
assert(h <= 64); \
|
assert(h <= 64); \
|
||||||
if (x_step_q4 == 16 && y_step_q4 == 16) { \
|
assert(x_step_q4 == 16); \
|
||||||
if (filter_x[0] || filter_x[1] || filter_x[2] || filter_x[3] == 128 || \
|
assert(y_step_q4 == 16); \
|
||||||
filter_y[0] || filter_y[1] || filter_y[2] || filter_y[3] == 128) { \
|
if (filter_x[0] || filter_x[1] || filter_x[2]|| \
|
||||||
DECLARE_ALIGNED(16, uint8_t, fdata2[64 * 71]); \
|
filter_y[0] || filter_y[1] || filter_y[2]) { \
|
||||||
vpx_convolve8_horiz_##opt(src - 3 * src_stride, src_stride, fdata2, 64, \
|
DECLARE_ALIGNED(16, uint8_t, fdata2[64 * 71]); \
|
||||||
filter_x, x_step_q4, filter_y, y_step_q4, \
|
vpx_convolve8_horiz_##opt(src - 3 * src_stride, src_stride, fdata2, 64, \
|
||||||
w, h + 7); \
|
filter_x, x_step_q4, filter_y, y_step_q4, \
|
||||||
vpx_convolve8_##avg##vert_##opt(fdata2 + 3 * 64, 64, dst, dst_stride, \
|
w, h + 7); \
|
||||||
filter_x, x_step_q4, filter_y, \
|
vpx_convolve8_##avg##vert_##opt(fdata2 + 3 * 64, 64, dst, dst_stride, \
|
||||||
y_step_q4, w, h); \
|
filter_x, x_step_q4, filter_y, \
|
||||||
} else { \
|
y_step_q4, w, h); \
|
||||||
DECLARE_ALIGNED(16, uint8_t, fdata2[64 * 65]); \
|
} else { \
|
||||||
vpx_convolve8_horiz_##opt(src, src_stride, fdata2, 64, \
|
DECLARE_ALIGNED(16, uint8_t, fdata2[64 * 65]); \
|
||||||
filter_x, x_step_q4, filter_y, y_step_q4, \
|
vpx_convolve8_horiz_##opt(src, src_stride, fdata2, 64, \
|
||||||
w, h + 1); \
|
filter_x, x_step_q4, filter_y, y_step_q4, \
|
||||||
vpx_convolve8_##avg##vert_##opt(fdata2, 64, dst, dst_stride, \
|
w, h + 1); \
|
||||||
filter_x, x_step_q4, filter_y, \
|
vpx_convolve8_##avg##vert_##opt(fdata2, 64, dst, dst_stride, \
|
||||||
y_step_q4, w, h); \
|
filter_x, x_step_q4, filter_y, \
|
||||||
} \
|
y_step_q4, w, h); \
|
||||||
} \
|
} \
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user