From f7742669cb52dff7a64bd1a9ba466e333abb87bc Mon Sep 17 00:00:00 2001 From: Marco Costalba Date: Sat, 28 Dec 2013 10:30:35 +0100 Subject: [PATCH 1/1] Retire asymmThreshold Verified with 40K games at long TC does not regress: ELO: 1.74 +-1.9 (95%) LOS: 96.2% Total: 39624 W: 6402 L: 6203 D: 27019 bench: 7762310 --- src/position.cpp | 11 +---------- src/position.h | 2 +- src/search.cpp | 5 +---- 3 files changed, 3 insertions(+), 15 deletions(-) diff --git a/src/position.cpp b/src/position.cpp index 982befa3..910966a4 100644 --- a/src/position.cpp +++ b/src/position.cpp @@ -1029,7 +1029,7 @@ int Position::see_sign(Move m) const { return see(m); } -int Position::see(Move m, int asymmThreshold) const { +int Position::see(Move m) const { Square from, to; Bitboard occupied, attackers, stmAttackers; @@ -1096,15 +1096,6 @@ int Position::see(Move m, int asymmThreshold) const { } while (stmAttackers); - // If we are doing asymmetric SEE evaluation and the same side does the first - // and the last capture, it loses a tempo and gain must be at least worth - // 'asymmThreshold', otherwise we replace the score with a very low value, - // before negamaxing. - if (asymmThreshold) - for (int i = 0; i < slIndex; i += 2) - if (swapList[i] < asymmThreshold) - swapList[i] = - QueenValueMg * 16; - // Having built the swap list, we negamax through it to find the best // achievable score from the point of view of the side to move. while (--slIndex) diff --git a/src/position.h b/src/position.h index 9a88e1b2..6b77a737 100644 --- a/src/position.h +++ b/src/position.h @@ -141,7 +141,7 @@ public: void undo_null_move(); // Static exchange evaluation - int see(Move m, int asymmThreshold = 0) const; + int see(Move m) const; int see_sign(Move m) const; // Accessing hash keys diff --git a/src/search.cpp b/src/search.cpp index 713bd10f..19cb3b51 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -1220,10 +1220,7 @@ moves_loop: // When in check and at SpNode search starts from here continue; } - // Prune moves with negative or equal SEE and also moves with positive - // SEE where capturing piece loses a tempo and SEE < beta - futilityBase. - if ( futilityBase < beta - && pos.see(move, beta - futilityBase) <= 0) + if (futilityBase < beta && pos.see(move) <= 0) { bestValue = std::max(bestValue, futilityBase); continue; -- 2.39.2