Search found 284 matches

by Sesse
Mon Dec 28, 2020 12:22 am
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: Asynchronous tablebase lookups
Replies: 9
Views: 2175

Re: Asynchronous tablebase lookups

An effect I hadn't thought of: It seems that synchronous tablebase lookups also make the “stop” command a bit slower, since there's no way to abort an mmap-induced I/O operation. Of course, with an SSD we're only talking milliseconds, but on rotating media with many threads hammering, you could get ...
by Sesse
Wed Dec 23, 2020 12:51 am
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: Advent of Code 2020
Replies: 5
Views: 1522

Re: Advent of Code 2020

Isn't day 13 part 2 just the Chinese remainder theorem? It can be solved by hand if you wish. Or you can use any of the available online CRT calculators, which will find the answer in a split second.
by Sesse
Tue Dec 22, 2020 11:43 pm
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: Position Causes Stockfish and Komodo To Crash
Replies: 135
Views: 18635

Re: Position causes StockFish and Komodo to crash.

Michel wrote:
Tue Dec 22, 2020 7:57 pm
I strongly doubt that this micro optimization brings any Elo.
It's been there since the very first Stockfish commit (import of Glaurung 2.1). Perhaps this is a good chance to get a commit in as a simplification? =)
by Sesse
Tue Dec 22, 2020 1:17 pm
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: Position Causes Stockfish and Komodo To Crash
Replies: 135
Views: 18635

Re: Position Causes Stockfish and Komodo To Crash

This just makes me even more convinced you'll need to just brute-force the possible unmoves to see if there are any. :-)
by Sesse
Mon Dec 21, 2020 5:34 pm
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: Advent of Code 2020
Replies: 5
Views: 1522

Re: Advent of Code 2020

If you want to compete for the top spots, you'll either need to live in a “good” timezone or get up really early in the morning. Not worth it. :-)
by Sesse
Sun Dec 20, 2020 3:22 pm
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: Asynchronous tablebase lookups
Replies: 9
Views: 2175

Re: Asynchronous tablebase lookups

I guess it's time for me to look into io_uring ;-) It's surprisingly comfortable! (But do use liburing, not the syscalls directly.) So one approach would be to let the TB probe fail if it the data is not immediately available. This is what the Gaviota probing code can do as well ("soft probes"). Bu...
by Sesse
Sun Dec 20, 2020 1:24 pm
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: Asynchronous tablebase lookups
Replies: 9
Views: 2175

Re: Asynchronous tablebase lookups

Not sure about that. The page faults are already happening now anyway. But it may be tricky to roll back the TB probe efficiently. But there's no good reason why they'd need to happen? io_uring will give you I/O without ever transitioning into kernel space. If you can do 1M TB lookups per second, i...
by Sesse
Sun Dec 20, 2020 1:13 pm
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: Position Causes Stockfish and Komodo To Crash
Replies: 135
Views: 18635

Re: Position Causes Stockfish and Komodo To Crash

syzygy wrote:
Sun Dec 20, 2020 1:08 pm
In my browser the diagram in your post has extra squares i1, j1, k1, l1 with a black bishop on j1 and a black rook on k1. But in this reply those extra squares seem to disappear...
Yeah, I noticed so myself. They didn't appear in preview when I wrote the post, however…
by Sesse
Sun Dec 20, 2020 11:42 am
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: Asynchronous tablebase lookups
Replies: 9
Views: 2175

Re: Asynchronous tablebase lookups

TBH I think you have to just abandon mmap to get this kind of performance going. You don't want to be roundtripping through the kernel on every I/O.
by Sesse
Sun Dec 20, 2020 11:12 am
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: Position Causes Stockfish and Komodo To Crash
Replies: 135
Views: 18635

Re: Position Causes Stockfish and Komodo To Crash

It seems you don't even need a double-check to make an unreachable position. For instance, how did this happen? [D]k1R5/2p4K/8/pp1ppppp/rnbq1bnr/8/PPPPPPPP/RNBQ1BN1 OTOH, I guess it should be fairly cheap to backwards-generate all moves, captures and promotions and see if any of them are without che...