Determine computer processor information.
#include "msparser.hpp"
#include <iostream>
using namespace matrix_science;
int main(int argc, char * argv[])
{
{
std::cout << "There are errors. Cannot continue. The last error description:" << std::endl;
return 1;
}
std::cout <<
"Number of CPUS available on the system: " << cpus.
getNumOnSystem() << std::endl;
return 0;
}
std::string getLastErrorString() const
Return the error description of the last error that occurred.
Definition: ms_errors.cpp:1488
bool isValid() const
Call this function to determine if there have been any errors.
Definition: ms_errors.cpp:1472
This class is designed to retrieve current CPU configuration on the computer and set affinity.
Definition: ms_processors.hpp:50
int getNumOnSystem() const
Returns the number of logical CPUs installed in the system.
Definition: ms_processors.cpp:69