OK, but that procedure calling involves overhead is well known. The issue here if it would pay to implement apha-beta fully. Be it recursively or iteratively. My post that you quoted showed the iterative version of the fully implemented alpha-beta.bob wrote:A recursive implementation depends on procedure calls and returns, which is less efficient because of the call instruction in X86. An iterative approach (which I have always used) avoids this overhead completely. I have tried this recursive approach, just for fun, but there is a small speed penalty. But since this gets executed so frequently, it has a measurable impact on overall speed.
SEE algorithm on chessprogramming wiki
Moderator: Ras
-
- Posts: 28386
- Joined: Fri Mar 10, 2006 10:06 am
- Location: Amsterdam
- Full name: H G Muller
Re: SEE algorithm on chessprogramming wiki
-
- Posts: 20943
- Joined: Mon Feb 27, 2006 7:30 pm
- Location: Birmingham, AL
Re: SEE algorithm on chessprogramming wiki
I would never argue with that point. My alpha/beta search in Cray Blitz was fully iterative since when it was started, FORTRAN didn't support recursion at all. (they used a fixed static area to store registers which included the return address so recursion would introduce an instant infinite loop). I like the look of the recursive SEE, but not the speed.hgm wrote:OK, but that procedure calling involves overhead is well known. The issue here if it would pay to implement apha-beta fully. Be it recursively or iteratively. My post that you quoted showed the iterative version of the fully implemented alpha-beta.bob wrote:A recursive implementation depends on procedure calls and returns, which is less efficient because of the call instruction in X86. An iterative approach (which I have always used) avoids this overhead completely. I have tried this recursive approach, just for fun, but there is a small speed penalty. But since this gets executed so frequently, it has a measurable impact on overall speed.