Programmatically find the number of cores on a machine

Posted by hazzen on Stack Overflow See other posts from Stack Overflow or by hazzen
Published on 2008-09-29T19:51:45Z Indexed on 2010/06/09 13:52 UTC
Read the original article Hit count: 170

Filed under:
|

This is more of a curiosity question than something that needs actual solving, but is there a way to determine how many cores a machine has from C++ in a platform-independent way? If no such thing exists, what about determining it per-platform (Windows/*nix/Mac)?

© Stack Overflow or respective owner

Related posts about c++

Related posts about multicore