platform_build_soong/ui
Dan Willemsen 104d9eb54a Better handling of low memory situations
Drop down to a single high-mem task when we've got <=16GB, as the system
probably isn't completely free RAM, ninja will be using a couple gigs,
along with whatever "normal" actions will be running concurrently. So
it's unlikely that we can handle two 6-8GB actions along with everything
else.

Also print warnings when we detect <=16GB total RAM, or when we're
running more parallel jobs than than we have GB RAM. These both notify
the user and suggest lowering the `-j` value if they run into problems.

Bug: 141066538
Test: fake totalRAM to [0.5,8,16]GB, checking warning
Test: fake totalRAM to 17GB, `m -j4 nothing` has no warning
Test: `m -j187 nothing` on a 188GB system
Test: `m -j188 nothing` on a 188GB system
Change-Id: Ieb008e9f462d5f40fb65781d94cf116b1caf8446
Merged-In: Ieb008e9f462d5f40fb65781d94cf116b1caf8446
(cherry picked from commit 570a292bab)
2020-05-29 21:45:06 +00:00
..
build Better handling of low memory situations 2020-05-29 21:45:06 +00:00
logger Panic if logging is attempted after Close 2019-03-21 21:17:04 -07:00
metrics Add total build time to metrics 2020-01-16 15:25:50 -08:00
status Don't print critical path parallelism ratio if elapsed time is 0. 2020-01-04 07:26:28 +00:00
terminal smart_status: move channel write outside lock to avoid deadlock 2019-10-29 15:27:32 -07:00
tracer Move all output through StatusOutput 2019-06-12 21:30:56 -07:00