• Jon Chronopoulos's avatar
    ProcessorCount: Fix virtual processor count on Solaris · 1c87bc60
    Jon Chronopoulos authored
    The previous code did not count the number of virtual processors across
    physical processors on SunOS.
    
    Can handle the following situations:
    
    ```
    $ uname -a
    SunOS solaris 5.11 11.4.0.15.0 i86pc i386 i86pc
    $ psrinfo -p -v
    The physical processor has 1 virtual processor (0)
      x86 (GenuineIntel 306D2 family 6 model 61 step 2 clock 3492 MHz)
            Intel Core Processor (Broadwell)
    The physical processor has 1 virtual processor (1)
      x86 (GenuineIntel 306D2 family 6 model 61 step 2 clock 3492 MHz)
            Intel Core Processor (Broadwell)
    The physical processor has 1 virtual processor (2)
      x86 (GenuineIntel 306D2 family 6 model 61 step 2 clock 3492 MHz)
            Intel Core Processor (Broadwell)
    The physical processor has 1 virtual processor (3)
      x86 (GenuineIntel 306D2 family 6 model 61 step 2 clock 3492 MHz)
            Intel Core Processor (Broadwell)
    ```
    
    ```
    $ uname -a
    SunOS sol11x86 5.11 11.0 i86pc i386 i86pc
    $ psrinfo -p -v
    The physical processor has 2 virtual processors (0 1)
      x86 (GenuineIntel 50650 family 6 model 85 step 0 clock 2000 MHz)
            Intel(r) Xeon(r) Gold 6138 CPU @ 2.00GHz
    ```
    
    ```
    $ uname -a
    SunOS sol11 5.11 11.0 sun4v sparc sun4v
    $ psrinfo -p -v
    The physical processor has 2 cores and 16 virtual processors (0-15)
      The core has 8 virtual processors (0-7)
      The core has 8 virtual processors (8-15)
        SPARC-T4 (chipid 0, clock 2848 MHz)
    ```
    1c87bc60
Name
Last commit
Last update
.github Loading commit data...
Auxiliary Loading commit data...
Help Loading commit data...
Licenses Loading commit data...
Modules Loading commit data...
Packaging Loading commit data...
Source Loading commit data...
Templates Loading commit data...
Tests Loading commit data...
Utilities Loading commit data...
.clang-format Loading commit data...
.clang-tidy Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
.hooks-config Loading commit data...
CMakeCPack.cmake Loading commit data...
CMakeCPackOptions.cmake.in Loading commit data...
CMakeGraphVizOptions.cmake Loading commit data...
CMakeLists.txt Loading commit data...
CMakeLogo.gif Loading commit data...
CONTRIBUTING.rst Loading commit data...
CTestConfig.cmake Loading commit data...
CTestCustom.cmake.in Loading commit data...
CompileFlags.cmake Loading commit data...
Copyright.txt Loading commit data...
DartConfig.cmake Loading commit data...
README.rst Loading commit data...
bootstrap Loading commit data...
cmake_uninstall.cmake.in Loading commit data...
configure Loading commit data...
doxygen.config Loading commit data...