Use incremental updates more often
[stockfish] / src / nnue / features / half_kp.cpp
index 88e384a3578cf6156fc24c6a9c00e5a4a753aca5..116157cc19d1b6e555fb39a39dd18ee1822fd9a3 100644 (file)
@@ -52,11 +52,10 @@ namespace Eval::NNUE::Features {
   // Get a list of indices for recently changed features
   template <Side AssociatedKing>
   void HalfKP<AssociatedKing>::AppendChangedIndices(
-      const Position& pos, Color perspective,
+      const Position& pos, const DirtyPiece& dp, Color perspective,
       IndexList* removed, IndexList* added) {
 
     Square ksq = orient(perspective, pos.square<KING>(perspective));
-    const auto& dp = pos.state()->dirtyPiece;
     for (int i = 0; i < dp.dirty_num; ++i) {
       Piece pc = dp.piece[i];
       if (type_of(pc) == KING) continue;