Author: Vincent Diepeveen
Date: 19:24:38 10/23/03
Go up one level in this thread
On October 23, 2003 at 20:29:24, Sune Fischer wrote: >> >>What i also do avoid in diep is writing out code for black and white. I have >>neat loops there where easily possible: >> for( side = 0 ; side <= 2; side++ ) > >Pawns always break symmetry anyway, so it doesn't work 100%. Not sure whether there's already snow falling in your country, hiding the shape of the board, but mine is 8x8, so that's mirrorable in 2 ways at least. So with a bit of good coding 1 pattern can be used 4 times here and you write down it 4 times. Good luck. >>I sure can win a few % there. >> >>Another thing i avoid is mixing 8 bits with 32 bits code. I really try to avoid >>mixing different types whereever possible. >> >>Only for node counts i have 64 bits variables, simply because 32 isn't enough >>there. >> >>>I view portability and readability as more important than the few percent >>>performance I could get from writing some parts in ASM. >> >>Again i agree completely. A very good example is that in so many patterns in my >>evaluation i can speed diep a very little bit up by doing next: >> >>Current code: >> if( board[sq_xx] == piece && color[sq_xx] == xside .... >> >>Trivially i can rewrite this ugly by writing out black & white. >> >>Another way to speed this up in what i think is ugly: >> >> if( !((board[sq_xx]-piece)|(color[sq_xx]-xside)) .... >> >>All together i'm sure i can get diep like that 20% faster with all those dirty >>tricks (assembly even more perhaps), especially the 8 bits code would rock at >>the K7 (and do poor at the opteron). > >Why don't you just access it through a macro, then you quickly test the speed of >different expressions? >I guess you don't like macros either? :) >-S. I do use defines indeed. However i'm not toying with assembly code in DIEP like you are. I prefer to spend my time elsewhere than that. Good luck writing Itanium assembly by the way :)
This page took 0 seconds to execute
Last modified: Thu, 15 Apr 21 08:11:13 -0700
Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.