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

Unified Diff: runtime/bin/BUILD.gn

Issue 2367723004: Add tcmalloc to GN build (Closed)
Patch Set: Address comments Created 4 years, 3 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') | third_party/tcmalloc/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/BUILD.gn
diff --git a/runtime/bin/BUILD.gn b/runtime/bin/BUILD.gn
index f09dd415b9a0f99179020d1159c84b27cb1c27a5..549807b8ff385da0cd227808c59288c9b9740ad6 100644
--- a/runtime/bin/BUILD.gn
+++ b/runtime/bin/BUILD.gn
@@ -12,6 +12,10 @@ declare_args() {
# VM, we set this to //runtime/bin/zlib where we have a BUILD.gn file without
# a dependence on //base.
dart_zlib_path = "//third_party/zlib"
+
+ # Whether to link the standalone VM against tcmalloc. The standalone build of
+ # the VM enables this only for Linux builds.
+ dart_use_tcmalloc = false
}
resources_sources_gypi =
@@ -516,6 +520,12 @@ template("dart_executable") {
"$dart_zlib_path",
] + extra_deps
+ if (dart_use_tcmalloc) {
+ deps += [
+ "//third_party/tcmalloc",
+ ]
+ }
+
defines = extra_defines
sources = [
@@ -665,6 +675,12 @@ executable("run_vm_tests") {
"TESTING",
]
+ if (dart_use_tcmalloc) {
+ deps += [
+ "//third_party/tcmalloc",
+ ]
+ }
+
# The VM sources are already included in libdart, so we just want to add in
# the tests here.
vm_tests_list = exec_script("../../tools/gypi_to_gn.py",
« no previous file with comments | « build/config/compiler/BUILD.gn ('k') | third_party/tcmalloc/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698