X-Git-Url: https://git.sesse.net/?p=stockfish;a=blobdiff_plain;f=src%2Fsearch.cpp;h=e7e33edef8f7acd4b1b41e9861e7a78e36158c03;hp=9a2bd41565911c1bd1179df7d074a20b72ed0846;hb=b37054c310876850f6ff65b19f6cdb5f941c57dc;hpb=8a74c089286913f24a641aa37532006088d0f438 diff --git a/src/search.cpp b/src/search.cpp index 9a2bd415..e7e33ede 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -787,11 +787,7 @@ namespace { } else { - // In case of null move search use previous static eval with a different sign - if ((ss-1)->currentMove != MOVE_NULL) - ss->staticEval = eval = evaluate(pos); - else - ss->staticEval = eval = -(ss-1)->staticEval; + ss->staticEval = eval = evaluate(pos); // Save static evaluation into transposition table if(!excludedMove) @@ -893,19 +889,16 @@ namespace { assert(probCutBeta < VALUE_INFINITE); MovePicker mp(pos, ttMove, probCutBeta - ss->staticEval, &captureHistory); - int probCutCount = 0; bool ttPv = ss->ttPv; ss->ttPv = false; - while ( (move = mp.next_move()) != MOVE_NONE - && probCutCount < 2 + 2 * cutNode) + while ((move = mp.next_move()) != MOVE_NONE) if (move != excludedMove && pos.legal(move)) { assert(pos.capture_or_promotion(move)); assert(depth >= 5); captureOrPromotion = true; - probCutCount++; ss->currentMove = move; ss->continuationHistory = &thisThread->continuationHistory[ss->inCheck]