Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(31)

Unified Diff: skia/BUILD.gn

Issue 371853007: Fix optional neon support (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@gn-missing-files
Patch Set: Rebase Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « build/config/compiler/BUILD.gn ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: skia/BUILD.gn
diff --git a/skia/BUILD.gn b/skia/BUILD.gn
index 1a043ceb33fbba67dc7f0cda02647b0c61b80fbd..2b520e4af1068f299ca28a5f7c9c63937107475e 100644
--- a/skia/BUILD.gn
+++ b/skia/BUILD.gn
@@ -180,6 +180,15 @@ config("skia_library_config") {
"SK_USE_DISCARDABLE_SCALEDIMAGECACHE",
]
+ if (cpu_arch == "arm") {
+ if (arm_use_neon) {
+ defines += [ "__ARM_HAVE_NEON" ]
+ }
+ if (arm_optionally_use_neon) {
+ defines += [ "__ARM_HAVE_OPTIONAL_NEON_SUPPORT" ]
+ }
+ }
+
# Settings for text blitting, chosen to approximate the system browser.
if (is_linux) {
defines += [
@@ -626,20 +635,18 @@ source_set("skia_opts") {
# Root build config sets -mfpu=$arm_fpu, which we expect to be neon
# when running this.
- assert(arm_fpu == "neon")
+ if (!arm_use_neon) {
+ configs -= [ "//build/config/compiler:compiler_arm_fpu" ]
+ cflags += [
+ "-mfpu=neon"
+ ]
+ }
#ldflags = [
# "-march=armv7-a",
# "-Wl,--fix-cortex-a8",
#]
}
-
- if (arm_use_neon) {
- defines += [ "__ARM_HAVE_NEON" ]
- }
- if (arm_optionally_use_neon) {
- defines += [ "__ARM_HAVE_OPTIONAL_NEON_SUPPORT" ]
- }
}
# Non-Neon ARM code.
« no previous file with comments | « build/config/compiler/BUILD.gn ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698