This position crashes Houdini 1.5 and Stockfish

Discussion of anything and everything relating to chess playing software and machines.

Moderators: hgm, Dann Corbit, Harvey Williamson

Forum rules
This textbox is used to restore diagrams posted with the [d] tag before the upgrade.
Tom Barrister
Posts: 227
Joined: Tue Oct 05, 2010 3:29 pm

This position crashes Houdini 1.5 and Stockfish

Post by Tom Barrister » Wed Jan 19, 2011 2:28 pm

[D]2r2q1k/6pp/Q4pn1/3p4/2p1n3/5P2/PPP4P/4R1K1 b KQkq

Both Houdini 1.5 64 bit and Stockfish 2.01-ja 64 bit crash when trying to analyze this position with SCID-vs-PC 4.2. Neither outputs much more than gibberish before they crash

Neither has a problem if it's changed to White to move. Toga has no problem analyzing it (except that it can't find the right move).

The position looks normal enough. What causes two engines based on different source to crash but is handled fine by other engines?
This production is being brought to you by Rybka: "The engine made from scratch.™"

bob
Posts: 20923
Joined: Mon Feb 27, 2006 6:30 pm
Location: Birmingham, AL

Re: This position crashes Houdini 1.5 and Stockfish

Post by bob » Wed Jan 19, 2011 2:34 pm

Tom Barrister wrote:[D]2r2q1k/6pp/Q4pn1/3p4/2p1n3/5P2/PPP4P/4R1K1 b KQkq

Both Houdini 1.5 64 bit and Stockfish 2.01-ja 64 bit crash when trying to analyze this position with SCID-vs-PC 4.2. Neither outputs much more than gibberish before they crash

Neither has a problem if it's changed to White to move. Toga has no problem analyzing it (except that it can't find the right move).

The position looks normal enough. What causes two engines based on different source to crash but is handled fine by other engines?
Maybe a depth overflow? The queen check leads to lots of things...

zullil
Posts: 6442
Joined: Mon Jan 08, 2007 11:31 pm
Location: PA USA
Full name: Louis Zulli

Re: This position crashes Houdini 1.5 and Stockfish

Post by zullil » Wed Jan 19, 2011 2:35 pm

Tom Barrister wrote:[D]2r2q1k/6pp/Q4pn1/3p4/2p1n3/5P2/PPP4P/4R1K1 b KQkq
The FEN is incorrect; neither side can castle.

Don't use Houdini, but SF is fine with

Code: Select all

2r2q1k/6pp/Q4pn1/3p4/2p1n3/5P2/PPP4P/4R1K1 b -
(and does indeed seg fault with

Code: Select all

2r2q1k/6pp/Q4pn1/3p4/2p1n3/5P2/PPP4P/4R1K1 b KQkq
)

zullil
Posts: 6442
Joined: Mon Jan 08, 2007 11:31 pm
Location: PA USA
Full name: Louis Zulli

Re: This position crashes Houdini 1.5 and Stockfish

Post by zullil » Wed Jan 19, 2011 2:48 pm

Crafty sees!

Code: Select all

Crafty v23.4 (8 cpus)

White(1): setboard 2r2q1k/6pp/Q4pn1/3p4/2p1n3/5P2/PPP4P/4R1K1 b KQkq
ERROR-- castling status does not match board position
bad string = "2r2q1k/6pp/Q4pn1/3p4/2p1n3/5P2/PPP4P/4R1K1"
Illegal position, using normal initial chess position

zullil
Posts: 6442
Joined: Mon Jan 08, 2007 11:31 pm
Location: PA USA
Full name: Louis Zulli

Re: This position crashes Houdini 1.5 and Stockfish

Post by zullil » Wed Jan 19, 2011 2:50 pm

Tom Barrister wrote:[D]2r2q1k/6pp/Q4pn1/3p4/2p1n3/5P2/PPP4P/4R1K1 b KQkq

Neither has a problem if it's changed to White to move.
No so, at least here:

Code: Select all

