diff options
Diffstat (limited to 'src/corelib/thread/qthread.cpp')
-rw-r--r-- | src/corelib/thread/qthread.cpp | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/src/corelib/thread/qthread.cpp b/src/corelib/thread/qthread.cpp index a936d189f4..4cfcab2258 100644 --- a/src/corelib/thread/qthread.cpp +++ b/src/corelib/thread/qthread.cpp @@ -314,9 +314,20 @@ QThreadPrivate::~QThreadPrivate() /*! \fn int QThread::idealThreadCount() - Returns the ideal number of threads that can be run on the system. This is done querying - the number of processor cores, both real and logical, in the system. This function returns 1 - if the number of processor cores could not be detected. + Returns the ideal number of threads that this process can run in parallel. + This is done by querying the number of logical processors available to this + process (if supported by this OS) or the total number of logical processors + in the system. This function returns 1 if neither value could be + determined. + + \note On operating systems that support setting a thread's affinity to a + subset of all logical processors, the value returned by this function may + change between threads and over time. + + \note On operating systems that support CPU hotplugging and hot-unplugging, + the value returned by this function may also change over time (and note + that CPUs can be turned on and off by software, without a physical, + hardware change). */ /*! |