Skip to content

System Native

Spice
import "std/os/system_native";

Functions

getNativeCPUCoreCount

Spice
public f<long> getNativeCPUCoreCount()

Returns the number of CPU cores of the host system, that are online.

Returns: long — Number of cores

convertNativeMaxRssToBytes

Spice
public f<unsigned long> convertNativeMaxRssToBytes(long maxRss)

Converts the maximum resident set size, as reported by getrusage, to bytes.

Parameters

Name Type Description
maxRss long Maximum resident set size, as reported by getrusage

Returns: unsigned long — Maximum resident set size in bytes