]> git.sesse.net Git - stockfish/blobdiff - src/benchmark.cpp
Update stats at pv nodes
[stockfish] / src / benchmark.cpp
index cf0a315c1090a95236029977e845ca5d6d4c1199..fbf7b0e3a88990004ecbbe5ec54a02ecb20c1290 100644 (file)
@@ -144,7 +144,7 @@ void benchmark(const Position& current, istream& is) {
 
   uint64_t nodes = 0;
   Search::StateStackPtr st;
-  Time::point elapsed = Time::now();
+  TimePoint elapsed = now();
 
   for (size_t i = 0; i < fens.size(); ++i)
   {
@@ -158,12 +158,12 @@ void benchmark(const Position& current, istream& is) {
       else
       {
           Threads.start_thinking(pos, limits, st);
-          Threads.wait_for_think_finished();
+          Threads.main()->join();
           nodes += Search::RootPos.nodes_searched();
       }
   }
 
-  elapsed = Time::now() - elapsed + 1; // Ensure positivity to avoid a 'divide by zero'
+  elapsed = now() - elapsed + 1; // Ensure positivity to avoid a 'divide by zero'
 
   dbg_print(); // Just before to exit