diff options
Diffstat (limited to 'src/split.c')
| -rwxr-xr-x | src/split.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/split.c b/src/split.c index ce9a752..b30cdb6 100755 --- a/src/split.c +++ b/src/split.c @@ -1125,8 +1125,12 @@ Return value: iExtend)) { ASSERT(iExtend == 0); - iExtend = -ONE_PLY; - ctx->sPlyInfo[ctx->uPly].iExtensionAmount = -ONE_PLY; + iExtend = -(ONE_PLY + ExtraReduction(uDepth, + (g_SplitInfo[u].uAlreadyDone + + uMoveNum + 1), + GetMoveFailHighPercentage(mv))); + ctx->sPlyInfo[ctx->uPly].iExtensionAmount = iExtend; + INC(ctx->sCounters.tree.u64HistoryPrunes); } // @@ -1147,8 +1151,9 @@ Return value: // if ((iExtend < 0) && (iScore >= iBeta)) { - uDepth += ONE_PLY; + uDepth -= iExtend; // undo the full reduction, whatever its magnitude ctx->sPlyInfo[ctx->uPly].iExtensionAmount = 0; + INC(ctx->sCounters.tree.u64HistoryPruneReSearches); iScore = -Search(ctx, -iBeta, -iAlpha, uDepth); } UnmakeMove(ctx, mv); |
