Current http://nixos.org/nix/manual/ says:
build-max-jobs
This option defines the maximum number of jobs that Nix will try to build in parallel. The default is 1. You should generally set it to the number of CPUs in your system (e.g., 2 on an Athlon 64 X2). It can be overridden using the --max-jobs (-j) command line switch.
Looking at docs for --max-jobs:
--max-jobs, -j
Sets the maximum number of build jobs that Nix will perform in parallel to the specified number. The default is specified by the build-max-jobs configuration setting, which itself defaults to 1.
So these two default to 1.
However, looking at the changelog for D.4. Release 1.8:
The configuration option
build-max-jobsnow defaults to the number of available CPU cores.
So I assume at some point it was changed back to 1, but this didn't make it into a changelog?
Is there a value I can set build-max-jobs or --max-jobs to to get it auto-choose the number of CPUs I have?
And another question: --max-jobs also seems to determine the number of parallell binary cache downloads (which I'd like to have much higher than my number of CPUs as connection initiation is slow and I have fast internet).
Is there a way to set the number of parallel downloads independently of the compile parallelism?
(I guess a similar questions comes from https://www.reddit.com/r/NixOS/comments/5bke41/nixpkgs_configuring_parallel_fetch_from_binary/)
An example of parallel download making a big difference for download time (plotted are --max-jobs 40, 4 and 1):

The build-max-jobs situation is a typo in changelog, apparently; build-cores is what's detected since de4cdd0d47adc70a4db12397a42c18ee50b4e662, though setting it to 0 is also taken by our nixpkgs stdenv as hint to auto-detect that anyway ($NIX_BUILD_CORES).
It would be a nice enhancement to separately control of the number of _substituted_ paths in parallel, though that won't cover all fetches. We could approximate downloads better by considering all fixed-output derivations as well.
I don't understand
build-max-jobs be deprecated in favor of build-cores?build-max-jobs to 0 to use all available cores?You can set max-jobs to auto (7251d048fa812d2551b7003bc9f13a8f5d4c95a5). No, it's not deprecated since it serves a different purpose (max-jobs is about the number of derivations that Nix will build in parallel, while cores is about parallelism inside a derivation, e.g. what make -j will use).
Most helpful comment
You can set
max-jobstoauto(7251d048fa812d2551b7003bc9f13a8f5d4c95a5). No, it's not deprecated since it serves a different purpose (max-jobsis about the number of derivations that Nix will build in parallel, whilecoresis about parallelism inside a derivation, e.g. whatmake -jwill use).