X-Git-Url: https://git.sesse.net/?p=stockfish;a=blobdiff_plain;f=src%2Fthread.cpp;h=62ff37641c7cb013fb3376d795382ca4d1aaae9f;hp=06244dc9bb957c41f5d47d13ed64aa59a40c6bf8;hb=43efd7fad77eb6a84305b0e2b25e62a6f1ce5fed;hpb=6ba1d3ead63490f1f6734bd0245ed10783975c11 diff --git a/src/thread.cpp b/src/thread.cpp index 06244dc9..62ff3764 100644 --- a/src/thread.cpp +++ b/src/thread.cpp @@ -119,7 +119,7 @@ bool Thread::available_to(const Thread* master) const { // Make a local copy to be sure it doesn't become zero under our feet while // testing next condition and so leading to an out of bounds access. - int size = splitPointsSize; + const int size = splitPointsSize; // No split points means that the thread is available as a slave for any // other thread otherwise apply the "helpful master" concept if possible. @@ -181,13 +181,12 @@ void MainThread::idle_loop() { // init() is called at startup to create and launch requested threads, that will -// go immediately to sleep due to 'sleepWhileIdle' set to true. We cannot use -// a c'tor because Threads is a static object and we need a fully initialized -// engine at this point due to allocation of Endgames in Thread c'tor. +// go immediately to sleep. We cannot use a c'tor because Threads is a static +// object and we need a fully initialized engine at this point due to allocation +// of Endgames in Thread c'tor. void ThreadPool::init() { - sleepWhileIdle = true; timer = new_thread(); push_back(new_thread()); read_uci_options();