]> git.sesse.net Git - stockfish/commitdiff
Update bestValue when futility pruning (2)
authorMarco Costalba <mcostalba@gmail.com>
Fri, 22 Mar 2013 08:52:41 +0000 (09:52 +0100)
committerMarco Costalba <mcostalba@gmail.com>
Sun, 24 Mar 2013 22:32:21 +0000 (23:32 +0100)
Same idea of 5af8179647b9e80353c
in qsearch() but applied to search()

After 15500 games at 15+0.05
ELO: 4.48 +-3.4 (95%) LOS: 99.5%
Total: 15500 W: 3061 L: 2861 D: 9578

bench: 4985829

src/search.cpp

index 6dcd9f1db794f56f1ab5214e21fcab7587d2b3b0..f99f63beca57fda3d7e3b4780595e85f4d5c2b09 100644 (file)
@@ -879,9 +879,14 @@ split_point_start: // At split points actual search starts from here
 
           if (futilityValue < beta)
           {
+              bestValue = std::max(bestValue, futilityValue);
+
               if (SpNode)
+              {
                   splitPoint->mutex.lock();
-
+                  if (bestValue > splitPoint->bestValue)
+                      splitPoint->bestValue = bestValue;
+              }
               continue;
           }