Skip to content

Commit 7e9f776

Browse files
VoyagerOnezamar
authored andcommitted
LMR Tweak: Decrease reduction if cmh>0 && history>0.
STC: LLR: 2.96 (-2.94,2.94) [-1.50,4.50] Total: 9627 W: 1879 L: 1748 D: 6000 LTC: LLR: 2.97 (-2.94,2.94) [0.00,6.00] Total: 21543 W: 3433 L: 3234 D: 14876 Bench: 8646407 Resolves #370 #371
1 parent 3f1bc9e commit 7e9f776

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/search.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -959,7 +959,10 @@ namespace {
959959
[pos.piece_on(to_sq(move))][to_sq(move)] <= VALUE_ZERO))
960960
ss->reduction += ONE_PLY;
961961

962-
if (move == countermove)
962+
if ( move == countermove
963+
|| ( History[pos.piece_on(to_sq(move))][to_sq(move)] > VALUE_ZERO
964+
&& CounterMovesHistory[pos.piece_on(prevMoveSq)][prevMoveSq]
965+
[pos.piece_on(to_sq(move))][to_sq(move)] > VALUE_ZERO))
963966
ss->reduction = std::max(DEPTH_ZERO, ss->reduction - ONE_PLY);
964967

965968
// Decrease reduction for moves that escape a capture

0 commit comments

Comments
 (0)