From 946fa4762539307dcdcb30d08f13d627864e9bcf Mon Sep 17 00:00:00 2001 From: lucasart Date: Tue, 5 May 2015 19:10:19 +0800 Subject: [PATCH 1/1] Never clear stats Based on an idea and patch by VoyagerOne. Small simplification, but was tedted for an ELO gain anyway. STC: LLR: 2.95 (-2.94,2.94) [-1.00,4.00] Total: 5375 W: 1119 L: 977 D: 3279 LTC: LLR: 2.95 (-2.94,2.94) [0.00,5.00] Total: 17893 W: 2984 L: 2792 D: 12117 bench 8322847 --- src/movepick.h | 2 -- src/search.cpp | 4 ---- 2 files changed, 6 deletions(-) diff --git a/src/movepick.h b/src/movepick.h index 44fc51f6..423a6a18 100644 --- a/src/movepick.h +++ b/src/movepick.h @@ -21,7 +21,6 @@ #define MOVEPICK_H_INCLUDED #include // For std::max -#include // For std::memset #include "movegen.h" #include "position.h" @@ -44,7 +43,6 @@ struct Stats { const T* operator[](Piece pc) const { return table[pc]; } T* operator[](Piece pc) { return table[pc]; } - void clear() { std::memset(table, 0, sizeof(table)); } void update(Piece pc, Square to, Move m) { diff --git a/src/search.cpp b/src/search.cpp index 18e0cb95..9c7190be 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -339,10 +339,6 @@ namespace { beta = VALUE_INFINITE; TT.new_search(); - History.clear(); - CounterMovesHistory.clear(); - Gains.clear(); - Countermoves.clear(); size_t multiPV = Options["MultiPV"]; Skill skill(Options["Skill Level"]); -- 2.39.2