Search found 2142 matches

by Michael Sherwin
Sun Apr 21, 2019 1:29 pm
Forum: Computer Chess Club: General Topics
Topic: Contrived position for perft
Replies: 13
Views: 284

Re: Contrived position for perft

How aboud this? [D] r6r/1bp2pP1/R2qkn2/1P6/1pPQ4/1B3N2/1B1P2p1/4K2R b KQ c3 0 It adds pins of the 2 possible kinds: * the normal pin, where from->to causes self-check through the vacated from square. * the en-passant special case, where from->to causes self-check, through the square vacated by the ...
by Michael Sherwin
Sun Apr 21, 2019 7:02 am
Forum: Computer Chess Club: General Topics
Topic: Resurection
Replies: 1
Views: 115

Re: Resurection

There are 12 letters in resurrection like the 12 disciples. But, I noticed that there is one disciple missing. Must be Judas Iscariot! :mrgreen:
by Michael Sherwin
Sun Apr 21, 2019 6:29 am
Forum: Computer Chess Club: General Topics
Topic: Contrived position for perft
Replies: 13
Views: 284

Re: Contrived position for perft

lucasart wrote:
Sun Apr 21, 2019 5:12 am
Michael Sherwin wrote:
Sun Apr 21, 2019 3:10 am
Does it cover all the possibilities? Has someone done a better one already? Any suggested changes?

Thanks
nice one. pins are an important source of bugs. you should add more pins.
Bed time, I will work on that tomorrow! :D
by Michael Sherwin
Sun Apr 21, 2019 3:10 am
Forum: Computer Chess Club: General Topics
Topic: Contrived position for perft
Replies: 13
Views: 284

Contrived position for perft

Does it cover all the possibilities? Has someone done a better one already? Any suggested changes?

Thanks
by Michael Sherwin
Sat Apr 20, 2019 10:36 pm
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: SMP, game struct, thread struct and MakeMove
Replies: 6
Views: 252

Re: SMP, game struct, thread struct and MakeMove

Do I need a separate Make Move for the game history record? In Jumbo the game history is simply part of the Board object (so "Board" is more like "Game with current position and history"). The small memory overhead is negligible but the gain of simplicity is significant in my view. Each search thre...
by Michael Sherwin
Sat Apr 20, 2019 7:57 pm
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: Pointers in C++, please help
Replies: 4
Views: 138

Re: Pointers in C++, please help

Hi Ras, Thanks! How would it be done with good practice in C++? I have no clue. You'd use some of the STL provided types. You could use either a std::vector inside another std::vector, or std::array inside another std::array. I think the latter will be faster here because the dimensions are fixed s...
by Michael Sherwin
Sat Apr 20, 2019 7:20 pm
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: Pointers in C++, please help
Replies: 4
Views: 138

Re: Pointers in C++, please help

If you have this: *(mvs + (((fs << 3) + n))) = ts; // I want to do something like, mvs[fs][n] = ts; then the shift suggests that the n variable stretches over 3 bit, i.e. it can go from 0 to 7. That means a lower array dimenion of 8. Assuming that the other dimension is also 8 because it is about a...
by Michael Sherwin
Sat Apr 20, 2019 6:58 pm
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: Pointers in C++, please help
Replies: 4
Views: 138

Pointers in C++, please help

I've spent hours in my C++ primer and other books and online with no success. I want to use a pointer to a two dimensional array like it was an array name. This code works and I am okay with that but it uses pure pointer arithmetic, however, for readability I want to use the pointer like array notat...
by Michael Sherwin
Sat Apr 20, 2019 2:26 pm
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: No standard specification for Perft
Replies: 22
Views: 410

Re: No standard specification for Perft

If you want perft to be a representative measure of the speed of an engine it should indeed focus more on capture-only generation. Perthaps it would be useful to define a function perft(N, M) which does N ply of full-width search followed by M ply of captures only. Most people use perft only for te...
by Michael Sherwin
Sat Apr 20, 2019 4:45 am
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: My newest almost bb move generator is wonderful
Replies: 16
Views: 870

Re: My newest almost bb move generator is wonderful

Well at least I have 'proof of concept' as perft 1 generated the correct 20 moves. The black move generators are still empty functions and I'm out of time for today. // A Simple Perft void Perft(threadS *t, u08 depth) { u08 id = t->wtm ? 19 : 39, typ; while (id) { id = t->nxt[id]; typ = t->typ[id]; ...