Improving speed

Discussion of chess software programming and technical issues.

Moderators: hgm, Rebel, chrisw

Dann Corbit
Posts: 12538
Joined: Wed Mar 08, 2006 8:57 pm
Location: Redmond, WA USA

Re: Improving speed

Post by Dann Corbit »

Henk wrote:The biggest lie is that after playing many games you assume that everything is working fine for Elo didn't drop and all games finished properly.

Information on user level only telling you lies all the time.

[For lazy testers "code that is not there can't go wrong" as HGM already told us]
After many games, you know the answer to one question:
Stronger or not.
You know nothing about correctness from this.
Taking ideas is not a vice, it is a virtue. We have another word for this. It is called learning.
But sharing ideas is an even greater virtue. We have another word for this. It is called teaching.
Henk
Posts: 7216
Joined: Mon May 27, 2013 10:31 am

Re: Improving speed

Post by Henk »

There is only room for tedious unit testing.
Dann Corbit
Posts: 12538
Joined: Wed Mar 08, 2006 8:57 pm
Location: Redmond, WA USA

Re: Improving speed

Post by Dann Corbit »

Henk wrote:There is only room for tedious unit testing.
Unit testing can be fun.

Don't forget coverage testing.

Regression testing

Blackbox testing

Whitebox testing

Use of assert()

Code review

The fun goes on and on. Quality is key. That's the one for me.
Taking ideas is not a vice, it is a virtue. We have another word for this. It is called learning.
But sharing ideas is an even greater virtue. We have another word for this. It is called teaching.
Henk
Posts: 7216
Joined: Mon May 27, 2013 10:31 am

Re: Improving speed

Post by Henk »

'Why tune bugs' as Sven already told us.
Dann Corbit
Posts: 12538
Joined: Wed Mar 08, 2006 8:57 pm
Location: Redmond, WA USA

Re: Improving speed

Post by Dann Corbit »

Henk wrote:'Why tune bugs' as Sven already told us.
Man, that's sig quality.
Taking ideas is not a vice, it is a virtue. We have another word for this. It is called learning.
But sharing ideas is an even greater virtue. We have another word for this. It is called teaching.
Ras
Posts: 2487
Joined: Tue Aug 30, 2016 8:19 pm
Full name: Rasmus Althoff

Re: Improving speed

Post by Ras »

Henk wrote:I already demolished my code to get a speed of 1.4 million NPS on my machine.
Given the resulting moves, that only means that nonsense is being calculated faster. I'd first go for a more decent static eval so that king safety, mobility, piece positions, pawn structure, rooks on open files are taken into account. Even if that should cut your NPS in half, that would at least be useful calculations, and the engine would be stronger.
User avatar
hgm
Posts: 27790
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Improving speed

Post by hgm »

Note that in the presence of gross misevaluations or move oversights, searching deeper only makes the engine weaker. It will become more clever in finding possibilities to hurt itself.
Henk
Posts: 7216
Joined: Mon May 27, 2013 10:31 am

Re: Improving speed

Post by Henk »

Ras wrote:
Henk wrote:I already demolished my code to get a speed of 1.4 million NPS on my machine.
Given the resulting moves, that only means that nonsense is being calculated faster. I'd first go for a more decent static eval so that king safety, mobility, piece positions, pawn structure, rooks on open files are taken into account. Even if that should cut your NPS in half, that would at least be useful calculations, and the engine would be stronger.
That means I at least have to improve speed by a factor 4 instead of 2 because of the expensive evaluation stuff. It amazes me that Crafty can be so fast.
Dann Corbit
Posts: 12538
Joined: Wed Mar 08, 2006 8:57 pm
Location: Redmond, WA USA

Re: Improving speed

Post by Dann Corbit »

Houdini and Goliath are both stupendously fast.
But beside that, they are relatively correct.

If you hit your head with a hammer 1 million times in a second, it's not a benefit.
Taking ideas is not a vice, it is a virtue. We have another word for this. It is called learning.
But sharing ideas is an even greater virtue. We have another word for this. It is called teaching.
Henk
Posts: 7216
Joined: Mon May 27, 2013 10:31 am

Re: Improving speed

Post by Henk »

Dann Corbit wrote:Houdini and Goliath are both stupendously fast.
But beside that, they are relatively correct.

If you hit your head with a hammer 1 million times in a second, it's not a benefit.
Whatever I do there are always people doing at least thousand times better.