X-Git-Url: https://git.sesse.net/?p=stockfish;a=blobdiff_plain;f=src%2Fevaluate.cpp;h=5d8d7b9902ec77fa1e1078e26b7e44725d44da7a;hp=6b15f6c7f0b8838b151aeba3d48380d60da34572;hb=c2d42ea8339b49e52a116e488214a14fda09d413;hpb=5c5af4fa6533e22fb56dd22985cf2b3938efde6c diff --git a/src/evaluate.cpp b/src/evaluate.cpp index 6b15f6c7..5d8d7b99 100644 --- a/src/evaluate.cpp +++ b/src/evaluate.cpp @@ -288,7 +288,7 @@ Value do_evaluate(const Position& pos, Value& margin) { margins[WHITE] = margins[BLACK] = VALUE_ZERO; // Probe the material hash table - ei.mi = Threads[pos.thread()].materialTable.get_material_info(pos); + ei.mi = Threads[pos.thread()].materialTable.material_info(pos); score += ei.mi->material_value(); // If we have a specialized evaluation function for the current material @@ -300,7 +300,7 @@ Value do_evaluate(const Position& pos, Value& margin) { } // Probe the pawn hash table - ei.pi = Threads[pos.thread()].pawnTable.get_pawn_info(pos); + ei.pi = Threads[pos.thread()].pawnTable.pawn_info(pos); score += ei.pi->pawns_value(); // Initialize attack and king safety bitboards @@ -462,8 +462,8 @@ namespace { // no minor piece which can exchange the outpost piece. if (bonus && bit_is_set(ei.attackedBy[Us][PAWN], s)) { - if ( pos.pieces(KNIGHT, Them) == EmptyBoardBB - && (SquaresByColorBB[color_of(s)] & pos.pieces(BISHOP, Them)) == EmptyBoardBB) + if ( !pos.pieces(KNIGHT, Them) + && !(SquaresByColorBB[color_of(s)] & pos.pieces(BISHOP, Them))) bonus += bonus + bonus / 2; else bonus += bonus / 2; @@ -488,7 +488,7 @@ namespace { const Color Them = (Us == WHITE ? BLACK : WHITE); const Square* pl = pos.piece_list(Us, Piece); - ei.attackedBy[Us][Piece] = EmptyBoardBB; + ei.attackedBy[Us][Piece] = 0; while ((s = *pl++) != SQ_NONE) {