diff --git a/src/evaluate.cpp b/src/evaluate.cpp index 177d29345fa..d533eed8c76 100644 --- a/src/evaluate.cpp +++ b/src/evaluate.cpp @@ -210,7 +210,7 @@ namespace { // in KingDanger[]. Various little "meta-bonuses" measuring the strength // of the enemy attack are added up into an integer, which is used as an // index to KingDanger[]. - Score KingDanger[512]; + Score KingDanger[400]; // KingAttackWeights[PieceType] contains king attack weights by piece type const int KingAttackWeights[PIECE_TYPE_NB] = { 0, 0, 7, 5, 4, 1 }; diff --git a/src/search.cpp b/src/search.cpp index 9dfa5193e99..7fafe933d5f 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -725,8 +725,8 @@ namespace { // Step 6. Razoring (skipped when in check) if ( !PvNode && depth < 4 * ONE_PLY - && eval + razor_margin[depth / ONE_PLY] <= alpha - && ttMove == MOVE_NONE) + && ttMove == MOVE_NONE + && eval + razor_margin[depth / ONE_PLY] <= alpha) { if ( depth <= ONE_PLY && eval + razor_margin[3 * ONE_PLY] <= alpha) @@ -924,8 +924,8 @@ namespace { && !captureOrPromotion && !inCheck && !givesCheck - && !pos.advanced_pawn_push(move) - && bestValue > VALUE_MATED_IN_MAX_PLY) + && bestValue > VALUE_MATED_IN_MAX_PLY + && !pos.advanced_pawn_push(move)) { // Move count based pruning if (moveCountPruning)