position fen 2r2q1k/6pp/Q4pn1/3p4/2p1n3/5P2/PPP4P/4R1K1 w KQkq    
go infinite
info depth 1
info depth 1 seldepth 1 multipv 1 score cp -505 time 583 nodes 818 nps 1403 pv f3e4 
info depth 2
info depth 2 seldepth 3 multipv 1 score cp -505 time 583 nodes 869 nps 1490 pv f3e4 f8c5 g1f1 
info depth 3
info depth 3 seldepth 4 multipv 1 score cp -501 time 583 nodes 1309 nps 2245 pv f3e4 f8c5 g1f1 d5d4 
info depth 4
info depth 4 seldepth 4 multipv 1 score cp -501 time 584 nodes 2244 nps 3842 pv f3e4 c8a8 a6b7 g6e5 
info depth 5
info depth 5 seldepth 8 multipv 1 score cp -537 time 585 nodes 3275 nps 5598 pv f3e4 c8a8 a6b7 g6e5 g1g2 d5e4 e1e4 a8a2 
info depth 6
info depth 6 seldepth 1 multipv 1 score cp -537 time 588 nodes 7519 nps 12787 pv f3e4 
info depth 6 seldepth 1 multipv 1 score cp -499 lowerbound time 588 nodes 8244 nps 14020 pv e1c1 
info depth 6 seldepth 1 multipv 1 score cp -464 lowerbound time 588 nodes 8576 nps 14585 pv e1c1 
info depth 6 seldepth 1 multipv 1 score cp -391 lowerbound time 589 nodes 9195 nps 15611 pv e1c1 
info depth 6 seldepth 11 multipv 1 score cp -363 time 590 nodes 11044 nps 18718 pv e1c1 f8c5 g1h1 e4f2 h1g1 g6h4 a6c8 c5c8 g1f2 c8c5 f2e2 
info depth 7
Segmentation fault

kgburcham
Posts: 2016
Joined: Sun Feb 17, 2008 3:19 pm

Re: This position crashes Houdini 1.5 and Stockfish

Post by kgburcham » Wed Jan 19, 2011 3:09 pm

[D] 2r2q1k/6pp/Q4pn1/3p4/2p1n3/5P2/PPP4P/4R1K1 b - -

Thanks Louis
Houdini 1.5 x64 (4096 MB)

18/51 0:01 -M16 1...Qc5+ 2.Kh1 Nf2+ 3.Kg2 Nf4+ 4.Kf1 N2h3 5.Re3 d4 6.Re4 d3 (33.193.373) 29400
19/51 0:01 -M16 1...Qc5+ 2.Kh1 Nf2+ (40.943.204) 31665
20/51 0:01 -M15 1...Qc5+ 2.Kh1 Nf2+ 3.Kg2 Nf4+ 4.Kf1 N2h3 5.Re3 d4 6.Re4 d3 (67.193.556) 37185
21/51 0:02 -M15 1...Qc5+ (123.051.214) 42622
22/51 0:04 -M15 1...Qc5+ 2.Kh1 Nf2+ 3.Kg2 Nf4+ 4.Kf1 N2h3 5.Re3 d4 (232.452.212) 47997
23/51 0:09 -M9 1...Qc5+ 2.Kh1 Re8 3.Rxe4 dxe4 4.Qa4 Rd8 5.Qa8 Rxa8 (498.617.729) 51670
24/51 0:10 -M9 1...Qc5+ 2.Kh1 Re8 3.Rxe4 dxe4 4.Qa4 Rd8 5.Qa8 Rxa8 (537.585.387) 51840

Stockfish 2.0 JA 64bit (4096 MB)

19/31 0:01 -29.73++ 1...Qc5+ 2.Kh1 Nf2+ 3.Kg2 Nf4+ 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5+ 2.Kh1 Re8 3.Rxe4 dxe4 4.Qa4 Rd8 5.Qa8 Rxa8 6.Kg2 Qe3 (2.180.560.441) 21100
26/17 1:45 -M9 1...Qc5+ 2.Kh1 Re8 3.Rxe4 dxe4 4.Qa4 Rd8 5.Qa8 Rxa8 6.Kg2 Qe3 (2.219.116.672) 21059
27/17 1:46 -M9++ 1...Qc5+ 2.Kh1 Re8 3.Rxe4 dxe4 4.Qa4 Rd8 5.Qa8 Rxa8 6.Kg2 Qe3 (2.247.633.445) 21018

zullil
Posts: 6442
Joined: Mon Jan 08, 2007 11:31 pm
Location: PA USA
Full name: Louis Zulli

Re: This position crashes Houdini 1.5 and Stockfish

Post by zullil » Wed Jan 19, 2011 3:16 pm

kgburcham wrote:[D] 2r2q1k/6pp/Q4pn1/3p4/2p1n3/5P2/PPP4P/4R1K1 b - -

Thanks Louis
You're welcome. By the way, Crafty does well here:

Code: Select all

Crafty v23.4 (8 cpus)

White(1): hash=2048M
Warning--  xboard 'memory' option disabled
hash table memory = 2048M bytes (128M entries).
White(1): setboard 2r2q1k/6pp/Q4pn1/3p4/2p1n3/5P2/PPP4P/4R1K1 b - -
Black(1): st 180
search time set to 180.00.
Black(1): display stats
display statistics at end of each search.
Black(1): go
              time limit 3:00 (+0.00) (3:00)
              depth   time  score   variation (1)
