X-Git-Url: https://git.sesse.net/?p=stockfish;a=blobdiff_plain;f=src%2Fucioption.cpp;h=9f1447e19944c42064998321af595af437292471;hp=9bcd960b6a157f535d44dfaa030f64d1519849ef;hb=968c3de8e0acd46a8b55225dda1ed607ce24f380;hpb=6a6facc058e5f08ccd07815a6e619eb0d2451000 diff --git a/src/ucioption.cpp b/src/ucioption.cpp index 9bcd960b..9f1447e1 100644 --- a/src/ucioption.cpp +++ b/src/ucioption.cpp @@ -198,10 +198,14 @@ void init_uci_options() { // Set optimal value for parameter "Minimum Split Depth" // according to number of available cores. + assert(options.find("Threads") != options.end()); assert(options.find("Minimum Split Depth") != options.end()); + Option& thr = options["Threads"]; Option& msd = options["Minimum Split Depth"]; + thr.defaultValue = thr.currentValue = stringify(cpu_count()); + if (cpu_count() >= 8) msd.defaultValue = msd.currentValue = stringify(7); }