X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fsearch.cpp;h=17d52cae5febf53739f97e78e0ab254e3e7d5b83;hb=c86eee391830c9c74bc11be9c537ccbbf6cb412e;hp=c9f1aee0685be46653a04758ed1693ef6f6f1995;hpb=10b53e1c5e6aeba156eb5c02afccfd7db1f84d16;p=stockfish diff --git a/src/search.cpp b/src/search.cpp index c9f1aee0..17d52cae 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -937,7 +937,7 @@ moves_loop: // When in check and at SpNode search starts from here // Step 15. Reduced depth search (LMR). If the move fails high will be // re-searched at full depth. - if ( depth > 3 * ONE_PLY + if ( depth >= 3 * ONE_PLY && !pvMove && !captureOrPromotion && move != ttMove @@ -1361,7 +1361,10 @@ moves_loop: // When in check and at SpNode search starts from here Square m2to = to_sq(second); // The piece is the same or second's destination was vacated by the first move - if (m1to == m2from || m2to == m1from) + // We exclude the trivial case where a sliding piece does in two moves what + // it could do in one move: eg. Ra1a2, Ra2a3. + if ( m2to == m1from + || (m1to == m2from && !squares_aligned(m1from, m2from, m2to))) return true; // Second one moves through the square vacated by first one