http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58669

--- Comment #3 from Folkert van Heusden <folkert at vanheusden dot com> ---
Did some googling and with appropriate #ifdefs it should be at least on linux
possible to retrieve this value:

sysconf(_SC_NPROCESSORS_ONLN);

If that function can't figure it out, it will return '1' which is somewhat
sensible.

On
http://stackoverflow.com/questions/150355/programmatically-find-the-number-of-cores-on-a-machine
I found a whole list of implementations for windows, *bsd, macos, aix, well I
think all relevant platforms.
Also
http://stackoverflow.com/questions/4586405/get-number-of-cpus-in-linux-using-c
gives some ideas.

If there's any further help I can do; let me know.

Reply via email to