Commit 64620cd2 authored by Yaowu Xu's avatar Yaowu Xu
Browse files

Help msvc 2017 compiler to generate correct code

This loop is wrongly vectorized by the MSVC2017 compiler, this change
is a work-around for the compiler bug.

Change-Id: Ie4c8403965c3e4cd6d70eb3dbc92148f5272f0ab
(cherry picked from commit 5b33d7184bf319d9c10e34ef0fdcdd244d2fdb56)
parent e67377b3
......@@ -356,20 +356,17 @@ highbd_sadMxNx4D(128, 32)
int width, int height) {
int y, x;
unsigned int sad = 0;
for (y = 0; y < height; y++) {
for (x = 0; x < width; x++) {
const uint8_t pred = AOM_BLEND_A64(m[x], a[x], b[x]);
const int16_t pred = AOM_BLEND_A64(m[x], a[x], b[x]);
sad += abs(pred - src[x]);
}
src += src_stride;
a += a_stride;
b += b_stride;
m += m_stride;
}
sad = (sad + 31) >> 6;
return sad;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment