]> git.sesse.net Git - stockfish/blobdiff - src/search.cpp
Simplify late countermove bonus condition
[stockfish] / src / search.cpp
index 2eed74b87592596c369f7e29a6b521d10f97e29c..eccb97fd12c198cbf5efc1a1d19c2e26e7d91c92 100644 (file)
@@ -1371,11 +1371,10 @@ moves_loop: // When in check, search starts here
                          quietsSearched, quietCount, capturesSearched, captureCount, depth);
 
     // Bonus for prior countermove that caused the fail low
-    else if (   (depth >= 5 || PvNode || bestValue < alpha - 65 * depth)
-             && !priorCapture)
+    else if (!priorCapture)
     {
         // Extra bonuses for PV/Cut nodes or bad fail lows
-        int bonus = 1 + (PvNode || cutNode) + (bestValue < alpha - 88 * depth);
+        int bonus = (depth > 4) + (PvNode || cutNode) + (bestValue < alpha - 88 * depth);
         update_continuation_histories(ss-1, pos.piece_on(prevSq), prevSq, stat_bonus(depth) * bonus);
     }