Our example C++ source file (processor-info.cpp) consists of the following:
#include "config.h"#include <cstdlib>#include <iostream>int main() { std::cout << "Number of logical cores: " << NUMBER_OF_LOGICAL_CORES << std::endl; std::cout << "Number of physical cores: " << NUMBER_OF_PHYSICAL_CORES << std::endl; std::cout << "Total virtual memory in megabytes: " << TOTAL_VIRTUAL_MEMORY << std::endl; std::cout << "Available virtual memory in megabytes: " << AVAILABLE_VIRTUAL_MEMORY << std::endl; std::cout << "Total physical memory in megabytes: " << TOTAL_PHYSICAL_MEMORY << std::endl; std::cout << "Available physical memory in megabytes: " << AVAILABLE_PHYSICAL_MEMORY << std::endl; std::cout << "Processor is 64Bit: " << IS_64BIT ...