| Index: build/android/envsetup.sh
|
| diff --git a/build/android/envsetup.sh b/build/android/envsetup.sh
|
| index f9e3e5ede1f0b74e5c21f1d95a2108ae5a6613d9..cacfafc79c60eb7c50e27a9c070aaf0dfab43bc8 100755
|
| --- a/build/android/envsetup.sh
|
| +++ b/build/android/envsetup.sh
|
| @@ -143,6 +143,14 @@ fi
|
| ANDROID_GOMA_WRAPPER=""
|
| if [[ -d $GOMA_DIR ]]; then
|
| ANDROID_GOMA_WRAPPER="$GOMA_DIR/gomacc"
|
| + num_cores="$(grep --count ^processor /proc/cpuinfo)"
|
| +# Goma is IO-ish you want more threads than you have cores.
|
| + let goma_threads=num_cores*2
|
| + if [ -z "${GOMA_COMPILER_PROXY_THREADS}" -a "${goma_threads}" -gt 16 ]; then
|
| +# The default is 16 threads, if the machine has many cores we crank it up a bit
|
| + GOMA_COMPILER_PROXY_THREADS="${goma_threads}"
|
| + export GOMA_COMPILER_PROXY_THREADS
|
| + fi
|
| fi
|
| export ANDROID_GOMA_WRAPPER
|
|
|
|
|