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

Unified Diff: build/toolchain/mac/BUILD.gn

Issue 2018553003: [GN] Configure a pool for copy_bundle_data and compile_xcassets tools. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@gn-pool
Patch Set: Address comments Created 4 years, 6 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/toolchain/mac/BUILD.gn
diff --git a/build/toolchain/mac/BUILD.gn b/build/toolchain/mac/BUILD.gn
index 1fdc1eef3175805485521607d667a19981de86e3..ffd3d5bc5574c330417352766586aae4c3c70864 100644
--- a/build/toolchain/mac/BUILD.gn
+++ b/build/toolchain/mac/BUILD.gn
@@ -23,6 +23,15 @@ if (use_goma) {
goma_prefix = ""
}
+if (current_toolchain == default_toolchain) {
+ # Reduce the number of tasks using the copy_bundle_data and compile_xcassets
+ # tools as they can cause lots of I/O contention when invoking ninja with a
+ # large number of parallel jobs (e.g. when using distributed build like goma).
+ pool("bundle_pool") {
+ depth = concurrent_links
+ }
+}
+
# This will copy the gyp-mac-tool to the build directory. We pass in the source
# file of the mac tool.
gyp_mac_tool_source =
@@ -271,6 +280,7 @@ template("mac_toolchain") {
root_build_dir)
command = "python $_tool {{source}} {{output}}"
description = "COPY_BUNDLE_DATA {{source}} {{output}}"
+ pool = ":bundle_pool($default_toolchain)"
}
tool("compile_xcassets") {
_tool = rebase_path("//build/toolchain/mac/compile_xcassets.py",
@@ -287,6 +297,7 @@ template("mac_toolchain") {
"-o {{output}} {{inputs}}"
description = "COMPILE_XCASSETS {{output}}"
+ pool = ":bundle_pool($default_toolchain)"
}
toolchain_args() {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698