Function

GLib-2.0GLibget_num_processorsSince 2.36

  • Determine the approximate number of threads that the system will schedule simultaneously for this process. This is intended to be used as a parameter to g_thread_pool_new() for CPU bound tasks and similar cases.

    Returns number

    Number of schedulable threads, always greater than 0

    2.36