mvanthoor wrote: ↑Tue Feb 15, 2022 8:56 am
First: you will need to run through the move list anyway to order or pick moves, because you can't know which of the moves in the list are going to be the transposition table move, or are part of the killer moves. (If any, obviously.)
Is there a hash move? Great I play it first. No move generation at all and no iteration over any move list at this point. And the hash move is often already producing a cutoff!
Next... generate just the captures. That's going to be a short list. Lazy picking the best move here is quick because the range is so small.
Next... killers. Why would I need a move list here? I just get the killer move candidate, make sure it's actually playable in the current position and play it.
Finally... quiet moves. But thanks to staged move generation in most nodes we don't get this far and thus most moves that exist in a position have never been generated let alone traversed over in a list.
After searching 300 positions to depth 7 with Leorik (just alpha/beta pruning mostly) this is how often the different stages have been reached in total outside of Qsearch.
Code: Select all
HashMove: 28,105,975, Captures: 19,237,950, Killers: 8,863,512, Quiets: 7,653,768
...and this after searching to depth 8.
Code: Select all
HashMove: 163M Captures: 144M, Killers: 29M, Quiets: 16M
(whether searching even or odd number of plies makes a big difference in the ratios, somehow)