| # Copyright 2019 The Fuchsia Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| |
| assert( |
| current_toolchain == default_toolchain, |
| "This should only be imported in the default_toolchain, beause the pools it is used with MUST only be defined once for the entire build.") |
| |
| _script = "get_concurrent_jobs.py" |
| _args = [ |
| "-S", # See https://fxbug.dev/42141201. |
| rebase_path(_script, root_build_dir), |
| "--reserve-memory=1GB", |
| ] |
| |
| _args += [ |
| "--memory-per-job", |
| "local=1GB", |
| "highmem=32GB", |
| ] |
| |
| default_concurrent_jobs = |
| exec_script(python_exe_src, |
| _args, |
| "json", |
| [ |
| _script, # See https://fxbug.dev/42141201#comment6. |
| ]) |