Bug 1358776 - fix building of SkBitmapProcState on ARM NEON. r=jrmuizel
authorLee Salzman <lsalzman@mozilla.com>
Mon, 01 May 2017 13:36:19 -0400
changeset 396154 460138422c29abfc9b6f7987e30f4fe0087ce2d2
parent 396153 ff1cbde070426a1612e62def7104dea7203d4772
child 396155 a1f55676508b925695b531c28bb37f793a48339f
push id1468
push userasasaki@mozilla.com
push dateMon, 05 Jun 2017 19:31:07 +0000
treeherdermozilla-release@0641fc6ee9d1 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjrmuizel
bugs1358776
milestone54.0
Bug 1358776 - fix building of SkBitmapProcState on ARM NEON. r=jrmuizel
gfx/skia/skia/src/core/SkBitmapProcState.cpp
gfx/skia/skia/src/core/SkBitmapProcState_matrixProcs.cpp
--- a/gfx/skia/skia/src/core/SkBitmapProcState.cpp
+++ b/gfx/skia/skia/src/core/SkBitmapProcState.cpp
@@ -295,17 +295,17 @@ bool SkBitmapProcState::chooseScanlinePr
                 index |= 40;
                 fPaintPMColor = SkPreMultiplyColor(fPaintColor);
                 break;
             default:
                 // TODO(dominikg): Should we ever get here? SkASSERT(false) instead?
                 return false;
         }
 
-#if !defined(SK_ARM_HAS_NEON)
+#if !defined(SK_ARM_HAS_NEON) || defined(SK_ARM_HAS_OPTIONAL_NEON)
         static const SampleProc32 gSkBitmapProcStateSample32[] = {
             S32_opaque_D32_nofilter_DXDY,
             S32_alpha_D32_nofilter_DXDY,
             S32_opaque_D32_nofilter_DX,
             S32_alpha_D32_nofilter_DX,
             S32_opaque_D32_filter_DXDY,
             S32_alpha_D32_filter_DXDY,
             S32_opaque_D32_filter_DX,
--- a/gfx/skia/skia/src/core/SkBitmapProcState_matrixProcs.cpp
+++ b/gfx/skia/skia/src/core/SkBitmapProcState_matrixProcs.cpp
@@ -51,17 +51,17 @@ void decal_filter_scale(uint32_t dst[], 
 
 // These are defined in src/opts/SkBitmapProcState_matrixProcs_neon.cpp
 extern const SkBitmapProcState::MatrixProc ClampX_ClampY_Procs_neon[];
 extern const SkBitmapProcState::MatrixProc RepeatX_RepeatY_Procs_neon[];
 
 #endif // defined(SK_ARM_HAS_NEON)
 
 // Compile non-neon code path if needed
-#if !defined(SK_ARM_HAS_NEON)
+#if !defined(SK_ARM_HAS_NEON) || defined(SK_ARM_HAS_OPTIONAL_NEON)
 #define MAKENAME(suffix)        ClampX_ClampY ## suffix
 #define TILEX_PROCF(fx, max)    SkClampMax((fx) >> 16, max)
 #define TILEY_PROCF(fy, max)    SkClampMax((fy) >> 16, max)
 #define TILEX_LOW_BITS(fx, max) (((fx) >> 12) & 0xF)
 #define TILEY_LOW_BITS(fy, max) (((fy) >> 12) & 0xF)
 #define CHECK_FOR_DECAL
 #include "SkBitmapProcState_matrix.h"