aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar Mike Klein <mtklein@chromium.org>2016-12-14 13:39:34 +0000
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2016-12-14 13:39:48 +0000
commit0d413f0f455c984eacf46c9d5cb0978d7b73357f (patch)
tree613aa672794ab10bfffc0fa2ba9e113775a59ad3
parentd37d5d96493604c12cfaa2d64bcbd32c41b01f3b (diff)
Revert "Revert "SkNx basically always is fast now.""
This reverts commit 8ba64d1996ba6c9ecfb12132cdab7d5d99af7456. Reason for revert: does not appear to have been blocking the roll. Original change's description: > Revert "SkNx basically always is fast now." > > This reverts commit 21f783829619186442041de6008f7f58f4f6250d. > > Reason for revert: roll? > > Original change's description: > > SkNx basically always is fast now. > > > > We had this SKNX_IS_FAST hanging around from before Chrome always built with NEON. > > > > CQ_INCLUDE_TRYBOTS=skia.primary:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD > > > > Change-Id: Ia5cc0323b3ef052192e2903f961aee11eb3f82d8 > > Reviewed-on: https://skia-review.googlesource.com/5946 > > Commit-Queue: Mike Klein <mtklein@chromium.org> > > Reviewed-by: Mike Reed <reed@google.com> > > Reviewed-by: Florin Malita <fmalita@chromium.org> > > > > TBR=mtklein@chromium.org,fmalita@chromium.org,reed@google.com,reviews@skia.org > NOPRESUBMIT=true > NOTREECHECKS=true > NOTRY=true > > Change-Id: I0e57285c68eae0a64213fe29ea4cca5519777954 > Reviewed-on: https://skia-review.googlesource.com/6040 > Commit-Queue: Mike Klein <mtklein@chromium.org> > Reviewed-by: Mike Klein <mtklein@chromium.org> > TBR=mtklein@chromium.org,reviews@skia.org,fmalita@chromium.org,reed@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Change-Id: I230dd4c2abb2d14ffc302be5376b9eaacbbeafcc Reviewed-on: https://skia-review.googlesource.com/6026 Commit-Queue: Mike Klein <mtklein@chromium.org> Reviewed-by: Mike Klein <mtklein@chromium.org>
-rw-r--r--src/core/SkMipMap.cpp9
-rw-r--r--src/effects/gradients/SkLinearGradient.cpp3
-rw-r--r--src/opts/SkNx_neon.h2
-rw-r--r--src/opts/SkNx_sse.h2
4 files changed, 0 insertions, 16 deletions
diff --git a/src/core/SkMipMap.cpp b/src/core/SkMipMap.cpp
index ba3cb18749..987949fea0 100644
--- a/src/core/SkMipMap.cpp
+++ b/src/core/SkMipMap.cpp
@@ -23,7 +23,6 @@
struct ColorTypeFilter_8888 {
typedef uint32_t Type;
-#if defined(SKNX_IS_FAST)
static Sk4h Expand(uint32_t x) {
return SkNx_cast<uint16_t>(Sk4b::Load(&x));
}
@@ -32,14 +31,6 @@ struct ColorTypeFilter_8888 {
SkNx_cast<uint8_t>(x).store(&r);
return r;
}
-#else
- static uint64_t Expand(uint32_t x) {
- return (x & 0xFF00FF) | ((uint64_t)(x & 0xFF00FF00) << 24);
- }
- static uint32_t Compact(uint64_t x) {
- return (uint32_t)((x & 0xFF00FF) | ((x >> 24) & 0xFF00FF00));
- }
-#endif
};
struct ColorTypeFilter_S32 {
diff --git a/src/effects/gradients/SkLinearGradient.cpp b/src/effects/gradients/SkLinearGradient.cpp
index 5994fd6d0c..4bb640de91 100644
--- a/src/effects/gradients/SkLinearGradient.cpp
+++ b/src/effects/gradients/SkLinearGradient.cpp
@@ -276,15 +276,12 @@ void SkLinearGradient::LinearGradientContext::shadeSpan(int x, int y, SkPMColor*
SkASSERT(count > 0);
const SkLinearGradient& linearGradient = static_cast<const SkLinearGradient&>(fShader);
-// Only use the Sk4f impl when known to be fast.
-#if defined(SKNX_IS_FAST)
if (SkShader::kClamp_TileMode == linearGradient.fTileMode &&
kLinear_MatrixClass == fDstToIndexClass)
{
this->shade4_clamp(x, y, dstC, count);
return;
}
-#endif
SkPoint srcPt;
SkMatrix::MapXYProc dstProc = fDstToIndexProc;
diff --git a/src/opts/SkNx_neon.h b/src/opts/SkNx_neon.h
index 83873a76e1..6836a527e7 100644
--- a/src/opts/SkNx_neon.h
+++ b/src/opts/SkNx_neon.h
@@ -10,8 +10,6 @@
#include <arm_neon.h>
-#define SKNX_IS_FAST
-
namespace {
// ARMv8 has vrndmq_f32 to floor 4 floats. Here we emulate it:
diff --git a/src/opts/SkNx_sse.h b/src/opts/SkNx_sse.h
index 554d65d5ce..394115626e 100644
--- a/src/opts/SkNx_sse.h
+++ b/src/opts/SkNx_sse.h
@@ -13,8 +13,6 @@
// This file may assume <= SSE2, but must check SK_CPU_SSE_LEVEL for anything more recent.
// If you do, make sure this is in a static inline function... anywhere else risks violating ODR.
-#define SKNX_IS_FAST
-
namespace {
template <>