From: Marco Costalba Date: Mon, 14 Aug 2017 16:12:16 +0000 (-0700) Subject: Fix incorrect StateInfo X-Git-Url: https://git.sesse.net/?p=stockfish;a=commitdiff_plain;h=232c50fed0b80a0f39322a925575f760648ae0a5;hp=232c50fed0b80a0f39322a925575f760648ae0a5 Fix incorrect StateInfo We use Position::set() to set root position across threads. But there are some StateInfo fields (previous, pliesFromNull, capturedPiece) that cannot be deduced from a fen string, so set() clears them and to not lose the info we need to backup and later restore setupStates->back(). Note that setupStates is shared by threads but is accessed in read-only mode. This fixes regression introduced by df6cb446eaf21 Tested with 3 threads at STC: LLR: 2.95 (-2.94,2.94) [-4.00,0.00] Total: 14436 W: 2304 L: 2196 D: 9936 Bench: 5608839 ---