Lua
C++
Edit

MaxThreads

This function returns the maximum number of simultaneous threads the CPU can execute at once. More threads than this can be created and run, but will not yield any performance gains.

Syntax

Returns

Returns the maximum number of threads that can run at once.

Example

#include "Leadwerks.h"

using namespace Leadwerks;

int main(int argc, const char* argv[])
{
    Print(String(MaxThreads()) + " threads are supported on this machine.");
    return 0;
}
Copyright © 2006-2025 Leadwerks Software.
All rights reserved.
Leadwerks 4 Documentation