function slider_attacks(sq: TSquare; occ, mask: TBitboard; const deltas: TDeltas): TBitboard;
var
i: integer;
s: TSquare;
begin
result := BB_Empty;
for i := 0 to 3 do begin
s := delta_add(sq, deltas[i]);
while valid_square(integer(s)) and (SquareBB[s] and mask <> 0) do begin
if (square_distance(s, delta_sub(s, deltas[i])) <> 1) then break;
set_bit(result, s);
if SquareBB[s] and occ <> 0 then break;
inc(s, deltas[i]);
end;
end;
end;
while valid_square(integer(s)) and (SquareBB[s] and mask <> 0) do
Is it the case that the Pascal dialect which you're using guarantees short circuit boolean evaluation? If not, I can see where there could be a problem.
This has been an issue with the Bozochess coding. Because I don't know which short circuit scheme (if any) is used by the end user's compiler, I have to code for the most general case and this can mean an extra "if" statement for each subsequent conditional expression.
The program is similarly unresponsive in the Fritz GUI.
When I run OpenCritter 1.1.37 x64 from the command line, it seems to work better. It gets past the GTB initialization phase to the hash allocation phase.
OpenCritter v1.1.37 64bit
by Richard Vida, Slovakia
GTB DLL
C:\Games\Chess\Winboard\OpenCritter_1.1.37\gtb64.dll
GTB PATHS
main: \gtb
GTB initialization
Compression Scheme = 4
Compression Indexes = **FAILED**
GTB Init OK
Hash table: 4194304 entries of 16 bytes = 64 MB total
Eval cache: 32768 entries of 8 bytes = 256 KB total
Pawn hash : 65536 entries of 32 bytes = 2 MB total
2 cpu(s) detected
Opening book: "book.cbk" - 53436 entries [native]
uci
id name OpenCritter v1.1.37
id author Richard Vida
option name Hash type spin default 64 min 16 max 1024
option name Ponder type check default false
option name OwnBook type check default true
option name Book File type string default book.cbk
option name UCI_Chess960 type check default false
option name MultiPV type spin default 1 min 1 max 100
option name Threads type spin default 2 min 1 max 8
option name Minimum Split Depth type spin default 6 min 4 max 10
option name GaviotaTbPath type string default \gtb
option name GaviotaTbCache type spin default 32 min 4 max 256
option name GaviotaTbCompression type combo default cp4 var uncompressed var cp1
var cp2 var cp3 var cp4
option name Tablebase Usage type combo default Only At Root var Disable var Only
At Root var Everywhere
option name Clear Hash type button
uciok
isready
readyok
I don't get it. Why would it act so strangely with a GUI, yet be fine from the command line?
Never mind, I seem to have solved the problem. I replaced the gtb64.dll file in the OpenCritter package with the one from Critter 1.2, and it worked for me after that.