From: Johann Date: Fri, 14 Apr 2017 21:37:58 +0000 (-0700) Subject: sad avg: align intermediate buffer X-Git-Tag: v1.7.0~559 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=069b772915215c11d87ed41d96aa9bf9f9c398d1;p=libvpx sad avg: align intermediate buffer comp_avg_pred has started declaring a requirement for aligned buffers. BUG=webm:1390 Change-Id: Idaf6667498ea343e8d49b32bc9d8b9d0aa43ef5c --- diff --git a/vpx_dsp/sad.c b/vpx_dsp/sad.c index c80ef729b..6ceb37e43 100644 --- a/vpx_dsp/sad.c +++ b/vpx_dsp/sad.c @@ -39,7 +39,7 @@ static INLINE unsigned int sad(const uint8_t *a, int a_stride, const uint8_t *b, unsigned int vpx_sad##m##x##n##_avg_c(const uint8_t *src, int src_stride, \ const uint8_t *ref, int ref_stride, \ const uint8_t *second_pred) { \ - uint8_t comp_pred[m * n]; \ + DECLARE_ALIGNED(16, uint8_t, comp_pred[m * n]); \ vpx_comp_avg_pred_c(comp_pred, second_pred, m, n, ref, ref_stride); \ return sad(src, src_stride, comp_pred, m, m, n); \ } @@ -178,7 +178,7 @@ static INLINE unsigned int highbd_sadb(const uint8_t *a8, int a_stride, unsigned int vpx_highbd_sad##m##x##n##_avg_c( \ const uint8_t *src, int src_stride, const uint8_t *ref, int ref_stride, \ const uint8_t *second_pred) { \ - uint16_t comp_pred[m * n]; \ + DECLARE_ALIGNED(16, uint16_t, comp_pred[m * n]); \ vpx_highbd_comp_avg_pred_c(comp_pred, second_pred, m, n, ref, ref_stride); \ return highbd_sadb(src, src_stride, comp_pred, m, m, n); \ }