Qu

sysinfo

Builtin index · Concurrency

result = sysinfo()

Input: no input · Output: result

What it is

Takes no arguments.

Overloads

One call shape — this function is not overloaded.

CodeInputOutputDescription
result = sysinfo()no input
result Record, string, or number
Returns a Record describing this machine: .os/.arch/.hostname/.cpu/.qu_version/.build (strings), .logical_cores (integer), .physical_cores and .total_memory (number, or none when the platform doesn't report them), and .gpu/.gpu_reason (string, or none/an explanatory string when this build has no GPU support). What to branch on before sizing a pool.

Examples

From the documentation, and run by the build -- the output and the figure below are what the engine actually produced. Simplest first.

t = now()
print(t.year)                 # e.g. 2026 -- UTC

info = sysinfo()
print(info.logical_cores)     # e.g. 16 -- what to branch on before sizing a pool(n)

output
2026
16

from concurrency

How it works

sysinfo() -- the machine this is running on, as a record. sysinfo("text") -- the same thing as a printable block for the head of a benchmark report. Every field is something the OS actually reported; anything it would not tell us is nothing rather than a plausible guess. gpu is the field that matters most for a fair comparison and the easiest to get wrong silently: a GPU-accelerated run measured against a CPU-only baseline is not a language comparison, and gpu/gpu_reason make which one happened impossible to omit by accident.

From the note above this builtin in the interpreter, where the reasoning was written down as it was built.