Bug 1516605 - Turn on NEON on aarch64 when using gcc or clang. r=aosmond
authorMakoto Kato <m_kato@ga2.so-net.ne.jp>
Wed, 02 Jan 2019 14:11:31 +0000
changeset 509604 129f8c60783c4daba0c04106c3082c2f94890b66
parent 509590 7be73b4e5299792d47667c8587d56a5b2e36c71e
child 509605 32f94b7a8db69e3ab86135182fe8e43ea6926767
push id10547
push userffxbld-merge
push dateMon, 21 Jan 2019 13:03:58 +0000
treeherdermozilla-beta@24ec1916bffe [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersaosmond
bugs1516605
milestone66.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1516605 - Turn on NEON on aarch64 when using gcc or clang. r=aosmond libpng has NEON support using intrinsics, not assembler, so we should use it even if aarch64. MSVC build still turns off NEON since libpng doesn't support it on stable version although upstream has it. Differential Revision: https://phabricator.services.mozilla.com/D15462
media/libpng/moz.build
--- a/media/libpng/moz.build
+++ b/media/libpng/moz.build
@@ -36,16 +36,23 @@ if CONFIG['CPU_ARCH'] == 'arm':
         'arm/arm_init.c',
         'arm/filter_neon_intrinsics.c'
     ]
 
     SOURCES += [
         'arm/filter_neon.S'
     ]
 
+if CONFIG['CPU_ARCH'] == 'aarch64' and CONFIG['CC_TYPE'] in ('clang', 'gcc'):
+    DEFINES['MOZ_PNG_USE_ARM_NEON'] = True
+    UNIFIED_SOURCES += [
+        'arm/arm_init.c',
+        'arm/filter_neon_intrinsics.c'
+    ]
+
 if CONFIG['INTEL_ARCHITECTURE']:
     DEFINES['MOZ_PNG_USE_INTEL_SSE'] = True
     UNIFIED_SOURCES += [
         'intel/filter_sse2_intrinsics.c',
         'intel/intel_init.c'
     ]
 
 if CONFIG['HAVE_ALTIVEC']: