[Overview][Classes][Procedures and functions][Index] Reference for unit 'UTF8Process' (#lazutils)

GetSystemThreadCount

Gets the number of threads available on the system.

Declaration

Source position: utf8process.pp line 57

function GetSystemThreadCount: Integer;

Function result

The number of threads on the system.

Description

GetSystemThreadCount is an Integer function used to get the number of threads on the system. The implementation for GetSystemThreadCount is platform- and/or OS-specific. For the Windows environment, the total number of processors available (including logical hyperthreaded processors) are returned using the GetProcessAffinityMask API. When GetProcessAffinityMask is unavailable, the total number of processors from GetSystemInfo is used. For UNIX-like environments, either the sysconf or the fpsysctl function is used. For other environments, the return value is always 1.


Version 3.2 Generated 2024-02-25 Home