aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHoward M. Harte <hharte@cyngn.com>2015-04-08 19:31:58 -0700
committerHoward M. Harte <hharte@cyngn.com>2015-04-10 09:59:18 -0700
commit8a403aba9bb5c361476daedbb472695f435a394c (patch)
tree7a672afa98ba9db53e5a820c5ade15d4a3629ac9
parent2e87b697d21be8446c70888a1ac16733ee7bcd35 (diff)
downloadandroid_external_skia-stable/cm-12.0-YNG3C.tar.gz
android_external_skia-stable/cm-12.0-YNG3C.tar.bz2
android_external_skia-stable/cm-12.0-YNG3C.zip
x86: conditionalize code for ARM neon optimizationstable/cm-12.0-YNG3C
Conditionalize code for ARM neon optimizations so that other architectures compile correctly. Change-Id: I538b937734f3e6a3b318e40fcc45579bfa899f28
-rw-r--r--src/core/SkBitmapProcShader.cpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/core/SkBitmapProcShader.cpp b/src/core/SkBitmapProcShader.cpp
index a6d36a1287..4650800493 100644
--- a/src/core/SkBitmapProcShader.cpp
+++ b/src/core/SkBitmapProcShader.cpp
@@ -18,11 +18,9 @@
#endif
#include "SkBitmapProcState_utils.h"
-#if !SK_ARM_NEON_IS_NONE
-#if !defined(__LP64__)
+#if defined(__ARM_NEON__) && !defined(__LP64__)
extern void Clamp_S32_Opaque_D32_filter_DX_shaderproc_neon(const SkBitmapProcState&, int, int, uint32_t*, int);
#endif
-#endif
bool SkBitmapProcShader::CanDo(const SkBitmap& bm, TileMode tx, TileMode ty) {
switch (bm.colorType()) {
@@ -234,8 +232,7 @@ void SkBitmapProcShader::BitmapProcShaderContext::shadeSpan(int x, int y, SkPMCo
int count) {
const SkBitmapProcState& state = *fState;
if (state.getShaderProc32()) {
-#if !SK_ARM_NEON_IS_NONE
-#if !defined(__LP64__)
+#if defined(__ARM_NEON__) && !defined(__LP64__)
if (state.getShaderProc32() == Clamp_S32_Opaque_D32_filter_DX_shaderproc_neon) {
if (checkDecal(state, x, y, count)) {
state.getShaderProc32()(state, x, y, dstC, count);
@@ -243,7 +240,6 @@ void SkBitmapProcShader::BitmapProcShaderContext::shadeSpan(int x, int y, SkPMCo
}
} else
#endif
-#endif
{
state.getShaderProc32()(state, x, y, dstC, count);
return;