lantonov / asmFish

A continuation of the nice project asmFish by Mohammed Li. Latest version: 07.08.2019

Home Page:https://lantonov.github.io/asmFish/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Support for Bin Books larger than 262MB

CounterPly opened this issue · comments

There appears to be an issue with loading relatively large .bin books -- specifically, those which exceed 262 MB in size. As far as I know, this is a bug unique to asmFishW, and is not present in other SF ports.

Here is a picture demonstrating the result after loading of a 250 MB book and a 300 MB book on both CFish and asmFishW (CFish successfully loads both books, but asmFishW fails to load the larger book):

image

Through further testing, I was able to determine the point at which asmFishW "breaks" to be approximately 262 MB:

image

What exactly is causing this? Could this error possibly be due to the usage of the dword operand in the following portion of book.asm?

image

It is interesting to note that the definition of a qword according to Intel [(2^16) * 4 = 262,144] is also exactly the point at which .bin file loading seem to break. Moreover, after decompiling Cfish, it appears that the use of qword is more abundant in the pb_probe and polyhash sections, but it is still unclear to me how (or if) this is preferable syntax for this fasmg port.

I realize that Mohammed is busy with other projects these days, but any thoughts from anyone on how to go about fixing this bug would be greatly appreciated.

commented

The line with 1 shl 28 gives you the 256MiB. If you want to make sure huge books work, you would also probably have to upgrade book.entryCount from a dword to a qword. It will get done eventually.

Thanks again for this excellent feedback. I made the suggested changes and implemented them here:

CounterPly@a567716

If anyone has additional advice, please feel free to let me know.

Support for ctg Books larger than 10 GB ?

As far as I understand, now the book size is practically limitless (qword instead of dword) but it reads only 16M entries (256MB) at a time.

asmfish team doing too gd . i like asmfish engine and also use . ............. better if engine read larger (book reads +log file ) + syzygy then engine search