FauziAkram
504bf0e8b8
Change depth - 1 to newDepth
...
Replacing 'depth - 1' with 'newDepth' in the singularbeta formula
utilizes existing variables more succinctly.
closes https://github.com/official-stockfish/Stockfish/pull/4876
No functional change
2023-11-20 18:59:01 +01:00
Stefan Geschwentner
7970236e9e
Fix undefined behavior in search.
...
We use following line to clamp the search depth in some range:
Depth d = std::clamp(newDepth - r, 1, newDepth + 1);
Through negative extension its possible that the maximum value becomes smaller than the minimum value but then the behavior is undefined (see https://en.cppreference.com/w/cpp/algorithm/clamp ). So replace this line with a safe implementation.
Remark:
We have in recent master already one line where up to 3 negative extensions are possible which could trigger this undefined behavior but this can only be happen for completed depth > 24 so its not discovered by our default bench. Recent negative extension tests by @fauzi shows then this undefined behavior with wrong bench numbers.
closes https://github.com/official-stockfish/Stockfish/pull/4877
No functional change
2023-11-16 09:10:20 +01:00
Joost VandeVondele
f9d8717844
Symmetrize optimism
...
Removes some additional parameters, making the term more logical at the same
time.
Passed STC:
https://tests.stockfishchess.org/tests/view/6550e896136acbc5735328ed
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 271104 W: 68441 L: 68480 D: 134183
Ptnml(0-2): 827, 32590, 68816, 32433, 886
Passed LTC:
https://tests.stockfishchess.org/tests/view/65523858136acbc5735344f7
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 198954 W: 49250 L: 49211 D: 100493
Ptnml(0-2): 93, 22565, 54117, 22614, 88
closes https://github.com/official-stockfish/Stockfish/pull/4874
Bench: 1334248
2023-11-15 19:35:14 +01:00
Taras Vuk
863a1f2b4c
Introduce recapture extensions
...
When in a PV-node this patch extends ttMove if it is a recapture and has a good
history.
Passed STC:
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 83840 W: 21560 L: 21166 D: 41114
Ptnml(0-2): 343, 9905, 21027, 10305, 340
https://tests.stockfishchess.org/tests/view/654f4b02136acbc5735308ab
Passed LTC:
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 165318 W: 41068 L: 40476 D: 83774
Ptnml(0-2): 98, 18670, 44517, 19290, 84
https://tests.stockfishchess.org/tests/view/654fde04136acbc5735314e0
closes https://github.com/official-stockfish/Stockfish/pull/4872
Bench: 1393911
2023-11-15 19:32:59 +01:00
Linmiao Xu
fbc6b27505
Simplify away optimism average score offset params
...
Passed non-regression STC:
https://tests.stockfishchess.org/tests/view/654abf6b136acbc57352ac4b
LLR: 2.97 (-2.94,2.94) <-1.75,0.25>
Total: 49664 W: 12687 L: 12477 D: 24500
Ptnml(0-2): 138, 5840, 12703, 5976, 175
Passed non-regression LTC:
https://tests.stockfishchess.org/tests/view/654b638e136acbc57352b961
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 347166 W: 85561 L: 85676 D: 175929
Ptnml(0-2): 206, 39569, 94150, 39450, 208
closes https://github.com/official-stockfish/Stockfish/pull/4871
bench 1257641
2023-11-11 15:26:56 +01:00
Taras Vuk
d0e87104aa
Remove pawn history from ProbCut constructor
...
use same style as other history tables
Passed STC:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 184672 W: 46953 L: 46896 D: 90823
Ptnml(0-2): 604, 21095, 48887, 21140, 610
https://tests.stockfishchess.org/tests/view/654766b4136acbc573526602
closes https://github.com/official-stockfish/Stockfish/pull/4865
No functional change
2023-11-07 08:23:11 +01:00
Taras Vuk
442c294a07
Use stat_malus when decreasing stats
...
This patch applies stat_bonus when increasing and stat_malus when decreasing stats.
Passed STC:
LLR: 2.93 (-2.94,2.94) <0.00,2.00>
Total: 133792 W: 34221 L: 33758 D: 65813
Ptnml(0-2): 477, 15764, 33959, 16211, 485
https://tests.stockfishchess.org/tests/view/654699f3136acbc5735256b2
Passed LTC:
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 67374 W: 16912 L: 16523 D: 33939
Ptnml(0-2): 42, 7528, 18171, 7891, 55
https://tests.stockfishchess.org/tests/view/65474558136acbc5735263ab
closes https://github.com/official-stockfish/Stockfish/pull/4864
bench: 1114417
2023-11-05 19:54:59 +01:00
FauziAkram
d4b46ea6db
Set reduction to 0 if the move is a TT move
...
The reduction formula currently decreases by 1 if the move is a TT move.
This changes this by just setting the reduction to 0 instead.
Passed STC:
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 83136 W: 21145 L: 20758 D: 41233
Ptnml(0-2): 279, 9772, 21090, 10137, 290
https://tests.stockfishchess.org/tests/view/653c0fbacc309ae839561584
Passed LTC:
LLR: 2.96 (-2.94,2.94) <0.50,2.50>
Total: 273150 W: 67987 L: 67171 D: 137992
Ptnml(0-2): 155, 30730, 73966, 31592, 132
https://tests.stockfishchess.org/tests/view/653d9d02cc309ae839562fdf
closes https://github.com/official-stockfish/Stockfish/pull/4863
bench: 1110556
2023-11-05 19:53:15 +01:00
Shahin M. Shahin
791419aab5
Enhance some comments
...
This documents some code and makes some hard code easier to understand for new developers.
closes https://github.com/official-stockfish/Stockfish/pull/4862
No functional change
2023-11-05 19:51:02 +01:00
FauziAkram
7f97ba775e
Tweaking the futility pruning formula
...
Huge credit goes also to candirufish,
as the idea was first tried by him, and then tuned by me at multiple phases.
Tweaking the futility pruning formula to be a bit more selective about when pruning is applied.
Adjust the value added to the static eval based on the bestValue relative to ss->staticEval. If bestValue is significantly lower, we add a larger value.
Passed STC:
LLR: 2.98 (-2.94,2.94) <0.00,2.00>
Total: 37120 W: 9590 L: 9266 D: 18264
Ptnml(0-2): 130, 4301, 9385, 4603, 141
https://tests.stockfishchess.org/tests/view/6544cf90136acbc573523247
Passed LTC:
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 49632 W: 12381 L: 12033 D: 25218
Ptnml(0-2): 30, 5429, 13549, 5779, 29
https://tests.stockfishchess.org/tests/view/65453bc1136acbc573523a3c
closes https://github.com/official-stockfish/Stockfish/pull/4861
bench: 1107118
2023-11-04 17:34:35 +01:00
Michael Chaly
b4b704e686
Update pawn history based on static eval difference
...
Use the same logic as in main history but with 1/4 multiplier.
Passed STC:
https://tests.stockfishchess.org/tests/view/653c1282cc309ae8395615bf
LLR: 2.93 (-2.94,2.94) <0.00,2.00>
Total: 306624 W: 77811 L: 77094 D: 151719
Ptnml(0-2): 975, 36411, 77830, 37114, 982
Passed LTC:
https://tests.stockfishchess.org/tests/view/654258e2cc309ae83956818d
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 99150 W: 24681 L: 24228 D: 50241
Ptnml(0-2): 56, 11107, 26792, 11568, 52
closes https://github.com/official-stockfish/Stockfish/pull/4859
bench 1330590
2023-11-03 22:50:05 +01:00
Stefan Geschwentner
1cb9afbdc0
Remove razoring history update.
...
The recently commit 'Rewarding Quiet Moves that Enable Razoring' add a history update if razoring. But its contains also many tuned values all over the search. Following tests shows that the tuned values and not the added history update is responsible for the elo gain. So remove later.
Passed STC:
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 29376 W: 7641 L: 7410 D: 14325
Ptnml(0-2): 100, 3411, 7451, 3610, 116
https://tests.stockfishchess.org/tests/view/653c9fe1cc309ae839562070
Passed LTC:
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 242922 W: 59879 L: 59885 D: 123158
Ptnml(0-2): 129, 27764, 65688, 27744, 136
https://tests.stockfishchess.org/tests/view/653d06cbcc309ae839562735
closes https://github.com/official-stockfish/Stockfish/pull/4858
Bench: 1286104
2023-11-03 22:47:31 +01:00
FauziAkram
101d2bb8ea
Simplifying two formulas
...
by eliminating two multiplication operations.
Passed STC:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 60000 W: 15193 L: 14996 D: 29811
Ptnml(0-2): 199, 7100, 15215, 7277, 209
https://tests.stockfishchess.org/tests/view/653beb69cc309ae83956129d
Passed LTC:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 122910 W: 30471 L: 30353 D: 62086
Ptnml(0-2): 68, 13961, 33271, 14095, 60
https://tests.stockfishchess.org/tests/view/653c5848cc309ae839561ae7
closes https://github.com/official-stockfish/Stockfish/pull/4857
bench: 1216779
2023-11-03 22:40:43 +01:00
cj5716
e277dda716
Prefetch TT entries in probcut
...
Passed STC:
LLR: 2.93 (-2.94,2.94) <0.00,2.00>
Total: 101344 W: 25893 L: 25491 D: 49960
Ptnml(0-2): 303, 11350, 26991, 11698, 330
https://tests.stockfishchess.org/tests/view/6540daa6cc309ae83956669b
slight speedup:
```
Result of 100 runs
==================
base (./stockfish.master ) = 1170705 +/- 3133
test (./stockfish.patch ) = 1174545 +/- 2895
diff = +3841 +/- 3196
speedup = +0.0033
P(speedup > 0) = 0.9907
```
closes https://github.com/official-stockfish/Stockfish/pull/4856
No functional change
2023-11-03 22:39:04 +01:00
Muzhen Gaming
908811c24a
Introduce asymmetric optimism
...
Introduce asymmetric optimism for both side to move and opponent. Parameter tuning was done with 200k LTC games.
STC: https://tests.stockfishchess.org/tests/view/653cc08fcc309ae8395622b3
LLR: 2.96 (-2.94,2.94) <0.00,2.00>
Total: 98336 W: 25074 L: 24661 D: 48601
Ptnml(0-2): 339, 11612, 24890, 11951, 376
LTC: https://tests.stockfishchess.org/tests/view/653db595cc309ae839563140
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 83244 W: 20760 L: 20339 D: 42145
Ptnml(0-2): 51, 9306, 22498, 9705, 62
closes https://github.com/official-stockfish/Stockfish/pull/4853
Bench: 1371690
2023-10-30 07:51:27 +01:00
cj5716
38aa70adcf
Small cleanups
...
Corrects some incorrect or outdated comments.
Credit is shared with yaneurao (see 38e830a#commitcomment-131131500) and locutus2
closes #4852
No functional change.
2023-10-30 07:49:15 +01:00
Disservin
08ed4c90db
Format Code
...
No functional change
2023-10-27 17:33:59 +02:00
FauziAkram
d30af4f669
Rewarding Quiet Moves that Enable Razoring
...
The main idea of the patch comes from @peregrineshahin :
https://tests.stockfishchess.org/tests/view/65205363ac57711436728781
Another small idea (tuning) comes from @Vizvezdenec
https://tests.stockfishchess.org/tests/view/652e071ade6d262d08d318f4 And a long
phases of tuning and tests was done by me in order to make the patch be able to
pass both tests.
The idea, as mentioned by Peregrine is that in our standard code, if no best
move found after searching all moves, we give a bonus to the previous move that
caused the fail high. So in razoring we assume no bestmove will be found so we
might as well do the same.
Passed STC:
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 82336 W: 20997 L: 20610 D: 40729
Ptnml(0-2): 288, 9710, 20753, 10161, 256
https://tests.stockfishchess.org/tests/view/6538fafbcc309ae83955d8f0
Passed LTC:
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 46584 W: 11753 L: 11411 D: 23420
Ptnml(0-2): 21, 5133, 12642, 5475, 21
https://tests.stockfishchess.org/tests/view/653a3f2ccc309ae83955f223
closes https://github.com/official-stockfish/Stockfish/pull/4850
Bench: 1258079
Co-Authored-By: Shahin M. Shahin <41402573+peregrineshahin@users.noreply.github.com>
2023-10-27 17:32:19 +02:00
Michael Chaly
b0658f09b9
Introduce pawn structure based history
...
Original idea by Seer chess engine https://github.com/connormcmonigle/seer-nnue ,
coding done by @Disservin, code refactoring done by @locutus2 to match the style
of other histories.
This patch introduces pawn structure based history, which assings moves values
based on last digits of pawn structure hash and piece type of moved piece and
landing square of the move. Idea is that good places for pieces are quite often
determined by pawn structure of position. Used in 3 different places
- sorting of quiet moves, sorting of quiet check evasions and in history based
pruning in search.
Passed STC:
https://tests.stockfishchess.org/tests/view/65391d08cc309ae83955dbaf
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 155488 W: 39408 L: 38913 D: 77167
Ptnml(0-2): 500, 18427, 39408, 18896, 513
Passed LTC:
https://tests.stockfishchess.org/tests/view/653a36a2cc309ae83955f181
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 70110 W: 17548 L: 17155 D: 35407
Ptnml(0-2): 33, 7859, 18889, 8230, 44
closes https://github.com/official-stockfish/Stockfish/pull/4849
Bench: 1257882
Co-Authored-By: Disservin <disservin.social@gmail.com>
Co-Authored-By: Stefan Geschwentner <locutus2@users.noreply.github.com>
2023-10-27 17:24:25 +02:00
Taras Vuk
871ab55f01
Simplify futility pruning formula
...
closes https://github.com/official-stockfish/Stockfish/pull/4848
No functional change
2023-10-27 17:16:28 +02:00
Linmiao Xu
0024133b08
Update 5 search params for pruning at shallow depth
...
Found by spsa tuning at 45+0.45 with:
```
int fpcEvalOffset = 188;
int fpcLmrDepthMult = 206;
int histDepthMult = -3232;
int histDenom = 5793;
int fpEvalOffset = 115;
int negSeeDepthMultSq = -27;
TUNE(SetRange(0, 394), fpcEvalOffset);
TUNE(SetRange(0, 412), fpcLmrDepthMult);
TUNE(SetRange(-6464, -1616), histDepthMult);
TUNE(SetRange(2896, 11586), histDenom);
TUNE(SetRange(0, 230), fpEvalOffset);
TUNE(SetRange(-54, 0), negSeeDepthMultSq);
```
Passed STC:
https://tests.stockfishchess.org/tests/view/6535551de746e058e6c0165d
LLR: 2.98 (-2.94,2.94) <0.00,2.00>
Total: 109056 W: 28025 L: 27599 D: 53432
Ptnml(0-2): 357, 12669, 28038, 13119, 345
Passed LTC:
https://tests.stockfishchess.org/tests/view/65364c6ff127f3553505175d
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 61290 W: 15316 L: 14941 D: 31033
Ptnml(0-2): 34, 6849, 16498, 7236, 28
closes https://github.com/official-stockfish/Stockfish/pull/4847
bench 1167412
2023-10-24 17:46:18 +02:00
Joost VandeVondele
ec02714b62
Cleanup comments and some code reorg.
...
passed STC:
https://tests.stockfishchess.org/tests/view/6536dc7dcc309ae83955b04d
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 58048 W: 14693 L: 14501 D: 28854
Ptnml(0-2): 200, 6399, 15595, 6669, 161
closes https://github.com/official-stockfish/Stockfish/pull/4846
No functional change
2023-10-24 17:43:05 +02:00
cj5716
d6a5c2b085
Small formatting improvements
...
Changes some C style casts to C++ style, and fixes some incorrect comments and variable names.
closes #4845
No functional change
2023-10-24 17:42:13 +02:00
Muzhen Gaming
cf3dbcb5ac
Time management improvements
...
1. Tune time management parameters.
2. Scale the optimum time and maximum time parameters based on the amount of
time left, using a logarithmic scale.
Many acknowledgements to @FauziAkram for tuning the parameters and for the
original idea (see
https://tests.stockfishchess.org/tests/view/652f0356de6d262d08d333c5 ).
STC: https://tests.stockfishchess.org/tests/view/6533938fde6d262d08d39e4d
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 44320 W: 11301 L: 10982 D: 22037
Ptnml(0-2): 146, 4810, 11920, 5147, 137
LTC: https://tests.stockfishchess.org/tests/view/653477e4de6d262d08d3ae06
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 146442 W: 37338 L: 36811 D: 72293
Ptnml(0-2): 60, 14975, 42645, 15460, 81
Verification runs:
3+0.03: https://tests.stockfishchess.org/tests/view/65364e7ef127f3553505178a
10+0: https://tests.stockfishchess.org/tests/view/65364e9ff127f3553505178f
180+1.8: https://tests.stockfishchess.org/tests/view/65364ec3f127f35535051794
closes https://github.com/official-stockfish/Stockfish/pull/4843
No functional change.
Co-Authored-By: FauziAkram <11150271+FauziAkram@users.noreply.github.com>
2023-10-23 20:39:48 +02:00
Disservin
a105978bbd
remove blank line between function and it's description
...
- remove the blank line between the declaration of the function and it's
comment, leads to better IDE support when hovering over a function to see it's
description
- remove the unnecessary duplication of the function name in the functions
description
- slightly refactored code for lsb, msb in bitboard.h There are still a few
things we can be improved later on, move the description of a function where
it was declared (instead of implemented) and add descriptions to functions
which are behind macros ifdefs
closes https://github.com/official-stockfish/Stockfish/pull/4840
No functional change
2023-10-23 20:39:48 +02:00
Taras Vuk
b7b7800e2b
Simplify futilityBase formula
...
This patch replaces std::min(ss->staticEval, bestValue) with ss->staticEval in the futilityBase formula.
Original idea by Vizvezdenec: https://tests.stockfishchess.org/tests/view/64ce66795b17f7c21c0d85f3
Passed STC:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 116928 W: 29925 L: 29793 D: 57210
Ptnml(0-2): 399, 13558, 30446, 13634, 427
https://tests.stockfishchess.org/tests/view/653285aade6d262d08d385dd
Passed LTC:
LLR: 2.96 (-2.94,2.94) <-1.75,0.25>
Total: 50868 W: 12947 L: 12757 D: 25164
Ptnml(0-2): 30, 5414, 14355, 5606, 29
https://tests.stockfishchess.org/tests/view/65336ffbde6d262d08d39ba0
closes https://github.com/official-stockfish/Stockfish/pull/4837
bench: 1241996
2023-10-22 16:16:02 +02:00
Disservin
2d0237db3f
add clang-format
...
This introduces clang-format to enforce a consistent code style for Stockfish.
Having a documented and consistent style across the code will make contributing easier
for new developers, and will make larger changes to the codebase easier to make.
To facilitate formatting, this PR includes a Makefile target (`make format`) to format the code,
this requires clang-format (version 17 currently) to be installed locally.
Installing clang-format is straightforward on most OS and distros
(e.g. with https://apt.llvm.org/ , brew install clang-format, etc), as this is part of quite commonly
used suite of tools and compilers (llvm / clang).
Additionally, a CI action is present that will verify if the code requires formatting,
and comment on the PR as needed. Initially, correct formatting is not required, it will be
done by maintainers as part of the merge or in later commits, but obviously this is encouraged.
fixes https://github.com/official-stockfish/Stockfish/issues/3608
closes https://github.com/official-stockfish/Stockfish/pull/4790
Co-Authored-By: Joost VandeVondele <Joost.VandeVondele@gmail.com>
2023-10-22 16:06:27 +02:00
Taras Vuk
e18619d078
Subtract the margin from the value returned by ProbCut
...
This patch subtracts the margin from the value returned by ProbCut.
Passed STC:
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 46112 W: 11940 L: 11610 D: 22562
Ptnml(0-2): 131, 5318, 11842, 5620, 145
https://tests.stockfishchess.org/tests/view/652ea42ade6d262d08d329dd
Passed LTC:
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 86880 W: 22192 L: 21776 D: 42912
Ptnml(0-2): 43, 9213, 24510, 9633, 41
https://tests.stockfishchess.org/tests/view/652f70ffde6d262d08d33e8d
closes https://github.com/official-stockfish/Stockfish/pull/4835
bench: 1135313
2023-10-21 10:34:12 +02:00
FauziAkram
90c18b0b50
Removing history condition
...
Removing the bad history condition from the skip futility pruning formula.
Passed STC:
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 142688 W: 36420 L: 36317 D: 69951
Ptnml(0-2): 481, 16653, 36970, 16762, 478
https://tests.stockfishchess.org/tests/view/65270a663125598fc7eb8c67
Passed LTC:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 435378 W: 110723 L: 110925 D: 213730
Ptnml(0-2): 278, 47251, 122788, 47139, 233
https://tests.stockfishchess.org/tests/view/6528595f3125598fc7eba8f5
closes https://github.com/official-stockfish/Stockfish/pull/4834
Bench: 1110579
2023-10-21 10:31:51 +02:00
Shahin M. Shahin
057046cc9a
Cleanup qsearch continuation histories
...
Only (ss-1) and (ss-2) are used in qsearch.
closes https://github.com/official-stockfish/Stockfish/pull/4828
No functional change
2023-10-21 10:26:09 +02:00
FauziAkram
edb4ab924f
Standardize Comments
...
use double slashes (//) only for comments.
closes #4820
No functional change.
2023-10-21 10:25:03 +02:00
Stéphane Nicolet
fe53a18f7a
Reformat some comments and conditions
...
closes https://github.com/official-stockfish/Stockfish/pull/4814
No functional change
2023-10-21 10:15:48 +02:00
Shahin M. Shahin
a4fedd8152
Fix greater than TB scores in null move pruning.
...
This patch is a simplification and a fix to dealing with null moves scores that returns proven mates or TB scores by preventing 'null move pruning' if the nullvalue is in that range.
Current solution downgrades nullValues on the non-PV node but the value can be used in a transposed PV-node to the same position afterwards (Triangulation), the later is prone to propagate a wrong score (96.05) to root that will not be refuted unless we search further.
Score of (96.05) can be obtained be two methods,
maxim static-eval returned on Pv update (mostly qSearch)
this downgrade (clamp) in NMP
and theoretically can happen with or without TBs but the second scenario is more dangerous than the first.
This fixes the reproducible case in very common scenarios with TBs as shown in the debugging at discord.
Fixes : #4699
Passed STC:
https://tests.stockfishchess.org/tests/view/64c1eca8dc56e1650abba6f9
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 670048 W: 171132 L: 171600 D: 327316
Ptnml(0-2): 2134, 75687, 179820, 75279, 2104
Passed LTC:
https://tests.stockfishchess.org/tests/view/64c5e130dc56e1650abc0438
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 92868 W: 23642 L: 23499 D: 45727
Ptnml(0-2): 52, 9509, 27171, 9648, 54
closes https://github.com/official-stockfish/Stockfish/pull/4715
Bench: 1327410
2023-10-21 10:01:26 +02:00
Michael Chaly
38e830af4b
Use more continuation histories.
...
This patch allows stats updates and movepicker bonuses for continuation history 3 plies deep - so counter counter move.
Updates and movepicker usage are done with 1/4 multiplier compared to other histories.
Passed STC:
https://tests.stockfishchess.org/tests/view/6528f28d3125598fc7ebb5a3
LLR: 2.96 (-2.94,2.94) <0.00,2.00>
Total: 161344 W: 41369 L: 40868 D: 79107
Ptnml(0-2): 535, 18720, 41679, 19185, 553
Passed LTC:
https://tests.stockfishchess.org/tests/view/652a397a3125598fc7ebd1d6
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 48564 W: 12556 L: 12215 D: 23793
Ptnml(0-2): 25, 5149, 13595, 5486, 27
closes https://github.com/official-stockfish/Stockfish/pull/4827
bench 1327410
2023-10-14 16:52:35 +02:00
Muzhen Gaming
002636362e
Search parameters tune at 180+1.8
...
Passed VLTC: https://tests.stockfishchess.org/tests/view/65200c58ac577114367280bc
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 146180 W: 37407 L: 36988 D: 71785
Ptnml(0-2): 21, 14474, 43675, 14905, 15
Passed VLTC SMP: https://tests.stockfishchess.org/tests/view/652403da3125598fc7eb4b6d
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 57580 W: 15061 L: 14739 D: 27780
Ptnml(0-2): 2, 5001, 18460, 5327, 0
closes https://github.com/official-stockfish/Stockfish/pull/4826
Bench: 1099336
2023-10-10 17:45:32 +02:00
Taras Vuk
7a4de96159
Skip futility pruning if ttMove has bad history
...
Passed STC:
LLR: 2.96 (-2.94,2.94) <0.00,2.00>
Total: 52416 W: 13465 L: 13128 D: 25823
Ptnml(0-2): 128, 6024, 13604, 6287, 165
https://tests.stockfishchess.org/tests/view/651fadd4ac577114367277bf
Passed LTC:
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 87348 W: 22234 L: 21818 D: 43296
Ptnml(0-2): 38, 9240, 24698, 9664, 34
https://tests.stockfishchess.org/tests/view/65201932ac57711436728218
closes https://github.com/official-stockfish/Stockfish/pull/4825
bench: 1246560
2023-10-08 07:56:07 +02:00
gabe
f7fbc6880e
Avoid recomputing moveCountPruning
...
In search, when moveCountPruning becomes true, it can never turn false again.
Passed STC https://tests.stockfishchess.org/tests/view/652075ceac57711436728aac
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 136448 W: 34923 L: 34472 D: 67053
Ptnml(0-2): 420, 15094, 36767, 15501, 442
closes https://github.com/official-stockfish/Stockfish/pull/4823
Non functional change
2023-10-08 07:52:16 +02:00
candirufish
25d444ed60
Razor more if ss+1 cutoffCnt > 3
...
STC:
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 221760 W: 56726 L: 56144 D: 108890
Ptnml(0-2): 655, 25453, 58123, 25953, 696
https://tests.stockfishchess.org/tests/view/651d34dbcff46e538ee05d91
LTC:
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 130326 W: 33188 L: 32681 D: 64457
Ptnml(0-2): 69, 13949, 36620, 14456, 69
https://tests.stockfishchess.org/tests/view/651f844eac577114367273d5
closes https://github.com/official-stockfish/Stockfish/pull/4822
bench: 1291708
2023-10-08 07:50:03 +02:00
Stefan Geschwentner
008d59512a
Simplify collection of bad moves for history updates.
...
1. collect only the first 32 moves searched and ignore the rest. So late bad moves get no further negative history updates.
2. collect now for quiet moves also at most 32 bad moves
STC:
https://tests.stockfishchess.org/tests/view/6517b3aeb3e74811c8af5651
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 51168 W: 13013 L: 12810 D: 25345
Ptnml(0-2): 120, 6006, 13186, 6095, 177
LTC:
https://tests.stockfishchess.org/tests/view/651adafecff46e538ee02734
LLR: 2.96 (-2.94,2.94) <-1.75,0.25>
Total: 109866 W: 27786 L: 27656 D: 54424
Ptnml(0-2): 52, 11816, 31069, 11942, 54
closes https://github.com/official-stockfish/Stockfish/pull/4818
Bench: 1338617
2023-10-08 07:46:26 +02:00
Stéphane Nicolet
040dfedb34
Remove one test in the move loop
...
Simplification passed STC test:
https://tests.stockfishchess.org/tests/view/6519fc91cff46e538ee014f6
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 191264 W: 48550 L: 48501 D: 94213
Ptnml(0-2): 576, 21529, 51392, 21540, 595
closes #4815
Non functional change
2023-10-08 07:41:16 +02:00
cj5716
660da1ca7b
Skip moves-loop pruning in qsearch if we have only pawns
...
At first my idea was only to cover movecount and futility pruning, but
@peregrineshahin suggested to test it on all moves-loop pruning and it worked.
Passed STC:
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 167968 W: 42970 L: 42480 D: 82518
Ptnml(0-2): 444, 18324, 46002, 18726, 488
https://tests.stockfishchess.org/tests/view/6511181a55b420c569d0d54c
Passed LTC:
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 40794 W: 10496 L: 10182 D: 20116
Ptnml(0-2): 12, 4021, 12025, 4319, 20
https://tests.stockfishchess.org/tests/view/6512ccc4b3e74811c8aee86c
closes https://github.com/official-stockfish/Stockfish/pull/4809
Bench: 1338472
2023-09-29 22:28:34 +02:00
FauziAkram
243f7b264a
Improve grammar of comments
...
closes https://github.com/official-stockfish/Stockfish/pull/4801
No functional change
2023-09-29 22:18:17 +02:00
Stefan Geschwentner
154b8d3ecb
Remove VALUE_KNOWN_WIN.
...
After removing classic evaluation VALUE_KNOWN_WIN is not anymore returned explicit evaluation. So remove and replace it with VALUE_TB_WIN_IN_MAX_PLY.
Measurement on my big bench (bench 16 1 16 pos1000.fen) verifies that at least with current net the calculated evaluation lies always in the open interval (-VALUE_KNOWN_WIN, VALUE_KNOWN_WIN).
So i consider this a non-functional change. But to be safe i tested this also at LTC as requested by Stephane Nicolet.
STC:
https://tests.stockfishchess.org/tests/view/64f9db40eaf01be8259a6ed5
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 455296 W: 115981 L: 116217 D: 223098
Ptnml(0-2): 1415, 50835, 123420, 50527, 1451
LTC:
https://tests.stockfishchess.org/tests/view/650bfd867ca0d3f7bbf25feb
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 35826 W: 9170 L: 8973 D: 17683
Ptnml(0-2): 12, 3523, 10645, 3722, 11
closes https://github.com/official-stockfish/Stockfish/pull/4792
Bench: 1603079
2023-09-22 19:25:57 +02:00
cj5716
fce4cc1829
Make casting styles consistent
...
Make casting styles consistent with the rest of the code.
closes https://github.com/official-stockfish/Stockfish/pull/4793
No functional change
2023-09-22 19:14:29 +02:00
peregrineshahin
0e32287af4
Reorder some lines
...
Now that qsearch has its own repetition detection we can flip the order of lines and remove the guard of depth < 0 which is not needed after reordering (i.e. it was there to prevent checking repetition again at depth ==0).
Passed STC:
https://tests.stockfishchess.org/tests/view/6502ecbb2cd016da89abc3fb
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 69536 W: 17668 L: 17490 D: 34378
Ptnml(0-2): 190, 7652, 18929, 7784, 213
Passed LTC:
https://tests.stockfishchess.org/tests/view/6505ce9072620bc881ea9086
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 52116 W: 13294 L: 13113 D: 25709
Ptnml(0-2): 26, 5176, 15471, 5361, 24
closes https://github.com/official-stockfish/Stockfish/pull/4791
No functional change
2023-09-22 19:02:18 +02:00
Stéphane Nicolet
3f7fb5ac1d
Reformat some comments
...
Also include the bench to make Continuation Integration happy on Github.
Bench: 1603079
2023-09-11 23:19:06 +02:00
Michael Chaly
ef22829616
Do more futility pruning in qsearch
...
This patch introduces a third futility pruning heuristic in qsearch. The idea is
that the static exchange evaluation is much worse than the difference between
futility base and alpha. Thus we can assume that the probability of the move
being good enough to beat alpha is low so it can be pruned.
Passed STC:
https://tests.stockfishchess.org/tests/view/64fc982a5dab775b5359dc83
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 36576 W: 9484 L: 9170 D: 17922
Ptnml(0-2): 121, 4119, 9495, 4431, 122
Passed LTC:
https://tests.stockfishchess.org/tests/view/64fcc7935dab775b5359e1a9
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 135408 W: 34556 L: 34041 D: 66811
Ptnml(0-2): 56, 14462, 38165, 14953, 68
closes https://github.com/official-stockfish/Stockfish/pull/4781
Bench: 1330793
2023-09-11 22:36:26 +02:00
cj5716
6d85f43e26
Simplify cutnode depth condition
...
With this patch, the depth condition for the cutnodes reduction is loosened from
tte->depth() >= depth + 3 to just tte->depth() >= depth.
Passed STC:
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 101152 W: 25830 L: 25682 D: 49640
Ptnml(0-2): 312, 11788, 26258, 11876, 342
https://tests.stockfishchess.org/tests/view/64fd15635dab775b5359eaa6
Passed LTC:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 82542 W: 20980 L: 20824 D: 40738
Ptnml(0-2): 42, 8795, 23440, 8953, 41
https://tests.stockfishchess.org/tests/view/64fda3545dab775b5359fbf1
closes https://github.com/official-stockfish/Stockfish/pull/4780
Bench: 1479029
2023-09-11 22:30:57 +02:00
FauziAkram
adf29b3fd6
Rename one variable
...
To enhance code clarity and prevent potential confusion with the
'r' variable assigned to reduction later in the code, this pull
request renames it to 'reductionScale' when we use the same name
in the reduction() function.
Using distinct variable names for separate functions improves code
readability and maintainability.
closes https://github.com/official-stockfish/Stockfish/pull/4765
No functional change
2023-09-03 09:10:27 +02:00
Disservin
3c0e86a91e
Cleanup includes
...
Reorder a few includes, include "position.h" where it was previously missing
and apply include-what-you-use suggestions. Also make the order of the includes
consistent, in the following way:
1. Related header (for .cpp files)
2. A blank line
3. C/C++ headers
4. A blank line
5. All other header files
closes https://github.com/official-stockfish/Stockfish/pull/4763
fixes https://github.com/official-stockfish/Stockfish/issues/4707
No functional change
2023-09-03 08:24:51 +02:00