diff options
author | Torne (Richard Coles) <torne@google.com> | 2013-06-19 11:58:07 +0100 |
---|---|---|
committer | Torne (Richard Coles) <torne@google.com> | 2013-06-19 11:58:07 +0100 |
commit | 7d4cd473f85ac64c3747c96c277f9e506a0d2246 (patch) | |
tree | f5fecd524f5ac22cd38bcc6713b81f666730d5a1 /skia | |
parent | 84f2b2352908c30e40ae12ffe850dd8470f6c048 (diff) | |
download | chromium_org-7d4cd473f85ac64c3747c96c277f9e506a0d2246.tar.gz |
Merge from Chromium at DEPS revision r207203
This commit was generated by merge_to_master.py.
Change-Id: I5fbb6854d092096c4d39edc2865a48be1b53c418
Diffstat (limited to 'skia')
-rw-r--r-- | skia/ext/image_operations.cc | 4 | ||||
-rw-r--r-- | skia/ext/image_operations_unittest.cc | 11 | ||||
-rw-r--r-- | skia/ext/lazy_pixel_ref.h | 4 | ||||
-rw-r--r-- | skia/ext/lazy_pixel_ref_utils_unittest.cc | 5 | ||||
-rw-r--r-- | skia/skia.gyp | 89 | ||||
-rw-r--r-- | skia/skia.target.darwin-arm.mk | 6 | ||||
-rw-r--r-- | skia/skia.target.darwin-mips.mk | 1 | ||||
-rw-r--r-- | skia/skia.target.darwin-x86.mk | 1 | ||||
-rw-r--r-- | skia/skia.target.linux-arm.mk | 6 | ||||
-rw-r--r-- | skia/skia.target.linux-mips.mk | 1 | ||||
-rw-r--r-- | skia/skia.target.linux-x86.mk | 1 | ||||
-rw-r--r-- | skia/skia_opts.target.darwin-arm.mk | 3 | ||||
-rw-r--r-- | skia/skia_opts.target.darwin-mips.mk | 1 | ||||
-rw-r--r-- | skia/skia_opts.target.darwin-x86.mk | 1 | ||||
-rw-r--r-- | skia/skia_opts.target.linux-arm.mk | 3 | ||||
-rw-r--r-- | skia/skia_opts.target.linux-mips.mk | 1 | ||||
-rw-r--r-- | skia/skia_opts.target.linux-x86.mk | 1 | ||||
-rw-r--r-- | skia/skia_opts_neon.target.darwin-arm.mk | 161 | ||||
-rw-r--r-- | skia/skia_opts_neon.target.linux-arm.mk | 161 | ||||
-rw-r--r-- | skia/skia_test_expectations.txt | 10 |
20 files changed, 446 insertions, 25 deletions
diff --git a/skia/ext/image_operations.cc b/skia/ext/image_operations.cc index b1cdade0ad..f30a85dd14 100644 --- a/skia/ext/image_operations.cc +++ b/skia/ext/image_operations.cc @@ -496,8 +496,8 @@ SkBitmap ImageOperations::ResizeBasic(const SkBitmap& source, (method <= ImageOperations::RESIZE_LAST_ALGORITHM_METHOD)); SkAutoLockPixels locker(source); - if (!source.readyToDraw()) - return SkBitmap(); + if (!source.readyToDraw() || source.config() != SkBitmap::kARGB_8888_Config) + return SkBitmap(); ResizeFilter filter(method, source.width(), source.height(), dest_width, dest_height, dest_subset); diff --git a/skia/ext/image_operations_unittest.cc b/skia/ext/image_operations_unittest.cc index 9fce74bef5..c7069e2817 100644 --- a/skia/ext/image_operations_unittest.cc +++ b/skia/ext/image_operations_unittest.cc @@ -461,6 +461,17 @@ TEST(ImageOperations, HalveSubset) { } } +TEST(ImageOperations, InvalidParams) { + // Make our source bitmap. + SkBitmap src; + src.setConfig(SkBitmap::kA8_Config, 16, 34); + src.allocPixels(); + + // Scale it, don't die. + SkBitmap full_results = skia::ImageOperations::Resize( + src, skia::ImageOperations::RESIZE_BOX, 10, 20); +} + // Resamples an image to the same image, it should give the same result. TEST(ImageOperations, ResampleToSameHamming1) { CheckResampleToSame(skia::ImageOperations::RESIZE_HAMMING1); diff --git a/skia/ext/lazy_pixel_ref.h b/skia/ext/lazy_pixel_ref.h index c8a3a5820f..fff4c385ad 100644 --- a/skia/ext/lazy_pixel_ref.h +++ b/skia/ext/lazy_pixel_ref.h @@ -26,6 +26,10 @@ class SK_API LazyPixelRef : public SkPixelRef { // given clipping rect. Returns true is succeeded, or false otherwise. virtual bool PrepareToDecode(const PrepareParams& params) = 0; + // Returns true if this pixel ref is already in the ImageDecodingStore's + // cache, false otherwise. Much cheaper than PrepareToDecode(). + virtual bool MaybeDecoded() = 0; + // Start decoding the image. virtual void Decode() = 0; }; diff --git a/skia/ext/lazy_pixel_ref_utils_unittest.cc b/skia/ext/lazy_pixel_ref_utils_unittest.cc index 2854ef0b73..a9f60a23ab 100644 --- a/skia/ext/lazy_pixel_ref_utils_unittest.cc +++ b/skia/ext/lazy_pixel_ref_utils_unittest.cc @@ -48,6 +48,7 @@ class TestLazyPixelRef : public skia::LazyPixelRef { virtual void* onLockPixels(SkColorTable** color_table) OVERRIDE; virtual void onUnlockPixels() OVERRIDE {} virtual bool PrepareToDecode(const PrepareParams& params) OVERRIDE; + virtual bool MaybeDecoded() OVERRIDE; virtual SkPixelRef* deepCopy(SkBitmap::Config config, const SkIRect* subset) OVERRIDE; virtual void Decode() OVERRIDE {} @@ -120,6 +121,10 @@ bool TestLazyPixelRef::PrepareToDecode(const PrepareParams& params) { return true; } +bool TestLazyPixelRef::MaybeDecoded() { + return true; +} + SkPixelRef* TestLazyPixelRef::deepCopy(SkBitmap::Config config, const SkIRect* subset) { this->ref(); diff --git a/skia/skia.gyp b/skia/skia.gyp index cc80423cb8..d55a11395e 100644 --- a/skia/skia.gyp +++ b/skia/skia.gyp @@ -359,6 +359,19 @@ '__ARM_HAVE_NEON', ], }], + [ 'target_arch == "arm" and arm_version >= 7 and arm_neon_optional == 1', { + 'defines': [ + '__ARM_HAVE_OPTIONAL_NEON_SUPPORT', + ], + }], + [ 'OS == "android" and target_arch == "arm"', { + 'sources': [ + '../third_party/skia/src/core/SkUtilsArm.cpp', + ], + 'includes': [ + '../build/android/cpufeatures.gypi', + ], + }], [ 'target_arch == "arm" or target_arch == "mipsel"', { 'sources!': [ '../third_party/skia/src/opts/opts_check_SSE2.cpp' @@ -690,6 +703,13 @@ 'defines': [ '__ARM_HAVE_NEON', ], + }], + [ 'arm_version >= 7 and arm_neon_optional == 1', { + 'defines': [ + '__ARM_HAVE_OPTIONAL_NEON_SUPPORT', + ], + }], + [ 'arm_version >= 7 and (arm_neon == 1 or arm_neon_optional == 1)', { 'cflags': [ # The neon assembly contains conditional instructions which # aren't enclosed in an IT block. The assembler complains @@ -697,6 +717,9 @@ # See #86592. '-Wa,-mimplicit-it=always', ], + 'dependencies': [ + 'skia_opts_neon', + ] }], ], # The assembly uses the frame pointer register (r7 in Thumb/r11 in @@ -715,20 +738,9 @@ '../third_party/skia/src/opts/SkBitmapProcState_opts_arm.cpp', ], }], - [ 'target_arch == "arm" and (arm_version < 7 or arm_neon == 0)', { + [ 'target_arch == "arm" and (arm_version < 7 or (arm_neon == 0 and arm_neon_optional == 1))', { 'sources': [ '../third_party/skia/src/opts/memset.arm.S', - ], - }], - [ 'target_arch == "arm" and arm_version >= 7 and arm_neon == 1', { - 'sources': [ - '../third_party/skia/src/opts/memset16_neon.S', - '../third_party/skia/src/opts/memset32_neon.S', - '../third_party/skia/src/opts/SkBitmapProcState_arm_neon.cpp', - '../third_party/skia/src/opts/SkBitmapProcState_matrixProcs_neon.cpp', - '../third_party/skia/src/opts/SkBitmapProcState_matrix_clamp_neon.h', - '../third_party/skia/src/opts/SkBitmapProcState_matrix_repeat_neon.h', - '../third_party/skia/src/opts/SkBlitRow_opts_arm_neon.cpp', ], }], [ 'target_arch == "arm" and arm_version < 6', { @@ -803,6 +815,59 @@ }], ], }, + # NEON code must be compiled with -mfpu=neon which also affects scalar + # code. To support dynamic NEON code paths, we need to build all + # NEON-specific sources in a separate static library. The situation + # is very similar to the SSSE3 one. + { + 'target_name': 'skia_opts_neon', + 'type': 'static_library', + 'include_dirs': [ + '..', + 'config', + '../third_party/skia/include/config', + '../third_party/skia/include/core', + '../third_party/skia/src/core', + '../third_party/skia/src/opts', + ], + 'cflags!': [ + '-fno-omit-frame-pointer', + '-mfpu=vfp', # remove them all, just in case. + '-mfpu=vfpv3', + '-mfpu=vfpv3-d16', + ], + 'cflags': [ + '-mfpu=neon', + '-fomit-frame-pointer', + ], + 'ldflags': [ + '-march=armv7-a', + '-Wl,--fix-cortex-a8', + ], + 'conditions': [ + ['arm_neon == 1', { + 'defines': [ + '__ARM_HAVE_NEON', + ], + }], + ['arm_neon_optional == 1', { + 'defines': [ + '__ARM_HAVE_OPTIONAL_NEON_SUPPORT', + ], + }], + ['target_arch == "arm" and (arm_neon == 1 or arm_neon_optional == 1)', { + 'sources': [ + '../third_party/skia/src/opts/memset16_neon.S', + '../third_party/skia/src/opts/memset32_neon.S', + '../third_party/skia/src/opts/SkBitmapProcState_arm_neon.cpp', + '../third_party/skia/src/opts/SkBitmapProcState_matrixProcs_neon.cpp', + '../third_party/skia/src/opts/SkBitmapProcState_matrix_clamp_neon.h', + '../third_party/skia/src/opts/SkBitmapProcState_matrix_repeat_neon.h', + '../third_party/skia/src/opts/SkBlitRow_opts_arm_neon.cpp', + ], + }], + ], + }, { 'target_name': 'image_operations_bench', 'type': 'executable', diff --git a/skia/skia.target.darwin-arm.mk b/skia/skia.target.darwin-arm.mk index 2851017ece..a3ce883fa5 100644 --- a/skia/skia.target.darwin-arm.mk +++ b/skia/skia.target.darwin-arm.mk @@ -394,6 +394,7 @@ LOCAL_SRC_FILES := \ third_party/skia/src/image/SkImage_Gpu.cpp \ third_party/skia/src/image/SkSurface_Gpu.cpp \ third_party/skia/src/gpu/gl/SkGLContextHelper.cpp \ + third_party/skia/src/core/SkUtilsArm.cpp \ third_party/skia/src/ports/SkFontHost_fontconfig.cpp @@ -436,6 +437,7 @@ MY_CFLAGS := \ MY_CFLAGS_C := MY_DEFS := \ + '-DANGLE_DX11' \ '-D_FILE_OFFSET_BITS=64' \ '-DUSE_LINUX_BREAKPAD' \ '-DNO_TCMALLOC' \ @@ -461,6 +463,7 @@ MY_DEFS := \ '-DSK_GAMMA_APPLY_TO_A8' \ '-DSK_GAMMA_EXPONENT=1.4' \ '-DSK_GAMMA_CONTRAST=0.0' \ + '-D__ARM_HAVE_OPTIONAL_NEON_SUPPORT' \ '-DHAVE_PTHREADS' \ '-DOS_ANDROID' \ '-DSK_BUILD_FOR_ANDROID' \ @@ -541,7 +544,8 @@ LOCAL_LDFLAGS := \ -Wl,--as-needed -LOCAL_STATIC_LIBRARIES := +LOCAL_STATIC_LIBRARIES := \ + cpufeatures # Enable grouping to fix circular references LOCAL_GROUP_STATIC_LIBRARIES := true diff --git a/skia/skia.target.darwin-mips.mk b/skia/skia.target.darwin-mips.mk index 287a31f270..6e85641b50 100644 --- a/skia/skia.target.darwin-mips.mk +++ b/skia/skia.target.darwin-mips.mk @@ -439,6 +439,7 @@ MY_CFLAGS := \ MY_CFLAGS_C := MY_DEFS := \ + '-DANGLE_DX11' \ '-D_FILE_OFFSET_BITS=64' \ '-DNO_TCMALLOC' \ '-DDISABLE_NACL' \ diff --git a/skia/skia.target.darwin-x86.mk b/skia/skia.target.darwin-x86.mk index b61fd58b91..f7e63ed2fb 100644 --- a/skia/skia.target.darwin-x86.mk +++ b/skia/skia.target.darwin-x86.mk @@ -439,6 +439,7 @@ MY_CFLAGS := \ MY_CFLAGS_C := MY_DEFS := \ + '-DANGLE_DX11' \ '-D_FILE_OFFSET_BITS=64' \ '-DUSE_LINUX_BREAKPAD' \ '-DNO_TCMALLOC' \ diff --git a/skia/skia.target.linux-arm.mk b/skia/skia.target.linux-arm.mk index 2851017ece..a3ce883fa5 100644 --- a/skia/skia.target.linux-arm.mk +++ b/skia/skia.target.linux-arm.mk @@ -394,6 +394,7 @@ LOCAL_SRC_FILES := \ third_party/skia/src/image/SkImage_Gpu.cpp \ third_party/skia/src/image/SkSurface_Gpu.cpp \ third_party/skia/src/gpu/gl/SkGLContextHelper.cpp \ + third_party/skia/src/core/SkUtilsArm.cpp \ third_party/skia/src/ports/SkFontHost_fontconfig.cpp @@ -436,6 +437,7 @@ MY_CFLAGS := \ MY_CFLAGS_C := MY_DEFS := \ + '-DANGLE_DX11' \ '-D_FILE_OFFSET_BITS=64' \ '-DUSE_LINUX_BREAKPAD' \ '-DNO_TCMALLOC' \ @@ -461,6 +463,7 @@ MY_DEFS := \ '-DSK_GAMMA_APPLY_TO_A8' \ '-DSK_GAMMA_EXPONENT=1.4' \ '-DSK_GAMMA_CONTRAST=0.0' \ + '-D__ARM_HAVE_OPTIONAL_NEON_SUPPORT' \ '-DHAVE_PTHREADS' \ '-DOS_ANDROID' \ '-DSK_BUILD_FOR_ANDROID' \ @@ -541,7 +544,8 @@ LOCAL_LDFLAGS := \ -Wl,--as-needed -LOCAL_STATIC_LIBRARIES := +LOCAL_STATIC_LIBRARIES := \ + cpufeatures # Enable grouping to fix circular references LOCAL_GROUP_STATIC_LIBRARIES := true diff --git a/skia/skia.target.linux-mips.mk b/skia/skia.target.linux-mips.mk index 287a31f270..6e85641b50 100644 --- a/skia/skia.target.linux-mips.mk +++ b/skia/skia.target.linux-mips.mk @@ -439,6 +439,7 @@ MY_CFLAGS := \ MY_CFLAGS_C := MY_DEFS := \ + '-DANGLE_DX11' \ '-D_FILE_OFFSET_BITS=64' \ '-DNO_TCMALLOC' \ '-DDISABLE_NACL' \ diff --git a/skia/skia.target.linux-x86.mk b/skia/skia.target.linux-x86.mk index b61fd58b91..f7e63ed2fb 100644 --- a/skia/skia.target.linux-x86.mk +++ b/skia/skia.target.linux-x86.mk @@ -439,6 +439,7 @@ MY_CFLAGS := \ MY_CFLAGS_C := MY_DEFS := \ + '-DANGLE_DX11' \ '-D_FILE_OFFSET_BITS=64' \ '-DUSE_LINUX_BREAKPAD' \ '-DNO_TCMALLOC' \ diff --git a/skia/skia_opts.target.darwin-arm.mk b/skia/skia_opts.target.darwin-arm.mk index 22f6e6911b..37f4001b63 100644 --- a/skia/skia_opts.target.darwin-arm.mk +++ b/skia/skia_opts.target.darwin-arm.mk @@ -40,6 +40,7 @@ MY_CFLAGS := \ -pipe \ -fPIC \ -fomit-frame-pointer \ + -Wa,-mimplicit-it=always \ -Wno-format \ -fno-tree-sra \ -fuse-ld=gold \ @@ -68,6 +69,7 @@ MY_CFLAGS := \ MY_CFLAGS_C := MY_DEFS := \ + '-DANGLE_DX11' \ '-D_FILE_OFFSET_BITS=64' \ '-DUSE_LINUX_BREAKPAD' \ '-DNO_TCMALLOC' \ @@ -80,6 +82,7 @@ MY_DEFS := \ '-DENABLE_EGLIMAGE=1' \ '-DENABLE_LANGUAGE_DETECTION=1' \ '-DSK_BUILD_FOR_ANDROID' \ + '-D__ARM_HAVE_OPTIONAL_NEON_SUPPORT' \ '-DANDROID' \ '-D__GNU_SOURCE=1' \ '-DUSE_STLPORT=1' \ diff --git a/skia/skia_opts.target.darwin-mips.mk b/skia/skia_opts.target.darwin-mips.mk index 38f093d8c2..f7917d80c0 100644 --- a/skia/skia_opts.target.darwin-mips.mk +++ b/skia/skia_opts.target.darwin-mips.mk @@ -74,6 +74,7 @@ MY_CFLAGS := \ MY_CFLAGS_C := MY_DEFS := \ + '-DANGLE_DX11' \ '-D_FILE_OFFSET_BITS=64' \ '-DNO_TCMALLOC' \ '-DDISABLE_NACL' \ diff --git a/skia/skia_opts.target.darwin-x86.mk b/skia/skia_opts.target.darwin-x86.mk index 3bbb26f4fb..5a3adc0de6 100644 --- a/skia/skia_opts.target.darwin-x86.mk +++ b/skia/skia_opts.target.darwin-x86.mk @@ -73,6 +73,7 @@ MY_CFLAGS := \ MY_CFLAGS_C := MY_DEFS := \ + '-DANGLE_DX11' \ '-D_FILE_OFFSET_BITS=64' \ '-DUSE_LINUX_BREAKPAD' \ '-DNO_TCMALLOC' \ diff --git a/skia/skia_opts.target.linux-arm.mk b/skia/skia_opts.target.linux-arm.mk index 22f6e6911b..37f4001b63 100644 --- a/skia/skia_opts.target.linux-arm.mk +++ b/skia/skia_opts.target.linux-arm.mk @@ -40,6 +40,7 @@ MY_CFLAGS := \ -pipe \ -fPIC \ -fomit-frame-pointer \ + -Wa,-mimplicit-it=always \ -Wno-format \ -fno-tree-sra \ -fuse-ld=gold \ @@ -68,6 +69,7 @@ MY_CFLAGS := \ MY_CFLAGS_C := MY_DEFS := \ + '-DANGLE_DX11' \ '-D_FILE_OFFSET_BITS=64' \ '-DUSE_LINUX_BREAKPAD' \ '-DNO_TCMALLOC' \ @@ -80,6 +82,7 @@ MY_DEFS := \ '-DENABLE_EGLIMAGE=1' \ '-DENABLE_LANGUAGE_DETECTION=1' \ '-DSK_BUILD_FOR_ANDROID' \ + '-D__ARM_HAVE_OPTIONAL_NEON_SUPPORT' \ '-DANDROID' \ '-D__GNU_SOURCE=1' \ '-DUSE_STLPORT=1' \ diff --git a/skia/skia_opts.target.linux-mips.mk b/skia/skia_opts.target.linux-mips.mk index 38f093d8c2..f7917d80c0 100644 --- a/skia/skia_opts.target.linux-mips.mk +++ b/skia/skia_opts.target.linux-mips.mk @@ -74,6 +74,7 @@ MY_CFLAGS := \ MY_CFLAGS_C := MY_DEFS := \ + '-DANGLE_DX11' \ '-D_FILE_OFFSET_BITS=64' \ '-DNO_TCMALLOC' \ '-DDISABLE_NACL' \ diff --git a/skia/skia_opts.target.linux-x86.mk b/skia/skia_opts.target.linux-x86.mk index 3bbb26f4fb..5a3adc0de6 100644 --- a/skia/skia_opts.target.linux-x86.mk +++ b/skia/skia_opts.target.linux-x86.mk @@ -73,6 +73,7 @@ MY_CFLAGS := \ MY_CFLAGS_C := MY_DEFS := \ + '-DANGLE_DX11' \ '-D_FILE_OFFSET_BITS=64' \ '-DUSE_LINUX_BREAKPAD' \ '-DNO_TCMALLOC' \ diff --git a/skia/skia_opts_neon.target.darwin-arm.mk b/skia/skia_opts_neon.target.darwin-arm.mk new file mode 100644 index 0000000000..84ded4a020 --- /dev/null +++ b/skia/skia_opts_neon.target.darwin-arm.mk @@ -0,0 +1,161 @@ +# This file is generated by gyp; do not edit. + +include $(CLEAR_VARS) + +LOCAL_MODULE_CLASS := STATIC_LIBRARIES +LOCAL_MODULE := skia_skia_opts_neon_gyp +LOCAL_MODULE_SUFFIX := .a +LOCAL_MODULE_TAGS := optional +gyp_intermediate_dir := $(call local-intermediates-dir) +gyp_shared_intermediate_dir := $(call intermediates-dir-for,GYP,shared) + +# Make sure our deps are built first. +GYP_TARGET_DEPENDENCIES := + +GYP_GENERATED_OUTPUTS := + +# Make sure our deps and generated files are built first. +LOCAL_ADDITIONAL_DEPENDENCIES := $(GYP_TARGET_DEPENDENCIES) $(GYP_GENERATED_OUTPUTS) + +LOCAL_GENERATED_SOURCES := + +GYP_COPIED_SOURCE_ORIGIN_DIRS := + +LOCAL_SRC_FILES := \ + third_party/skia/src/opts/memset16_neon.S \ + third_party/skia/src/opts/memset32_neon.S \ + third_party/skia/src/opts/SkBitmapProcState_arm_neon.cpp \ + third_party/skia/src/opts/SkBitmapProcState_matrixProcs_neon.cpp \ + third_party/skia/src/opts/SkBlitRow_opts_arm_neon.cpp + + +# Flags passed to both C and C++ files. +MY_CFLAGS := \ + -fstack-protector \ + --param=ssp-buffer-size=4 \ + -fno-exceptions \ + -fno-strict-aliasing \ + -Wno-unused-parameter \ + -Wno-missing-field-initializers \ + -fvisibility=hidden \ + -pipe \ + -fPIC \ + -mfpu=neon \ + -fomit-frame-pointer \ + -Wno-format \ + -fno-tree-sra \ + -fuse-ld=gold \ + -Wno-psabi \ + -ffunction-sections \ + -funwind-tables \ + -g \ + -fstack-protector \ + -fno-short-enums \ + -finline-limit=64 \ + -Wa,--noexecstack \ + -U_FORTIFY_SOURCE \ + -Wno-extra \ + -Wno-ignored-qualifiers \ + -Wno-type-limits \ + -Wno-address \ + -Wno-format-security \ + -Wno-return-type \ + -Wno-sequence-point \ + -Os \ + -g \ + -fomit-frame-pointer \ + -fdata-sections \ + -ffunction-sections + +MY_CFLAGS_C := + +MY_DEFS := \ + '-DANGLE_DX11' \ + '-D_FILE_OFFSET_BITS=64' \ + '-DUSE_LINUX_BREAKPAD' \ + '-DNO_TCMALLOC' \ + '-DDISABLE_NACL' \ + '-DCHROMIUM_BUILD' \ + '-DUSE_LIBJPEG_TURBO=1' \ + '-DUSE_PROPRIETARY_CODECS' \ + '-DENABLE_GPU=1' \ + '-DUSE_OPENSSL=1' \ + '-DENABLE_EGLIMAGE=1' \ + '-DENABLE_LANGUAGE_DETECTION=1' \ + '-D__ARM_HAVE_OPTIONAL_NEON_SUPPORT' \ + '-DANDROID' \ + '-D__GNU_SOURCE=1' \ + '-DUSE_STLPORT=1' \ + '-D_STLP_USE_PTR_SPECIALIZATIONS=1' \ + '-DCHROME_BUILD_ID=""' \ + '-DDYNAMIC_ANNOTATIONS_ENABLED=1' \ + '-DWTF_USE_DYNAMIC_ANNOTATIONS=1' \ + '-D_DEBUG' + +LOCAL_CFLAGS := $(MY_CFLAGS_C) $(MY_CFLAGS) $(MY_DEFS) + +# Include paths placed before CFLAGS/CPPFLAGS +LOCAL_C_INCLUDES := \ + $(LOCAL_PATH) \ + $(LOCAL_PATH)/skia/config \ + $(LOCAL_PATH)/third_party/skia/include/config \ + $(LOCAL_PATH)/third_party/skia/include/core \ + $(LOCAL_PATH)/third_party/skia/src/core \ + $(LOCAL_PATH)/third_party/skia/src/opts \ + $(PWD)/frameworks/wilhelm/include \ + $(PWD)/bionic \ + $(PWD)/external/stlport/stlport + +LOCAL_C_INCLUDES := $(GYP_COPIED_SOURCE_ORIGIN_DIRS) $(LOCAL_C_INCLUDES) + +# Flags passed to only C++ (and not C) files. +LOCAL_CPPFLAGS := \ + -fno-rtti \ + -fno-threadsafe-statics \ + -fvisibility-inlines-hidden \ + -Wno-deprecated \ + -Wno-abi \ + -Wno-error=c++0x-compat \ + -Wno-non-virtual-dtor \ + -Wno-sign-promo \ + -Wno-non-virtual-dtor + +### Rules for final target. + +LOCAL_LDFLAGS := \ + -Wl,-z,now \ + -Wl,-z,relro \ + -Wl,-z,noexecstack \ + -fPIC \ + -march=armv7-a \ + -Wl,--fix-cortex-a8 \ + -Wl,-z,relro \ + -Wl,-z,now \ + -fuse-ld=gold \ + -nostdlib \ + -Wl,--no-undefined \ + -Wl,--exclude-libs=ALL \ + -Wl,--icf=safe \ + -Wl,--gc-sections \ + -Wl,-O1 \ + -Wl,--as-needed + + +LOCAL_STATIC_LIBRARIES := + +# Enable grouping to fix circular references +LOCAL_GROUP_STATIC_LIBRARIES := true + +LOCAL_SHARED_LIBRARIES := \ + libstlport \ + libdl + +# Add target alias to "gyp_all_modules" target. +.PHONY: gyp_all_modules +gyp_all_modules: skia_skia_opts_neon_gyp + +# Alias gyp target name. +.PHONY: skia_opts_neon +skia_opts_neon: skia_skia_opts_neon_gyp + +include $(BUILD_STATIC_LIBRARY) diff --git a/skia/skia_opts_neon.target.linux-arm.mk b/skia/skia_opts_neon.target.linux-arm.mk new file mode 100644 index 0000000000..84ded4a020 --- /dev/null +++ b/skia/skia_opts_neon.target.linux-arm.mk @@ -0,0 +1,161 @@ +# This file is generated by gyp; do not edit. + +include $(CLEAR_VARS) + +LOCAL_MODULE_CLASS := STATIC_LIBRARIES +LOCAL_MODULE := skia_skia_opts_neon_gyp +LOCAL_MODULE_SUFFIX := .a +LOCAL_MODULE_TAGS := optional +gyp_intermediate_dir := $(call local-intermediates-dir) +gyp_shared_intermediate_dir := $(call intermediates-dir-for,GYP,shared) + +# Make sure our deps are built first. +GYP_TARGET_DEPENDENCIES := + +GYP_GENERATED_OUTPUTS := + +# Make sure our deps and generated files are built first. +LOCAL_ADDITIONAL_DEPENDENCIES := $(GYP_TARGET_DEPENDENCIES) $(GYP_GENERATED_OUTPUTS) + +LOCAL_GENERATED_SOURCES := + +GYP_COPIED_SOURCE_ORIGIN_DIRS := + +LOCAL_SRC_FILES := \ + third_party/skia/src/opts/memset16_neon.S \ + third_party/skia/src/opts/memset32_neon.S \ + third_party/skia/src/opts/SkBitmapProcState_arm_neon.cpp \ + third_party/skia/src/opts/SkBitmapProcState_matrixProcs_neon.cpp \ + third_party/skia/src/opts/SkBlitRow_opts_arm_neon.cpp + + +# Flags passed to both C and C++ files. +MY_CFLAGS := \ + -fstack-protector \ + --param=ssp-buffer-size=4 \ + -fno-exceptions \ + -fno-strict-aliasing \ + -Wno-unused-parameter \ + -Wno-missing-field-initializers \ + -fvisibility=hidden \ + -pipe \ + -fPIC \ + -mfpu=neon \ + -fomit-frame-pointer \ + -Wno-format \ + -fno-tree-sra \ + -fuse-ld=gold \ + -Wno-psabi \ + -ffunction-sections \ + -funwind-tables \ + -g \ + -fstack-protector \ + -fno-short-enums \ + -finline-limit=64 \ + -Wa,--noexecstack \ + -U_FORTIFY_SOURCE \ + -Wno-extra \ + -Wno-ignored-qualifiers \ + -Wno-type-limits \ + -Wno-address \ + -Wno-format-security \ + -Wno-return-type \ + -Wno-sequence-point \ + -Os \ + -g \ + -fomit-frame-pointer \ + -fdata-sections \ + -ffunction-sections + +MY_CFLAGS_C := + +MY_DEFS := \ + '-DANGLE_DX11' \ + '-D_FILE_OFFSET_BITS=64' \ + '-DUSE_LINUX_BREAKPAD' \ + '-DNO_TCMALLOC' \ + '-DDISABLE_NACL' \ + '-DCHROMIUM_BUILD' \ + '-DUSE_LIBJPEG_TURBO=1' \ + '-DUSE_PROPRIETARY_CODECS' \ + '-DENABLE_GPU=1' \ + '-DUSE_OPENSSL=1' \ + '-DENABLE_EGLIMAGE=1' \ + '-DENABLE_LANGUAGE_DETECTION=1' \ + '-D__ARM_HAVE_OPTIONAL_NEON_SUPPORT' \ + '-DANDROID' \ + '-D__GNU_SOURCE=1' \ + '-DUSE_STLPORT=1' \ + '-D_STLP_USE_PTR_SPECIALIZATIONS=1' \ + '-DCHROME_BUILD_ID=""' \ + '-DDYNAMIC_ANNOTATIONS_ENABLED=1' \ + '-DWTF_USE_DYNAMIC_ANNOTATIONS=1' \ + '-D_DEBUG' + +LOCAL_CFLAGS := $(MY_CFLAGS_C) $(MY_CFLAGS) $(MY_DEFS) + +# Include paths placed before CFLAGS/CPPFLAGS +LOCAL_C_INCLUDES := \ + $(LOCAL_PATH) \ + $(LOCAL_PATH)/skia/config \ + $(LOCAL_PATH)/third_party/skia/include/config \ + $(LOCAL_PATH)/third_party/skia/include/core \ + $(LOCAL_PATH)/third_party/skia/src/core \ + $(LOCAL_PATH)/third_party/skia/src/opts \ + $(PWD)/frameworks/wilhelm/include \ + $(PWD)/bionic \ + $(PWD)/external/stlport/stlport + +LOCAL_C_INCLUDES := $(GYP_COPIED_SOURCE_ORIGIN_DIRS) $(LOCAL_C_INCLUDES) + +# Flags passed to only C++ (and not C) files. +LOCAL_CPPFLAGS := \ + -fno-rtti \ + -fno-threadsafe-statics \ + -fvisibility-inlines-hidden \ + -Wno-deprecated \ + -Wno-abi \ + -Wno-error=c++0x-compat \ + -Wno-non-virtual-dtor \ + -Wno-sign-promo \ + -Wno-non-virtual-dtor + +### Rules for final target. + +LOCAL_LDFLAGS := \ + -Wl,-z,now \ + -Wl,-z,relro \ + -Wl,-z,noexecstack \ + -fPIC \ + -march=armv7-a \ + -Wl,--fix-cortex-a8 \ + -Wl,-z,relro \ + -Wl,-z,now \ + -fuse-ld=gold \ + -nostdlib \ + -Wl,--no-undefined \ + -Wl,--exclude-libs=ALL \ + -Wl,--icf=safe \ + -Wl,--gc-sections \ + -Wl,-O1 \ + -Wl,--as-needed + + +LOCAL_STATIC_LIBRARIES := + +# Enable grouping to fix circular references +LOCAL_GROUP_STATIC_LIBRARIES := true + +LOCAL_SHARED_LIBRARIES := \ + libstlport \ + libdl + +# Add target alias to "gyp_all_modules" target. +.PHONY: gyp_all_modules +gyp_all_modules: skia_skia_opts_neon_gyp + +# Alias gyp target name. +.PHONY: skia_opts_neon +skia_opts_neon: skia_skia_opts_neon_gyp + +include $(BUILD_STATIC_LIBRARY) diff --git a/skia/skia_test_expectations.txt b/skia/skia_test_expectations.txt index 8f7bf63e97..eb7f1da84e 100644 --- a/skia/skia_test_expectations.txt +++ b/skia/skia_test_expectations.txt @@ -48,22 +48,14 @@ # # START OVERRIDES HERE -# the new image is better and results from improved AA ellipse drawing -# implemented in r9162 (https://chromiumcodereview.appspot.com/14938004) -crbug.com/241761 virtual/gpu/fast/canvas/canvas-composite-transformclip.html [ ImageOnlyFailure ] - # Skia r9262 (don't overclamp cubics (see skbug.com/1316)) changed # the way curves are drawn. The changes to this image are imperceptible crbug.com/243726 svg/as-background-image/svg-as-background-6.html [ ImageOnlyFailure ] -# Skia r9279 improved hairline rendering of quadratics and slightly -# changed this layout test -crbug.com/244401 virtual/gpu/fast/canvas/quadraticCurveTo.xml [ ImageOnlyFailure ] - # Skia's roll to r9450 caused some changes to the layout tests # In particular, the change to rendering some large fonts using paths # altered an svg test crbug.com/247306 svg/custom/use-referencing-nonexisting-symbol.svg [ Failure ImageOnlyFailure ] -crbug.com/247306 fast/text/international/spaces-combined-in-vertical-text.html [ Failure ] +crbug.com/247306 [ Linux ] fast/text/international/spaces-combined-in-vertical-text.html [ Failure ] # END OVERRIDES HERE (this line ensures that the file is newline-terminated) |