tildedave / apep-chess-engine

Chess engine that I hacked up in grad school
GNU Lesser General Public License v3.0
3 stars 0 forks source link

segfault on tactics test #5

Closed tildedave closed 13 years ago

tildedave commented 13 years ago

rnb11rk1/ppp11ppp/1b111111/q11P11B1/1111R111/11N11N1P/PP111PP1/R11Q11K1 w - - 0 1

expected: Be7

get error after processing Bxg2 -- was white to move? 1

tildedave commented 13 years ago

bug on 64 bit windows box

tildedave commented 13 years ago

confirmed on 32 bit linux box

tildedave commented 13 years ago

appears to be limited to new max-depth branch

tildedave commented 13 years ago

fixed by starting depth at 1 instead of 0

tildedave commented 13 years ago

1111111Q/11PK1n11/1111P1N1/1pR11111/rb11kNP1/p11n11R1/11B11111/111r1111 w - - 0 1

same issue

tildedave commented 13 years ago

the failing board has two white kings, which makes me think it's a white/black issue. obviously caused by iterative deepening for depths 1,2,3,4,5,6 instead of 2,4,6, so somewhere in the search we are assuming something is bad.

tildedave commented 13 years ago

also possible that this is an unrelated bug that was not caused by iterative deepening (hash collision?)

tildedave commented 13 years ago

issue is caused by generating more moves than the MAX_BRANCH factor

tildedave commented 13 years ago

https://github.com/tildedave/apep-chess-engine/commit/24fdf10e6489539992b60f76927467ca586aac7a