summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Andreas Gampe <agampe@google.com> 2017-05-19 08:28:06 -0700
committer Andreas Gampe <agampe@google.com> 2017-05-24 21:45:50 -0700
commitbc9f10ce5192dbb825db216d67135ff26f1e1b22 (patch)
tree4b128032a56e6b1d5b28406631d3e0173b4aff2a
parent705543e43d1e7df753c64cd048a933f7b9681226 (diff)
ART: Move overflow gap definition to art.go
Move the stack overflow guard page size definitions into art.go. This is in preparation for conditional increases necessary for instrumented builds, as there is no bp support. Bug: 31098551 Test: m test-art-host Change-Id: I6d8364ea60c624a89790e9a936dfe7447ad41487
-rw-r--r--build/Android.bp6
-rw-r--r--build/art.go8
2 files changed, 8 insertions, 6 deletions
diff --git a/build/Android.bp b/build/Android.bp
index 6c9f1d4dd1..c54f436b35 100644
--- a/build/Android.bp
+++ b/build/Android.bp
@@ -64,12 +64,6 @@ art_global_defaults {
"-Wno-constant-conversion",
"-Wno-undefined-var-template",
- "-DART_STACK_OVERFLOW_GAP_arm=8192",
- "-DART_STACK_OVERFLOW_GAP_arm64=8192",
- "-DART_STACK_OVERFLOW_GAP_mips=16384",
- "-DART_STACK_OVERFLOW_GAP_mips64=16384",
- "-DART_STACK_OVERFLOW_GAP_x86=8192",
- "-DART_STACK_OVERFLOW_GAP_x86_64=8192",
// Enable thread annotations for std::mutex, etc.
"-D_LIBCPP_ENABLE_THREAD_SAFETY_ANNOTATIONS",
],
diff --git a/build/art.go b/build/art.go
index 61a97590ea..6dca793f29 100644
--- a/build/art.go
+++ b/build/art.go
@@ -76,6 +76,14 @@ func globalFlags(ctx android.BaseContext) ([]string, []string) {
asflags = append(asflags, "-DART_USE_OLD_ARM_BACKEND=1")
}
+ cflags = append(cflags,
+ "-DART_STACK_OVERFLOW_GAP_arm=8192",
+ "-DART_STACK_OVERFLOW_GAP_arm64=8192",
+ "-DART_STACK_OVERFLOW_GAP_mips=16384",
+ "-DART_STACK_OVERFLOW_GAP_mips64=16384",
+ "-DART_STACK_OVERFLOW_GAP_x86=8192",
+ "-DART_STACK_OVERFLOW_GAP_x86_64=8192")
+
return cflags, asflags
}