Skip to content

Commit

Permalink
Remove one test in the move loop
Browse files Browse the repository at this point in the history
Gives a very small speed-up (0.3%) on my system

closes official-stockfish#4815

No functional change
  • Loading branch information
snicolet committed Oct 1, 2023
1 parent afe7f4d commit 3fdd37d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/search.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -954,7 +954,7 @@ namespace {
continue;

// Check for legality
if (!rootNode && !pos.legal(move))
if (!pos.legal(move))
continue;

ss->moveCount = ++moveCount;
Expand Down

0 comments on commit 3fdd37d

Please sign in to comment.