On Wed, May 29, 2019 at 04:13:41PM +0200, Rainer Orth wrote: > Prompted by extremely long libgomp make check times due to missing > parallelism, I noticed that the current support to restrict testcase > parallelism only works on targets which have getconf _NPROCESSORS_ONLN. > Instead of adding special cases for all sorts of tools to determine the > number of cores, I found a macro in the autoconf-archive that > encapsulates just that. > > The following patch makes use of that, bootstrapped without regressions > on i386-pc-solaris2.11 and sparc-sun-solaris2.11 and checked that > CPU_COUNT is determined correctly and the OMP_NUMP_THREADS warning > emitted. Also rebuilt libgomp on x86_64-pc-linux-gnu and performed the > same check. > > Ok for mainline?
I'd prefer not to determine the CPU count at configure time, the build directory can be on some network filesystem and tested sometimes on one machine, sometimes on another one, hw can be upgraded etc. So, something similar to what your patch does, but don't substitute the actual CPU count, but a command to determine the number of CPUs? Jakub