X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fsearch.cpp;h=e113068c408561c402f47513e685bb1b874b25a4;hb=d2274e609c28e46a24deee55b05684197d369976;hp=8a32e827488739ea351a4ee77d0532138b578ffa;hpb=9315ba60e68198452940a57292f27e37bc3b6ed2;p=stockfish diff --git a/src/search.cpp b/src/search.cpp index 8a32e827..e113068c 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -187,6 +187,7 @@ void Search::clear() { Time.availableNodes = 0; TT.clear(); Threads.clear(); + Tablebases::init(Options["SyzygyPath"]); // Free up mapped files } @@ -943,10 +944,8 @@ moves_loop: // When in check, search starts from here && pos.see_ge(move)) extension = ONE_PLY; - // Extension for king moves that change castling rights - if ( type_of(movedPiece) == KING - && pos.can_castle(us) - && depth < 12 * ONE_PLY) + else if ( pos.can_castle(us) // Extension for king moves that change castling rights + && type_of(movedPiece) == KING) extension = ONE_PLY; // Calculate new depth for this move