Call the C function to finish off lossless SSE loops only when necessary.

Change-Id: I4e221d80879dc9c90c24d69a40bc5811d73787ad
This commit is contained in:
Vincent Rabaud
2016-12-21 14:25:54 +01:00
parent 875fafc191
commit 1cb638010c
3 changed files with 75 additions and 25 deletions

View File

@ -32,7 +32,9 @@ static void SubtractGreenFromBlueAndRed(uint32_t* argb_data, int num_pixels) {
_mm_storeu_si128((__m128i*)&argb_data[i], out);
}
// fallthrough and finish off with plain-C
VP8LSubtractGreenFromBlueAndRed_C(argb_data + i, num_pixels - i);
if (i != num_pixels) {
VP8LSubtractGreenFromBlueAndRed_C(argb_data + i, num_pixels - i);
}
}
//------------------------------------------------------------------------------