How do you generates moves ?
Posted: 11 Aug 2005, 18:46
Hi,
I'm planning of rewriting my chess engine and i'm currently wondering how should I generates moves.
There is lots of possibilities :
We can generates all moves at once, I think Pro Deo do this. The principal advantage is that we can do a better move ordering, however lots of moves get generated, sorted, but never used.
On the opposite we can generate moves one by one. This way we do not generate any move that are not needed, but move ordering is more difficult (SEE and other heuristics can not be used).
A more popular way (I think) is to generates captures first (including promotions) then the others moves if no capture did cause a cutoff.
I currently used the last techniques. However I think this is not the most efficient way. There is probably some hybrid techniques that involve generatings only some moves at a times instead of only one. Or maybe you generates moves from one type of pieces at a time... things like that. I don't really know. I would'nt be asking if I knew.
So how do your engines (or other engines you know about) generates and order moves ?
Mathieu Pag
I'm planning of rewriting my chess engine and i'm currently wondering how should I generates moves.
There is lots of possibilities :
We can generates all moves at once, I think Pro Deo do this. The principal advantage is that we can do a better move ordering, however lots of moves get generated, sorted, but never used.
On the opposite we can generate moves one by one. This way we do not generate any move that are not needed, but move ordering is more difficult (SEE and other heuristics can not be used).
A more popular way (I think) is to generates captures first (including promotions) then the others moves if no capture did cause a cutoff.
I currently used the last techniques. However I think this is not the most efficient way. There is probably some hybrid techniques that involve generatings only some moves at a times instead of only one. Or maybe you generates moves from one type of pieces at a time... things like that. I don't really know. I would'nt be asking if I knew.
So how do your engines (or other engines you know about) generates and order moves ?
Mathieu Pag