1
0
Fork 0
mirror of https://github.com/sockspls/badfish synced 2025-05-01 17:19:36 +00:00

QuietPick Speed-up

Non-functional speedup: no need to generate, score, or sort quiet moves
if SkipQuiet is true. Thanks to @mstembera for his suggestion.

STC:
LLR: 2.95 (-2.94,2.94) [0.00,4.00]
Total: 27910 W: 6406 L: 6129 D: 15375
http://tests.stockfishchess.org/tests/view/5d07e0920ebc5925cf0a58a8

Closes https://github.com/official-stockfish/Stockfish/pull/2194

No functional change
This commit is contained in:
VoyagerOne 2019-06-17 17:35:03 -04:00 committed by Stephane Nicolet
parent 59f1d0c7dd
commit 297c40291a

View file

@ -200,11 +200,15 @@ top:
/* fallthrough */ /* fallthrough */
case QUIET_INIT: case QUIET_INIT:
cur = endBadCaptures; if (!skipQuiets)
endMoves = generate<QUIETS>(pos, cur); {
cur = endBadCaptures;
endMoves = generate<QUIETS>(pos, cur);
score<QUIETS>();
partial_insertion_sort(cur, endMoves, -4000 * depth / ONE_PLY);
}
score<QUIETS>();
partial_insertion_sort(cur, endMoves, -4000 * depth / ONE_PLY);
++stage; ++stage;
/* fallthrough */ /* fallthrough */