Commit 7dcf98f9 authored by Takuto Ikuta's avatar Takuto Ikuta Committed by Commit Bot

Increase the number of concurrent link when symbol_level is less than 2

This is mainly for compile step time improve for android-kitkat-arm-rel builder
having symbol_level=1

I measured peak memory usage when link some large targets with android-kitkat-arm-rel builder's config.

libchrome.so: 4776232 KB
lib_unit_tests__library.so: 5308156 KB
lib_components_unittests__library.so: 5383500 KB

So 6GB will be sufficient for such builder. This also increase parallelism of proguard steps too.

Bug: 804251
Change-Id: I7e8785ae3f14d8ba1f45da532585d7c61875d321
Reviewed-on: https://chromium-review.googlesource.com/1104280Reviewed-by: default avataragrieve <agrieve@chromium.org>
Commit-Queue: Takuto Ikuta <tikuta@chromium.org>
Cr-Commit-Position: refs/heads/master@{#569237}
parent 7b03f402
......@@ -38,11 +38,15 @@ if (concurrent_links == -1) {
} else if (is_android && !is_component_build && symbol_level == 2) {
# Full debug symbols require large memory for link.
_args = [ "--mem_per_link_gb=25" ]
} else if (is_android && !is_debug && !using_sanitizer && symbol_level == 0) {
} else if (is_android && !is_debug && !using_sanitizer && symbol_level < 2) {
# Increase the number of concurrent links for release bots. Debug builds
# make heavier use of ProGuard, and so should not be raised. Sanitizers also
# increase the memory overhead.
_args = [ "--mem_per_link_gb=4" ]
if (symbol_level == 1) {
_args = [ "--mem_per_link_gb=6" ]
} else {
_args = [ "--mem_per_link_gb=4" ]
}
} else if (is_linux && !is_chromeos && symbol_level == 0) {
# Memory consumption on link without debug symbols is low on linux.
_args = [ "--mem_per_link_gb=3" ]
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment