X-Git-Url: https://git.sesse.net/?p=stockfish;a=blobdiff_plain;f=src%2Fsearch.cpp;h=39dcf9768157d4276ccc97fbe50a80bafc2b1c73;hp=ffd484266b2196d0167c93b377c59b7a15230814;hb=e4fd9a2df7d0977cc279d73d94e79a866daddb2f;hpb=96a32eec69596be311d513cc13762f538cd7a422 diff --git a/src/search.cpp b/src/search.cpp index ffd48426..39dcf976 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -165,10 +165,11 @@ namespace { // Margins for futility pruning in the quiescence search, and at frontier // and near frontier nodes Value FutilityMarginQS = Value(0x80); - Value FutilityMargins[6] = { Value(0x120), Value(0x220), Value(0x250), - Value(0x280), Value(0x320), Value(0x360) }; + Value FutilityMargins[6] = { Value(0x100), Value(0x200), Value(0x250), + Value(0x2A0), Value(0x340), Value(0x3A0) }; // Razoring + const bool RazorAtDepthOne = false; Depth RazorDepth = 4*OnePly; Value RazorMargin = Value(0x300); @@ -416,7 +417,7 @@ void think(const Position &pos, bool infinite, bool ponder, int side_to_move, UseFutilityPruning = get_option_value_bool("Futility Pruning (Main Search)"); FutilityMarginQS = value_from_centipawns(get_option_value_int("Futility Margin (Quiescence Search)")); - int fmScale = get_option_value_int("Futility Margin (Main Serach)"); + int fmScale = get_option_value_int("Futility Margin Scale Factor (Main Search)"); for (int i = 0; i < 6; i++) FutilityMargins[i] = (FutilityMargins[i] * fmScale) / 100; @@ -1241,12 +1242,14 @@ namespace { else if ( !value_is_mate(beta) && approximateEval < beta - RazorMargin && depth < RazorDepth - && depth > OnePly + && (RazorAtDepthOne || depth > OnePly) && ttMove == MOVE_NONE && !pos.has_pawn_on_7th(pos.side_to_move())) { Value v = qsearch(pos, ss, beta-1, beta, Depth(0), ply, threadID); - if (v < beta - RazorMargin / 2 - int(depth - OnePly) * RazorMargin / 8) + if ( (v < beta - RazorMargin - RazorMargin / 4) + || (depth <= 2*OnePly && v < beta - RazorMargin) + || (depth <= OnePly && v < beta - RazorMargin / 2)) return v; }