Skip to content

Commit ebdef74

Browse files
committed
Fixed a bug in singular extensions and updated move sorting.
1 parent b046be7 commit ebdef74

File tree

4 files changed

+7
-4
lines changed

4 files changed

+7
-4
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,5 @@
11
.idea/
2+
.vscode/
23
cmake-build-debug/
4+
cmake-build-release/
5+
build/

movesort.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ move_t movesort_t::next(GenStage &stage, int &score, bool skip_quiets) {
8686
} else {
8787
main_scores[i] = heur.history.get(main_buf[i]);
8888
if (refutation.info.is_capture && main_buf[i].info.from == refutation.info.to) {
89-
main_scores[i] += 100;
89+
main_scores[i] += 800;
9090
}
9191
}
9292
}

movesort.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,15 +24,15 @@ class history_heur_t {
2424
public:
2525
void update(move_t move, int bonus) {
2626
table[move.info.team][move.info.from][move.info.to] +=
27-
bonus - table[move.info.team][move.info.from][move.info.to] * abs(bonus) / 2048;
27+
bonus - table[move.info.team][move.info.from][move.info.to] * abs(bonus) / 16384;
2828
}
2929

3030
int get(move_t move) const {
3131
return table[move.info.team][move.info.from][move.info.to];
3232
}
3333
private:
3434
// Indexed by [TEAM][FROM][TO]
35-
int table[2][64][64] = {};
35+
int16_t table[2][64][64] = {};
3636
};
3737

3838
// Killer heuristic

pvs.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ namespace pvs {
260260
&& (h_bound == tt::LOWER || h_bound == tt::EXACT)
261261
&& h.depth() >= depth - 2) {
262262
int reduced_beta = (h.value(ply)) - depth;
263-
score = search_zw(reduced_beta, ply, depth / 2, aborted);
263+
score = search_zw(reduced_beta, ply, depth / 2, aborted, move);
264264
if (aborted) return TIMEOUT;
265265

266266
if (score < reduced_beta) {

0 commit comments

Comments
 (0)