starting thread 1 2 3 4 5 6 7 <done>
               10     0.05     +1   1. ... Qc5+?                    
               10     0.05  -9.29   1. ... Qc5+ 2. Kh1 Nf2+ 3. Kg2 Nh4+  
                                    4. Kg3 Nf5+ 5. Kg2 Nd1 6. Kh1 Nxb2
                                    7. a4 Nh4 8. f4
               10     0.13  -9.43   1. ... Nd2 2. Re3 Rb8 3. Qa3 Qxa3 4. 
                                    Rxa3 Kg8 5. b3 Nxf3+ 6. Kh1 Nf4 7.
                                    bxc4
               10->   0.14  -9.43   1. ... Nd2 2. Re3 Rb8 3. Qa3 Qxa3 4. 
                                    Rxa3 Kg8 5. b3 Nxf3+ 6. Kh1 Nf4 7.
                                    bxc4 &#40;s=2&#41;
               11     0.19  -9.40   1. ... Nd2 2. Kh1 Rb8 3. Qe6 Nxf3 4. 
                                    Rb1 Qc5 5. a4 Qc7 6. Qh3 Nd4
               11->   0.24  -9.40   1. ... Nd2 2. Kh1 Rb8 3. Qe6 Nxf3 4. 
                                    Rb1 Qc5 5. a4 Qc7 6. Qh3 Nd4
               12     0.27     -1   1. ... Nd2!                          
               12     0.31 -10.01   1. ... Nd2 2. Kh1 Re8 3. Re6 Nf4 4.  
                                    Qa5 Rxe6 5. Qxd2 Qb8 6. Qa5 Ng6 7.
                                    Qxd5 Re1+ 8. Kg2 Qxb2 9. Qxc4
               12->   0.36 -10.01   1. ... Nd2 2. Kh1 Re8 3. Re6 Nf4 4.  
                                    Qa5 Rxe6 5. Qxd2 Qb8 6. Qa5 Ng6 7.
                                    Qxd5 Re1+ 8. Kg2 Qxb2 9. Qxc4 &#40;s=3&#41;
               13     0.47 -10.37   1. ... Nd2 2. Re3 d4 3. Re2 Nxf3+ 4.  
                                    Kh1 Rb8 5. b3 Nge5 6. Qe6 Qa3 7. Kg2
                                    Qxa2 8. bxc4 &#40;s=2&#41;
               13->   0.69 -10.37   1. ... Nd2 2. Re3 d4 3. Re2 Nxf3+ 4.  
                                    Kh1 Rb8 5. b3 Nge5 6. Qe6 Qa3 7. Kg2
                                    Qxa2 8. bxc4 &#40;s=3&#41;
               14     1.00 -10.68   1. ... Nd2 2. Kh1 Re8 3. Rxe8 Qxe8    
                                    4. Qa7 Nxf3 5. Qa5 Qb8 6. Kg2 Ngh4+
                                    7. Kf1 Nxh2+ 8. Ke2 Qe5+ 9. Kd1 Qd4+
                                    10. Kc1 Qg1+ 11. Kd2 &#40;s=2&#41;
               14     1.24     -1   1. ... Qc5+!                          
               14     1.31     -3   1. ... Qc5+!                          
               14     1.44     -M   1. ... Qc5+!                          
               14     2.47 -20.26   1. ... Qc5+ 2. Kh1 Re8 3. Re2 Nf2+    
                                    4. Kg2 Rxe2 5. Qa8+ Nf8 6. Kf1 Nd3
                                    7. Qxf8+ Qxf8 8. cxd3 cxd3 9. a4 Rxb2
               14->   2.47 -20.26   1. ... Qc5+ 2. Kh1 Re8 3. Re2 Nf2+
                                    4. Kg2 Rxe2 5. Qa8+ Nf8 6. Kf1 Nd3
                                    7. Qxf8+ Qxf8 8. cxd3 cxd3 9. a4 Rxb2
               15     2.58 -20.44   1. ... Qc5+ 2. Kh1 Re8 3. Re2 Nf2+    
                                    4. Kg2 Rxe2 5. Qa8+ Nf8 6. Kf1 Nd3
                                    7. Qxf8+ Qxf8 8. cxd3 cxd3 9. a4 Rxb2
                                    10. h4
               15->   2.65 -20.44   1. ... Qc5+ 2. Kh1 Re8 3. Re2 Nf2+    
                                    4. Kg2 Rxe2 5. Qa8+ Nf8 6. Kf1 Nd3
                                    7. Qxf8+ Qxf8 8. cxd3 cxd3 9. a4 Rxb2
                                    10. h4
               16     2.72     -1   1. ... Qc5+!                          
               16     2.88 -20.93   1. ... Qc5+ 2. Kh1 Re8 3. Re2 Nf2+    
                                    4. Kg2 Rxe2 5. Qa8+ Nf8 6. Kf1 Nd3
                                    7. Qxf8+ Qxf8 8. cxd3 cxd3 9. a4 Rxb2
                                    10. a5 Rxh2
               16->   3.02 -20.93   1. ... Qc5+ 2. Kh1 Re8 3. Re2 Nf2+    
                                    4. Kg2 Rxe2 5. Qa8+ Nf8 6. Kf1 Nd3
                                    7. Qxf8+ Qxf8 8. cxd3 cxd3 9. a4 Rxb2
                                    10. a5 Rxh2 &#40;s=2&#41;
               17     3.23     -1   1. ... Qc5+!                          
               17     3.33     -3   1. ... Qc5+!                          
               17     3.50     -M   1. ... Qc5+!                          
               17     3.94 -25.45   1. ... Qc5+ 2. Kh1 Re8 3. Re2 Ng3+    
                                    4. hxg3 Rxe2 5. Qa8+ Nf8 6. Qe8 Rxe8
                                    7. Kg2 Re2+ 8. Kh3 Rxc2 9. b4 Qxb4
                                    10. Kg4 Rxa2 11. Kf4
               17->   4.27 -25.45   1. ... Qc5+ 2. Kh1 Re8 3. Re2 Ng3+    
                                    4. hxg3 Rxe2 5. Qa8+ Nf8 6. Qe8 Rxe8
                                    7. Kg2 Re2+ 8. Kh3 Rxc2 9. b4 Qxb4
                                    10. Kg4 Rxa2 11. Kf4
               18     4.70     -1   1. ... Qc5+!                          
               18     4.78     -3   1. ... Qc5+!                          
               18     4.88     -M   1. ... Qc5+!                          
               18    16.99 -Mat09   1. ... Qc5+ 2. Kh1 Re8 3. Rf1 Nf2+    
                                    4. Kg2 Qe3 5. Qxf6 gxf6 6. Rxf2 Nh4+
                                    7. Kh3 Qxf2 8. f4 Qxf4 9. b4 Re3#
               18->  17.58 -Mat09   1. ... Qc5+ 2. Kh1 Re8 3. Rf1 Nf2+    
                                    4. Kg2 Qe3 5. Qxf6 gxf6 6. Rxf2 Nh4+
                                    7. Kh3 Qxf2 8. f4 Qxf4 9. b4 Re3#
              time=17.58  mat=-6  n=597455800  fh=95%  nps=34.0M
              extensions=35.0M qchecks=88.2M reduced=24.8M pruned=219.0M
              predicted=0  evals=5.2M  50move=0  EGTBprobes=0  hits=0
              SMP->  splits=15433  aborts=1459  data=49/512  elap=17.58
