mirror of
https://github.com/opelly27/Stockfish.git
synced 2026-05-20 06:17:49 +00:00
removed second killer move
STC with movepicker rewrite: LLR: 2.93 (-2.94,2.94) <-1.75,0.25> Total: 46656 W: 12208 L: 11995 D: 22453 Ptnml(0-2): 203, 5461, 11777, 5694, 193 https://tests.stockfishchess.org/tests/view/668d98a15034141ae5999e68 Earlier version passed STC: LLR: 2.94 (-2.94,2.94) <0.00,2.00> Total: 468896 W: 120999 L: 120054 D: 227843 Ptnml(0-2): 1207, 55209, 120639, 56218, 1175 https://tests.stockfishchess.org/tests/view/668b17d2cf91c430fca58630 Earlier version passed LTC: LLR: 2.94 (-2.94,2.94) <-1.75,0.25> Total: 550524 W: 139553 L: 139877 D: 271094 Ptnml(0-2): 333, 61646, 151616, 61346, 321 https://tests.stockfishchess.org/tests/view/668b2e04cf91c430fca586b1 closes https://github.com/official-stockfish/Stockfish/pull/5472 bench 1234309 Co-authored-by: rn5f107s2 <clemens.lerchl@gmail.com>
This commit is contained in:
committed by
Joost VandeVondele
parent
6135a0e2f8
commit
8d1e41458e
+12
-16
@@ -20,7 +20,6 @@
|
||||
|
||||
#include <algorithm>
|
||||
#include <cassert>
|
||||
#include <iterator>
|
||||
#include <utility>
|
||||
|
||||
#include "bitboard.h"
|
||||
@@ -35,7 +34,7 @@ enum Stages {
|
||||
MAIN_TT,
|
||||
CAPTURE_INIT,
|
||||
GOOD_CAPTURE,
|
||||
REFUTATION,
|
||||
KILLER,
|
||||
QUIET_INIT,
|
||||
GOOD_QUIET,
|
||||
BAD_CAPTURE,
|
||||
@@ -91,14 +90,14 @@ MovePicker::MovePicker(const Position& p,
|
||||
const CapturePieceToHistory* cph,
|
||||
const PieceToHistory** ch,
|
||||
const PawnHistory* ph,
|
||||
const Move* killers) :
|
||||
Move km) :
|
||||
pos(p),
|
||||
mainHistory(mh),
|
||||
captureHistory(cph),
|
||||
continuationHistory(ch),
|
||||
pawnHistory(ph),
|
||||
ttMove(ttm),
|
||||
refutations{{killers[0], 0}, {killers[1], 0}},
|
||||
killer{km, 0},
|
||||
depth(d) {
|
||||
assert(d > 0);
|
||||
|
||||
@@ -268,19 +267,17 @@ top:
|
||||
}))
|
||||
return *(cur - 1);
|
||||
|
||||
// Prepare the pointers to loop over the refutations array
|
||||
cur = std::begin(refutations);
|
||||
endMoves = std::end(refutations);
|
||||
|
||||
++stage;
|
||||
[[fallthrough]];
|
||||
|
||||
case REFUTATION :
|
||||
if (select<Next>([&]() {
|
||||
return *cur != Move::none() && !pos.capture_stage(*cur) && pos.pseudo_legal(*cur);
|
||||
}))
|
||||
return *(cur - 1);
|
||||
case KILLER :
|
||||
// increment it before so if we aren't stuck here indefinitely
|
||||
++stage;
|
||||
|
||||
if (killer != ttMove && killer != Move::none() && !pos.capture_stage(killer)
|
||||
&& pos.pseudo_legal(killer))
|
||||
return killer;
|
||||
|
||||
[[fallthrough]];
|
||||
|
||||
case QUIET_INIT :
|
||||
@@ -297,8 +294,7 @@ top:
|
||||
[[fallthrough]];
|
||||
|
||||
case GOOD_QUIET :
|
||||
if (!skipQuiets
|
||||
&& select<Next>([&]() { return *cur != refutations[0] && *cur != refutations[1]; }))
|
||||
if (!skipQuiets && select<Next>([&]() { return *cur != killer; }))
|
||||
{
|
||||
if ((cur - 1)->value > -7998 || (cur - 1)->value <= quiet_threshold(depth))
|
||||
return *(cur - 1);
|
||||
@@ -327,7 +323,7 @@ top:
|
||||
|
||||
case BAD_QUIET :
|
||||
if (!skipQuiets)
|
||||
return select<Next>([&]() { return *cur != refutations[0] && *cur != refutations[1]; });
|
||||
return select<Next>([&]() { return *cur != killer; });
|
||||
|
||||
return Move::none();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user