Skip to content
Permalink
Browse files

Bench: 3064056

  • Loading branch information...
DU-jdto
DU-jdto committed Jan 4, 2019
1 parent bb843a0 commit 6cc68b594f66dcb51be7aeea6c93c5cc7501f613
Showing with 6 additions and 13 deletions.
  1. +4 −7 src/movepick.cpp
  2. +1 −3 src/movepick.h
  3. +1 −2 src/search.cpp
  4. +0 −1 src/types.h
@@ -70,15 +70,13 @@ MovePicker::MovePicker(const Position& p, Move ttm, Depth d, const ButterflyHist

/// MovePicker constructor for quiescence search
MovePicker::MovePicker(const Position& p, Move ttm, Depth d, const ButterflyHistory* mh,
const CapturePieceToHistory* cph, const PieceToHistory** ch, Square rs)
: pos(p), mainHistory(mh), captureHistory(cph), continuationHistory(ch), recaptureSquare(rs), depth(d) {
const CapturePieceToHistory* cph, const PieceToHistory** ch)
: pos(p), mainHistory(mh), captureHistory(cph), continuationHistory(ch), depth(d) {

assert(d <= DEPTH_ZERO);

stage = pos.checkers() ? EVASION_TT : QSEARCH_TT;
ttMove = ttm
&& pos.pseudo_legal(ttm)
&& (depth > DEPTH_QS_RECAPTURES || to_sq(ttm) == recaptureSquare) ? ttm : MOVE_NONE;
ttMove = ttm && pos.pseudo_legal(ttm) ? ttm : MOVE_NONE;
stage += (ttMove == MOVE_NONE);
}

@@ -239,8 +237,7 @@ Move MovePicker::next_move(bool skipQuiets) {
return select<Best>([&](){ return pos.see_ge(move, threshold); });

case QCAPTURE:
if (select<Best>([&](){ return depth > DEPTH_QS_RECAPTURES
|| to_sq(move) == recaptureSquare; }))
if (select<Best>([&](){ return true; }))
return move;

// If we did not find any move and we do not try checks, we have finished
@@ -120,8 +120,7 @@ class MovePicker {
MovePicker(const Position&, Move, Value, const CapturePieceToHistory*);
MovePicker(const Position&, Move, Depth, const ButterflyHistory*,
const CapturePieceToHistory*,
const PieceToHistory**,
Square);
const PieceToHistory**);
MovePicker(const Position&, Move, Depth, const ButterflyHistory*,
const CapturePieceToHistory*,
const PieceToHistory**,
@@ -143,7 +142,6 @@ class MovePicker {
ExtMove refutations[3], *cur, *endMoves, *endBadCaptures;
int stage;
Move move;
Square recaptureSquare;
Value threshold;
Depth depth;
ExtMove moves[MAX_MOVES];
@@ -1330,8 +1330,7 @@ namespace {
// be generated.
MovePicker mp(pos, ttMove, depth, &thisThread->mainHistory,
&thisThread->captureHistory,
contHist,
to_sq((ss-1)->currentMove));
contHist);

// Loop through the moves until no moves remain or a beta cutoff occurs
while ((move = mp.next_move()) != MOVE_NONE)
@@ -209,7 +209,6 @@ enum Depth : int {
DEPTH_ZERO = 0 * ONE_PLY,
DEPTH_QS_CHECKS = 0 * ONE_PLY,
DEPTH_QS_NO_CHECKS = -1 * ONE_PLY,
DEPTH_QS_RECAPTURES = -5 * ONE_PLY,

DEPTH_NONE = -6 * ONE_PLY,
DEPTH_MAX = MAX_PLY * ONE_PLY

1 comment on commit 6cc68b5

@DU-jdto

This comment has been minimized.

Copy link
Owner

DU-jdto commented on 6cc68b5 Jan 10, 2019

I'm not sure why this (the LTC test) was set to priority -1, and the change appears to have been from before the STC passed. As such, I've set it back to 0. If there was a reason I'm not aware of for it still to have been at -1, feel free to set it back to that.

Please sign in to comment.
You can’t perform that action at this time.