@TomAoki @grahamperrin Poudriere could be significantly improved by exporting a semaphore into each jail and patching gmake, ninja, and a handful of other ports to acquire it before starting a job and release it at the end. Currently it has the nested schedulers problem: the things making the scheduling decision do not have the global knowledge to make good decisions. On a 16-core machine, you either let each jail build sequentially and end up with an LLVM build that everything depends on running with 15 cores idle, or you allow each jail to use 16 cores and end up with two big builds (e.g. LLVM, Chromium, LibreOffice) some slicing the cores and using more RAM than you have.Ideally, each jail spawns more than one build job only when other jails are not running, and limits parallel jobs (e.g. LLD) based on the number of available cores.CMake can now put link jobs in a separate resource pool because they tend to be memory and I/O limited, rather than CPU-bound. Linking LLVM will mmap several gigabytes of files and do copies of fragments of them. This can easily trigger swapping you’re linking multiple tools at the same time.