terminating SMP processes.

mate in 9 moves.

Black&#40;1&#41;&#58; Qc5+
              time used&#58;  17.58

bob
Posts: 20923
Joined: Mon Feb 27, 2006 6:30 pm
Location: Birmingham, AL

Re: This position crashes Houdini 1.5 and Stockfish

Post by bob » Wed Jan 19, 2011 3:57 pm

zullil wrote:Crafty sees!

Code: Select all

Crafty v23.4 &#40;8 cpus&#41;

White&#40;1&#41;&#58; setboard 2r2q1k/6pp/Q4pn1/3p4/2p1n3/5P2/PPP4P/4R1K1 b KQkq
ERROR-- castling status does not match board position
bad string = "2r2q1k/6pp/Q4pn1/3p4/2p1n3/5P2/PPP4P/4R1K1"
Illegal position, using normal initial chess position
Did not notice the bogus castling status in the FEN string. :) That will cause many problems for programs that don't at least sanity-check the FEN before starting a search.

mcostalba
Posts: 2684
Joined: Sat Jun 14, 2008 7:17 pm

Re: This position crashes Houdini 1.5 and Stockfish

Post by mcostalba » Wed Jan 19, 2011 6:05 pm

bob wrote:That will cause many problems for programs that don't at least sanity-check the FEN before starting a search.
No, we don't sanity-check the FEN string.

Personally I don't believe in fixing downstream, I believe more in fixing upstream (read the GUI)...incidentally that's the reason why SF currently experiences time losses with Arena and, if it is up to me, it will experience also in the future ;-)

Michel
Posts: 2219
Joined: Sun Sep 28, 2008 11:50 pm

Re: This position crashes Houdini 1.5 and Stockfish

Post by Michel » Wed Jan 19, 2011 6:43 pm

Personally I don't believe in fixing downstream,
Yes. But SF shouldn't segfault on incorrect input. So sanity checking of the FEN is necessary anyway.

Post Reply