Conversation

Replying to and
I'm curious whether this is just an oversight in the build script. I recently ran into the "argument list too long" issue with my shell, and it was because I was using subshells instead of named pipes.
1
2
Replying to and
"Oversight" is a very kind way of putting "they NIH'd an utterly hideous build system just because they couldn't be bothered to understand how good existing ones are supposed to work".
3
10
Replying to and
AOSP build system is ninja, and that's not my experience with it. It chooses the number of jobs based on the number of hardware threads by default rather than opting in, so if you're comparing to using 1 thread that's relevant. CPU cgroup + SCHED_BATCH helps with this in general.
2
Replying to and
I definitely wouldn't want it to serialize anything. I've already lost an enormous amount of time waiting for builds. If you want to use fewer jobs, you do have that option, and with 8GB of memory I don't think you can safely get away with more than 1-2 especially due to LTO.
2
I'm not aware of a build system that would go out of the way to serialize things like linking. The make-based build system didn't do that, and the jack compiler used far more memory than anything in the current builds. Peak memory usage now is from the Clang LTO needed for CFI.
1
Replying to and
Disable CFI/LTO and you'll probably find it uses drastically less memory. On my system, linking Chromium definitely uses far more memory than even the peak AOSP build memory usage, but I'm always building production (non-component) releases of Chromium where CFI/LTO are enabled.
1
1
I prefer working with the declarative blueprint files than gn, since it's far easier for me to analyze them and make changes. Build logic is far more contained to blueprint/soong, and I'd rather work with Go than a terrible build programming language. Still prefer gn over make.