From feed1fb2ef53362263ec79b50c0d05a3787fb069 Mon Sep 17 00:00:00 2001 From: Calcitem Date: Tue, 20 Apr 2021 23:03:42 +0800 Subject: [PATCH] search: Adjust TranspositionTable::save params like morris 0.2, but not same. Use: TranspositionTable::boundType(bestValue, alpha, beta), Not use oldAlpha self play change last few moves, white win more quickly. From: (3,5)->(2,5) (1,5)->(1,4) (2,5)->(1,5) (1,6)->(1,7) (1,5)->(1,6) (1,7)->(2,7) -(2,4) (1,6)->(1,5) (2,7)->(1,7) (1,5)->(1,6) (1,7)->(2,7) -(1,2) Player2 win! To: (3,5)->(2,5) (1,6)->(1,7) (2,5)->(3,5) (1,7)->(2,7) -(2,4) (3,5)->(2,5) (1,5)->(1,6) -(1,2) Player2 win! --- src/search.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/search.cpp b/src/search.cpp index 5636efa0..9a433445 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -473,8 +473,7 @@ Value search(Position *pos, Sanmill::Stack &ss, Depth depth, Depth ori #ifdef TRANSPOSITION_TABLE_ENABLE TranspositionTable::save(bestValue, depth, - bestValue >= beta ? BOUND_LOWER : - BOUND_UPPER, + TranspositionTable::boundType(bestValue, alpha, beta), posKey #ifdef TT_MOVE_ENABLE , bestMove