Jump to content

  • Log In with Google      Sign In   
  • Create Account

We're offering banner ads on our site from just $5!

1. Details HERE. 2. GDNet+ Subscriptions HERE. 3. Ad upload HERE.


#Actualpatishi

Posted 18 July 2013 - 05:06 PM

it seems that i also added points to non-cut off moves, e.g best move after a search, that's the explanation for the first question above.     
But now i switched to only score cut off moves, and there may have been a tiny improvement.     also, it doesn't seem that the hash move is doing anything special..with or without it, the speed is roughly the same.        i am using the two big replacement scheme in the TT , and ordering the moves just like john tromp explains...but still it takes too much time in certain positions.    (by the way, i abandoned the evaluate for one move idea..it's not that good smile.png  )    
 

And most of my code is fast, not so very different for the john tromp bitBoard implementation.      the one thing i think that can contribute to the slowness is my getMoves()  method.   i am creating a java ArrayList in every alpha beta function which hold all the move.   inside this function,   I also sort the moves according to the History table with bubble sort kinda loop..but with java  methods such as :    set(index,element) etc..  which also can be very slow i think.   (not like sorting a normal array).      
The reasin i am using java array list is because i can't know in advance how much available columns i have in a position,  and a normal array is a fixed size structure..while i need a dynamic structure.        

Ofcourse there are ways to increase the array side dynamiacally but it involving recreat new array every time i need to add an element.  (that's actually what the array list is doing in the background + some other bonus stuff that can cause even more slowness).   
I wasn't able to figure out a way to iterate and sort the moves inside the alpha beta without making a hell of a mess in my code smile.png


#1patishi

Posted 18 July 2013 - 05:03 PM

it seems that i also added points to non-cut off moves, e.g best move after a search, that's the explanation for the first question above.     
But now i switched to only score cut off moves, and there may have been a tiny improvement.     also, it doesn't seem that the hash move is doing anything special..with or without it, the speed is roughly the same.        i am using the two big replacement scheme in the TT , and ordering the moves just like john tromp explains...but still it takes too much time in certain positions.    (by the way, i abandoned the evaluate for one move idea..it's not that good :)  )    
 

And most of my code is fast, not so very different for the john tromp bitBoard implementation.      the one thing i think that can contribute to the slowness is my getMoves()  method.   i am creating a java ArrayList in every alpha beta function which hold all the move.   inside this function,   I also sort the moves according to the History table with bubble sort kinda loop..but with java  methods such as :    set(index,element) etc..  which also can be very slow i think.   (not like sorting a normal array).      
The reasin i am using java array list id because i can't know in advance how much available columns i have in a position,  and a normal array is a fixed size structure..while i need a dynamic structure.        

Ofcourse there are ways to increase the array side dynamiacally but it involving recreat new array every time i need to add an element.  (that's actually what the array list is doing in the background + some other bonus stuff that can cause even more slowness).   
I wasn't able to figure out a way to iterate and sort the moves inside the alpha beta without making a hell of a mess in my code :)


PARTNERS