]> git.sesse.net Git - stockfish/blobdiff - src/evaluate.cpp
Use "rm -f" instead of "rm" for gcc profiling hack in Makefile
[stockfish] / src / evaluate.cpp
index b47570e86303863cc968e632ca49b15ca9e175b0..38f2d604ce9f05ad588631531b6119be1b2b91bc 100644 (file)
@@ -503,10 +503,9 @@ namespace {
     Bitboard b, weak, defended;
     Score score = SCORE_ZERO;
 
-    // Non-pawn enemies defended by a pawn and under our attack
+    // Non-pawn enemies defended by a pawn
     defended =  (pos.pieces(Them) ^ pos.pieces(Them, PAWN))
-              &  ei.attackedBy[Them][PAWN]
-              & (ei.attackedBy[Us][KNIGHT] | ei.attackedBy[Us][BISHOP] | ei.attackedBy[Us][ROOK]);
+              &  ei.attackedBy[Them][PAWN];
 
     // Add a bonus according to the kind of attacking pieces
     if (defended)
@@ -703,7 +702,7 @@ namespace {
     // If we have a specialized evaluation function for the current material
     // configuration, call it and return.
     if (ei.mi->specialized_eval_exists())
-        return ei.mi->evaluate(pos) + Eval::Tempo;
+        return ei.mi->evaluate(pos);
 
     // Probe the pawn hash table
     ei.pi = Pawns::probe(pos, thisThread->pawnsTable);