Author: Uri Blass
Date: 03:42:05 07/19/03
Go up one level in this thread
On July 19, 2003 at 06:33:22, Uri Blass wrote:
>On July 19, 2003 at 06:00:06, Sune Fischer wrote:
>
>>On July 19, 2003 at 05:01:01, Richard Pijl wrote:
>>
>>>If you want to play a match between the Baron and a regular chess engine with
>>>the 16 selected positions that will not change the castling rules, I suggest you
>>>to use the standard Baron version (which is 2-3% faster as well). You should
>>>only use the FRC version of the Baron when playing a 'real' FRC game where the
>>>GUI is prepared to accept the FRC castling notation of Winboard.
>>>
>>>bye,
>>>Richard.
>>
>>Hi Richard
>>
>>Why does FRC slow you down 2-3%?
>>
>>I know it's going to be a little slower, because it doesn't seem possible to
>>unroll the loops when generating castle moves, but 2-3% is a lot IMO, castle
>>moves shouldn't be that frequent.
>
>I think that 2-3% is not a lot and there are cases when changes that should
>change nothing about speed may change the speed by more than it thanks to
>different compiler optimizations.
>
>I got bigger slow down when I decided to change the structure of the files by
>adding a special file for functions that I do not do often like setboard instead
>of having them in the same file as my move generator.
>
>I decided that it is probably not important and only random compiler
>optimizations.
>
>Uri
To be more clear I mean changing the information in the files in my project.
I have a file with the name boolean.c
originally it included only one function that generate arrays.
Here is the function.
void initializepowers()
{
int maskl,i;
char j;
biggest_power[0]=-1;
smallest_power[0]=-1;
for (i=1;i<65536;i++)
{
biggest_power[i]=-1;
smallest_power[i]=-1;
maskl=1;
for(j=0;j<16;j++)
{
if ((maskl & i))
{
biggest_power[i]=j;
if (smallest_power[i]==-1)
smallest_power[i]=j;
}
maskl=maskl<<1;
}
}
}
Later I added some more function that I do not do more than once or do not do in
the search.
For some reason at that time my code became slower by 3-4% but I decided to
ignore it and I prefer not to have functions like setboard in the file of my
move generator because it may do my program less readable when the speed is
probably only a random change that may go for the opposite direction if I change
the code.
Uri
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.