Author: José Carlos
Date: 08:20:47 06/05/01
Go up one level in this thread
On June 05, 2001 at 10:20:19, Colin Frayn wrote:
>On June 05, 2001 at 08:56:05, Vincent Diepeveen wrote:
>
>>Now see what i get in beowulf. Instead of that in 2001 dudes program
>>better they program things out FOR EVERY PIECE.
>>Even blackpawns and whitepawns are written out.
>>Man such a student i would directly ship back.
>
>Well if you can speed it up your way, then go ahead. Come back and continue
>complaining if you can get 1% speed increase out of it. In fact I would be
>surprised if you can avoid a 5% speed drop by writing it as you say.
>
>>How do you plan to let people learn from this code?
>>They must learn to "write everything out"??
>
>Only if they want their code to work quickly. It's their choice, I suppose.
>
>>Please use a few for loops, even in bitboards you can do that,
>>or have you forgotten how loops work?
>
>I just remembered how slow they are. Perhaps you would find a loop easier to
>read, but I tend to find things easier when they're written out in a logical
>fashion.
>
>Run my movegen against yours and post the results.
>
>Cheers,
>Col
I haven't had time to download your code and have a look at it but, from what
I read in Vincent's post, I see you do a lot of:
if (side == WHITE) {} else {}
...actually for every piece. You'd go faster doing only once that 'if' and
then the code for every piece:
if (side == WHITE)
{
// White pawns
...
// White knight
...
etc...
}
else
{
// Black pawns
...
// Black knight
...
etc...
}
Just one comment :) I don't intent to say your code is slow.
José C.
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.