Commit Graph

6585 Commits

Author SHA1 Message Date
Disservin
0475c8653f Restore development
closes https://github.com/official-stockfish/Stockfish/pull/5956

No functional change
2025-04-02 17:23:32 +02:00
Joost VandeVondele
03e27488f3 Stockfish 17.1
Official release version of Stockfish 17.1

Bench: 2030154

---

Stockfish 17.1

Today, we have the pleasure to announce Stockfish 17.1. As always, you can
**freely** download it at [stockfishchess.org/download][1] and use it in the
[GUI of your choice][2].

Join our [Discord server][3] to get in touch with the community of developers
and users of the project!

Quality of chess play

In our testing against its predecessor, Stockfish 17.1 shows a consistent
improvement in performance, with an [Elo gain of up to 20 points][4] and
winning close to 2 times more game pairs than it loses.

Update highlights

New speedtest command

The new `speedtest` command benchmarks your computer's performance (measured in
nodes per second) using a realistic and stable test. To run it, you'll need
[command line access][5]—give it a try and share your results with the
community!

Improved hardware support

Stockfish is [no longer limited to 1024 threads][6] and will allow users to
specify whatever their system is capable of. Additionally, hardware such as
ppc64 and Loongson is now better supported at build time.

Bug fixes for tablebase support

Our previous release introduced improved engine lines (principal variations)
ending in mate as soon as a mate score is announced. A side effect of this
improvement was a [rare corner case][7] involving cursed tablebase wins, only
relevant in correspondence chess when the 50-move rule does not apply,  which
has now been fixed. Relatedly, [time management][8] has also been improved to
avoid potential time losses.

Shoutouts

Download page redesign

We've redesigned the [download page][1] to address unclear wording and simplify
a previously cluttered experience. The page now features a modernized layout,
streamlined navigation, and clearer guidance to help you select the right
binary for your system.

Fishtest framework

Our testing framework has been improved in various ways, both on the worker
side, including the adoption of [Fastchess][9] as a new game manager, and on
the server side, such as streamlined configuration. The reliable availability
of testing resources is key for the progress of the engine.

Thank you

The Stockfish project builds on a thriving community of enthusiasts (thanks
everybody!) who contribute their expertise, time, and resources to build a free
and open-source chess engine that is robust, widely available, and very strong.

We would like to express our gratitude for the [12k stars][10] that light up
our GitHub project! Thank you for your support and encouragement – your
recognition means a lot to us.

We invite our chess fans to [join the Fishtest testing framework][11] to
contribute compute resources needed for development. Programmers can contribute
to the project either directly to [Stockfish][12] (C++), to [Fishtest][13]
(HTML, CSS, JavaScript, and Python), to our trainer [nnue-pytorch][14] (C++ and
Python), or to our [website][15] (HTML, CSS/SCSS, and JavaScript).

The Stockfish team

[1]: https://stockfishchess.org/download
[2]: https://official-stockfish.github.io/docs/stockfish-wiki/Download-and-usage.html#download-a-chess-gui
[3]: https://discord.gg/GWDRS3kU6R
[4]: https://tests.stockfishchess.org/tests/view/67e7d2fd6682f97da2178fbd
[5]: https://official-stockfish.github.io/docs/stockfish-wiki/UCI-&-Commands.html#speedtest
[6]: 652a8874b5
[7]: 6c7c5c7e47
[8]: 0f9ae0d11c
[9]: https://github.com/Disservin/fastchess
[10]: https://github.com/official-stockfish/Stockfish/stargazers
[11]: https://official-stockfish.github.io/docs/fishtest-wiki/Running-the-Worker.html
[12]: https://github.com/official-stockfish/Stockfish
[13]: https://github.com/official-stockfish/fishtest
[14]: https://github.com/official-stockfish/nnue-pytorch
[15]: https://github.com/official-stockfish/stockfish-web
sf_17.1 stockfish-dev-20250330-03e27488
2025-03-30 13:44:15 +02:00
Disservin
aafc732bcb Silence "may be used uninitialized" GCC warning
Helps gcc silence the warning about

```
warning: 'added' may be used uninitialized [-Wmaybe-uninitialized]
const IndexType offsetA0 = TransformedFeatureDimensions * added[0];
```

closes https://github.com/official-stockfish/Stockfish/pull/5950

No functional change
2025-03-29 11:55:55 +01:00
Robert Nurnberg @ elitebook
4a869f41c6 Update the WDL model
This PR updates the internal WDL model, using data from 2.6M games
played by the revisions since f3bfce3531.
Note that the normalizing constant increases only moderately from 372 to
377.

```
> ./updateWDL.sh --firstrev f3bfce3531
Running: ./updateWDL.sh --firstrev f3bfce3531 --lasttrev HEAD --materialMin 17 --EloDiffMax 5
started at:  Sat 22 Mar 11:02:14 CET 2025
Look recursively in directory pgns for games with max nElo difference 5 using books matching "UHO_Lichess_4852_v..epd" for SF revisions between f3bfce3531 (from 2025-02-28 09:50:59 +0100) and HEAD (from 2025-03-21 11:22:59 +0100).
Based on 138253430 positions from 2579360 games, NormalizeToPawnValue should change from 372 to 377.
ended at:  Sat 22 Mar 11:04:00 CET 2025
```

```
> cat scoreWDL.log
Converting evals with NormalizeData = {'momType': 'material', 'momMin': 17, 'momMax': 78, 'momTarget': 58, 'as': [-37.45051876, 121.19101539, -132.78783573, 420.70576692]}.
Reading eval stats from updateWDL.json.
Retained (W,D,L) = (33794348, 69943262, 34515820) positions.
Saved distribution plot to updateWDLdistro.png.
Fit WDL model based on material.
Initial objective function:  0.3648260131692729
Final objective function:    0.36482338611818094
Optimization terminated successfully.
const int NormalizeToPawnValue = 377;
Corresponding spread = 71;
Corresponding normalized spread = 0.1879431202530567;
Draw rate at 0.0 eval at material 58 = 0.9902694872976331;
Parameters in internal value units:
p_a = ((-13.500 * x / 58 + 40.928) * x / 58 + -36.828) * x / 58 + 386.830
p_b = ((96.534 * x / 58 + -165.791) * x / 58 + 90.897) * x / 58 + 49.296
    constexpr double as[] = {-13.50030198, 40.92780883, -36.82753545, 386.83004070};
    constexpr double bs[] = {96.53354896, -165.79058388, 90.89679019, 49.29561889};
Preparing plots.
Saved graphics to updateWDL.png.
Total elapsed time = 46.92s.
```

Only affects displayed `cp` and `wdl` values.

closes https://github.com/official-stockfish/Stockfish/pull/5939

No functional change
2025-03-29 11:54:32 +01:00
Michel Van den Bergh
6028264cb9 Delay check for curl/wget until really needed
closes https://github.com/official-stockfish/Stockfish/pull/5938

No functional change
2025-03-29 11:53:53 +01:00
Joost VandeVondele
12d023ed06 Update CPU contributors
closes https://github.com/official-stockfish/Stockfish/pull/5937

No functional change
2025-03-29 11:52:50 +01:00
mstembera
6ceaca4c7b Change layout of CorrectionHistory<NonPawn>
https://tests.stockfishchess.org/tests/view/67da5b158c7f315cc372a9d2
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 150368 W: 38874 L: 38401 D: 73093
Ptnml(0-2): 424, 16821, 40262, 17212, 465

Make CorrectionHistory\<NonPawn\> handle both black and white
internally. A follow up to
https://github.com/official-stockfish/Stockfish/pull/5816

closes https://github.com/official-stockfish/Stockfish/pull/5934

No functional change
2025-03-21 11:22:59 +01:00
FauziAkram
0dabf4f3fa Removing the conditional bonus calculation
The new value is just a guessed value.

Passed STC:
https://tests.stockfishchess.org/tests/view/67d5ee09517865b4a2dfd2df
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 52128 W: 13516 L: 13312 D: 25300
Ptnml(0-2): 157, 6044, 13451, 6262, 150

Passed LTC:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 42384 W: 10855 L: 10657 D: 20872
Ptnml(0-2): 19, 4554, 11852, 4744, 23
https://tests.stockfishchess.org/tests/view/67d5f9d3517865b4a2dfd2ef

closes https://github.com/official-stockfish/Stockfish/pull/5933

Bench: 2030154
2025-03-21 11:22:25 +01:00
Nonlinear2
43d8ccf856 change the bonusScale depth component
Passed STC:
https://tests.stockfishchess.org/tests/view/67d35f66517865b4a2dfc801
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 110816 W: 28875 L: 28449 D: 53492
Ptnml(0-2): 329, 13064, 28231, 13420, 364

Passed LTC:
https://tests.stockfishchess.org/tests/view/67d4bdf0517865b4a2dfd131
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 121824 W: 31047 L: 30559 D: 60218
Ptnml(0-2): 52, 13056, 34214, 13532, 58

closes https://github.com/official-stockfish/Stockfish/pull/5932

Bench: 2128807
2025-03-21 11:21:10 +01:00
Shawn Xu
9045f17c3f Simplify captures PCM
Passed Non-regression STC:
LLR: 2.92 (-2.94,2.94) <-1.75,0.25>
Total: 229856 W: 59258 L: 59252 D: 111346
Ptnml(0-2): 746, 27330, 58714, 27448, 690
https://tests.stockfishchess.org/tests/view/67d3fdac517865b4a2dfcef4

Passed Non-regression LTC:
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 107652 W: 27470 L: 27338 D: 52844
Ptnml(0-2): 56, 11646, 30280, 11798, 46
https://tests.stockfishchess.org/tests/view/67d5f972517865b4a2dfd2ec

closes https://github.com/official-stockfish/Stockfish/pull/5931

Bench: 1842520
2025-03-21 11:19:45 +01:00
Michael Chaly
8fc5e92005 Use slightly different formula for stat score when position is in check
Use formula that is closer to movepicker one.

Passed STC:
https://tests.stockfishchess.org/tests/view/67cffb337be98c1ad9b021ee
LLR: 2.99 (-2.94,2.94) <0.00,2.00>
Total: 250432 W: 64978 L: 64343 D: 121111
Ptnml(0-2): 795, 29390, 64159, 30129, 743

Passed LTC:
https://tests.stockfishchess.org/tests/view/67d3905d517865b4a2dfce8a
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 140004 W: 35742 L: 35215 D: 69047
Ptnml(0-2): 60, 15111, 39151, 15602, 78

closes https://github.com/official-stockfish/Stockfish/pull/5930

Bench: 2147336
2025-03-21 11:19:09 +01:00
Robert Nurnberg @ elitebook
652a8874b5 Allow more than 1024 threads on high-end machines
closes https://github.com/official-stockfish/Stockfish/pull/5929

No functional change
2025-03-21 11:17:59 +01:00
FauziAkram
4afd7f1a7b Removing contHist[1] from pruning formula
Passed STC:
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 51552 W: 13297 L: 13091 D: 25164
Ptnml(0-2): 166, 6009, 13215, 6225, 161
https://tests.stockfishchess.org/tests/view/67c4de79685e87e15e7c43f5

Passed LTC:
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 244554 W: 62135 L: 62142 D: 120277
Ptnml(0-2): 137, 26612, 68794, 26589, 145
https://tests.stockfishchess.org/tests/view/67c50982685e87e15e7c443d

closes https://github.com/official-stockfish/Stockfish/pull/5928

Bench: 1980385
2025-03-21 11:16:27 +01:00
Shawn Xu
fc0e0a44d4 Refactor accumulator storage/updates
Passed Non-regression STC:
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 115840 W: 29983 L: 29854 D: 56003
Ptnml(0-2): 338, 12990, 31149, 13091, 352
https://tests.stockfishchess.org/tests/view/67d0a044166a3e8781d84223

closes https://github.com/official-stockfish/Stockfish/pull/5927

No functional change
2025-03-21 11:12:47 +01:00
Shawn Xu
66aee01bb1 Simplify Return Value Adjustment Condition
Passed Non-regression STC:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 82112 W: 21281 L: 21110 D: 39721
Ptnml(0-2): 258, 9630, 21112, 9795, 261
https://tests.stockfishchess.org/tests/view/67c42528b7226b5d8a2dd3a0

Passed Non-regression LTC:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 182652 W: 46295 L: 46240 D: 90117
Ptnml(0-2): 103, 20025, 51003, 20104, 91
https://tests.stockfishchess.org/tests/view/67c4d56b685e87e15e7c43d8

closes https://github.com/official-stockfish/Stockfish/pull/5925

Bench: 1711791
2025-03-21 11:11:12 +01:00
Daniel Monroe
f9a6d43286 Simplify condition in futility pruning
Passed STC
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 427040 W: 111061 L: 111271 D: 204708
Ptnml(0-2): 1709, 48524, 113171, 48500, 1616
https://tests.stockfishchess.org/tests/view/67af01d01a4c73ae1f930ea4

Passed rebased LTC
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 28704 W: 7330 L: 7120 D: 14254
Ptnml(0-2): 8, 3000, 8138, 3186, 20
https://tests.stockfishchess.org/tests/view/67ca629a45214989aa0a123e

closes https://github.com/official-stockfish/Stockfish/pull/5924

Bench: 2050046
2025-03-21 11:09:38 +01:00
Shawn Xu
e3660b47bd Add dbg_clear helper function
closes https://github.com/official-stockfish/Stockfish/pull/5921

No functional change
2025-03-21 11:09:28 +01:00
Carlos Esparza
e407a4f269 Simplify risk_tolerance + avoid overflow
passed simplification STC:
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 73984 W: 19058 L: 18879 D: 36047
Ptnml(0-2): 232, 8735, 18866, 8940, 219
https://tests.stockfishchess.org/tests/view/67c269a38200cf1034c9baf9

passed simplification LTC:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 39288 W: 10033 L: 9833 D: 19422
Ptnml(0-2): 14, 4168, 11086, 4356, 20
https://tests.stockfishchess.org/tests/view/67c34f8c8200cf1034c9bda1

closes https://github.com/official-stockfish/Stockfish/pull/5919

Bench: 2050046
2025-03-21 11:09:27 +01:00
Shawn Xu
b825ea6e57 Improve Perft Testing
Added #5909 problematic position and chess-library DFRC positions to
perft testing. Additional work done by @Disservin to clean up and
improve error reporting.

closes https://github.com/official-stockfish/Stockfish/pull/5917

No functional change

Co-authored-by: disservin <disservin.social@gmail.com>
2025-03-21 11:03:31 +01:00
Shawn Xu
99d32e395e Reapply #5909
This version fixes the logic of `gives_check`, which was identified to
be the cause of illegal moves.

closes https://github.com/official-stockfish/Stockfish/pull/5914

No functional change

Co-authored-by: Robert Nürnberg <robert.nurnberg@gmx.de>
Co-authored-by: gab8192 <gabrilomba57@gmail.com>
2025-03-21 11:02:19 +01:00
xu-shawn
f3bfce3531 Revert "Replace aligned() function with line_bb() and simplify king piece detection" (#5915)
closes https://github.com/official-stockfish/Stockfish/pull/5915

No functional change

Co-authored-by: Robert Nürnberg <robert.nurnberg@gmx.de>
2025-02-28 09:50:59 +01:00
FauziAkram
5c617e579c VVLTC Search Tune
Passed VVLTC with STC bounds:
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 15788 W: 4106 L: 3868 D: 7814
Ptnml(0-2): 0, 1324, 5009, 1560, 1
https://tests.stockfishchess.org/tests/view/67bf2ddd6e569f6234102ade

Passed VVLTC with LTC bounds:
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 13622 W: 3620 L: 3368 D: 6634
Ptnml(0-2): 3, 1190, 4170, 1448, 0
https://tests.stockfishchess.org/tests/view/67c04308c8f7c4c0632d8055

closes https://github.com/official-stockfish/Stockfish/pull/5910

Bench: 1823605
2025-02-27 20:40:56 +01:00
Jake Senne
6d9c6f99b9 Replace aligned() function with line_bb() and simplify king piece detection
From https://discord.com/channels/435943710472011776/813919248455827515/1342267241168900228

Saves 6 instructions

closes https://github.com/official-stockfish/Stockfish/pull/5909

No functional change
2025-02-27 20:38:03 +01:00
FauziAkram
a730b4d08b Remove two unnecessary divisions
Passed STC:
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 280768 W: 72187 L: 72236 D: 136345
Ptnml(0-2): 815, 33131, 72550, 33064, 824
https://tests.stockfishchess.org/tests/view/67bcf7afe670525923b8a101

Passed LTC:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 108684 W: 27666 L: 27536 D: 53482
Ptnml(0-2): 40, 11768, 30606, 11878, 50
https://tests.stockfishchess.org/tests/view/67be472ed8d5c2c657c52cb8

closes https://github.com/official-stockfish/Stockfish/pull/5908

Bench: 2400689
2025-02-27 20:34:49 +01:00
Shawn Xu
09faa62621 Simplify NMP Conditions
Passed Non-regression STC:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 142400 W: 36883 L: 36779 D: 68738
Ptnml(0-2): 467, 16804, 36571, 16874, 484
https://tests.stockfishchess.org/tests/view/67bd1898e4a8d7152b974ef1

Passed Non-regression LTC:
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 251868 W: 63905 L: 63920 D: 124043
Ptnml(0-2): 133, 27480, 70708, 27495, 118
https://tests.stockfishchess.org/tests/view/67bd1898e4a8d7152b974ef1

closes https://github.com/official-stockfish/Stockfish/pull/5906

Bench: 2188400
2025-02-27 20:31:04 +01:00
mstembera
e4d7136042 Combine last 3 add/remove operations
https://tests.stockfishchess.org/tests/view/67ad587052879dfd14d7e8a5
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 45856 W: 12177 L: 11855 D: 21824
Ptnml(0-2): 176, 4845, 12588, 5119, 200

The two most common cases are when added and removed counts are equal
and when they are off by 1.  When they are off by 1 we currently do a
pass combining 2 and then an extra pass for the last 1.  This patch does
a single combined pass on the final 3 instead. Tested on top of the
simplification in
https://github.com/official-stockfish/Stockfish/pull/5901

closes https://github.com/official-stockfish/Stockfish/pull/5902

No functional change
2025-02-27 20:30:44 +01:00
mstembera
d330b48e21 Handle updating the small accumulator the same way as the big one
https://tests.stockfishchess.org/tests/view/67abfe1ca04df5eb8dbebf0b
LLR: 2.97 (-2.94,2.94) <-1.75,0.25>
Total: 153088 W: 40072 L: 39979 D: 73037
Ptnml(0-2): 619, 16728, 41764, 16807, 626

closes https://github.com/official-stockfish/Stockfish/pull/5901

No functional change
2025-02-27 20:30:10 +01:00
FauziAkram
93b966829b Simplify bestvalue update formula
Passed STC:
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 124960 W: 32598 L: 32472 D: 59890
Ptnml(0-2): 480, 14852, 31694, 14970, 484
https://tests.stockfishchess.org/tests/view/67b348bae00eea114cdba37d

Passed LTC:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 150306 W: 38220 L: 38132 D: 73954
Ptnml(0-2): 98, 16430, 42005, 16526, 94
https://tests.stockfishchess.org/tests/view/67b5e37918a66624a7a3f751

closes https://github.com/official-stockfish/Stockfish/pull/5898

Bench: 2146010
2025-02-24 19:16:26 +01:00
Joost VandeVondele
0f9ae0d11c Check maximum time every iteration
This fixes a TCEC timeloss, where slow DTZ TB7 access, in combination
with syzygy PV extension, led to a timeloss.

While the extension code correctly aborted after spending moveOverhead/2
time, the mainThread did not search sufficient nodes (512 in > 1s) to
trigger the stop in check_time. At the same time, totalTime exceeded
tm.maximum() due to the factors multiplying tm.optimum().

This corner case is fixed by checking also against the tm.maximum() at
each iteration.

Even though this problem can't be triggered on fishtest, the patch was
verified there.

Passed STC:
https://tests.stockfishchess.org/tests/view/67b99e1be99f8640b318810d
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 136832 W: 35625 L: 35518 D: 65689
Ptnml(0-2): 499, 14963, 37431, 14978, 545

closes https://github.com/official-stockfish/Stockfish/pull/5896

No functional change
2025-02-24 19:15:32 +01:00
Michael Chaly
c19a6ea53c Make Pv search shallower in some cases
Conditions are the same as they are for doShallowerSearch, just that
they also apply for cases where LMR wasn't reducing anything - if result
is bad enough reduce search depth of PV search by 1.

Passed STC:
https://tests.stockfishchess.org/tests/view/67b9d2aca49c651c2caac818
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 29216 W: 7731 L: 7424 D: 14061
Ptnml(0-2): 87, 3345, 7473, 3580, 123

Passed LTC:
https://tests.stockfishchess.org/tests/view/67ba538c01f3463ae1d35e69
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 33168 W: 8529 L: 8219 D: 16420
Ptnml(0-2): 12, 3505, 9262, 3771, 34

closes https://github.com/official-stockfish/Stockfish/pull/5895

Bench: 2290732
2025-02-24 19:14:04 +01:00
Myself
57f0fe08c0 Add risk tolerance calculation
https://tests.stockfishchess.org/tests/view/67b1db2188b11e2400eb06ae
Passed STC:
LLR: 2.93 (-2.94,2.94) <0.00,2.00>
Total: 123552 W: 32388 L: 31938 D: 59226
Ptnml(0-2): 487, 14520, 31345, 14904, 520

Passed LTC:
https://tests.stockfishchess.org/tests/view/67b3d53f154c4df4fc4b1f43
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 206928 W: 52916 L: 52246 D: 101766
Ptnml(0-2): 159, 22546, 57394, 23196, 169

closes https://github.com/official-stockfish/Stockfish/pull/5893

Bench: 2705449
2025-02-24 19:12:35 +01:00
Disservin
291a429cdd Remove duplicated info string printing
Currently "info string" is being printed twice for the network arch

```
info string info string NNUE evaluation using nn-1c0000000000.nnue (133MiB, (22528, 3072, 15, 32, 1))
info string info string NNUE evaluation using nn-37f18f62d772.nnue (6MiB, (22528, 128, 15, 32, 1))
```

closes https://github.com/official-stockfish/Stockfish/pull/5889

No functional change
2025-02-24 19:10:38 +01:00
Shawn Xu
43b2d65d72 Add scaling note to futility pruning
Note that both patches below effectively reduces the frequency of futility pruning.

Passed STC:
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 51680 W: 13599 L: 13253 D: 24828
Ptnml(0-2): 217, 6056, 12959, 6380, 228
https://tests.stockfishchess.org/tests/view/67ac218fa04df5eb8dbebf26

Passed LTC:
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 51798 W: 13338 L: 12986 D: 25474
Ptnml(0-2): 42, 5584, 14310, 5906, 57
https://tests.stockfishchess.org/tests/view/67acf04152879dfd14d7e846

Regression at STC SMP:
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 231552 W: 60226 L: 59642 D: 111684
Ptnml(0-2): 565, 25994, 62031, 26664, 522
https://tests.stockfishchess.org/tests/view/67ae390c1a4c73ae1f930dbf

Passed STC:
LLR: 2.93 (-2.94,2.94) <0.00,2.00>
Total: 22560 W: 6022 L: 5725 D: 10813
Ptnml(0-2): 87, 2524, 5762, 2819, 88
https://tests.stockfishchess.org/tests/view/67ac202aa04df5eb8dbebf22

Passed LTC:
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 66138 W: 16953 L: 16572 D: 32613
Ptnml(0-2): 62, 7103, 18360, 7480, 64
https://tests.stockfishchess.org/tests/view/67ad47d852879dfd14d7e899

Regression at VVLTC SMP:
LLR: -2.94 (-2.94,2.94) <-1.75,0.25>
Total: 29138 W: 7408 L: 7655 D: 14075
Ptnml(0-2): 0, 2816, 9189, 2559, 5
https://tests.stockfishchess.org/tests/view/67b159ce6c6b9e172ad1598f

closes https://github.com/official-stockfish/Stockfish/pull/5888

No functional change
2025-02-24 19:09:52 +01:00
Nonlinear2
fc2139fedc se separate parameters for stat values
The code has been refactored to remove the `stat_bonus` and `stat_malus`
functions, as the code for each bonus/malus is now different. This
allows for future tests to modify these formulas individually.

Passed LTC with STC bounds:
https://tests.stockfishchess.org/tests/view/67b115dd6c6b9e172ad1592f
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 75756 W: 19393 L: 19044 D: 37319
Ptnml(0-2): 60, 8251, 20913, 8588, 66

Passed LTC with LTC bounds:
https://tests.stockfishchess.org/tests/view/67af5f5d6c6b9e172ad15765
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 108126 W: 27880 L: 27412 D: 52834
Ptnml(0-2): 85, 11786, 29866, 12228, 98

closes https://github.com/official-stockfish/Stockfish/pull/5887

Bench: 2809143
2025-02-24 19:09:28 +01:00
Daniel Monroe
45b2b06cea Use same term for small and large net for nnue complexity adjustment
Passed simplification STC
LLR: 2.96 (-2.94,2.94) <-1.75,0.25>
Total: 386496 W: 100682 L: 100850 D: 184964
Ptnml(0-2): 1686, 46399, 97218, 46287, 1658
https://tests.stockfishchess.org/tests/view/67a9cc6d851bb0f25324449e

Passed rebased simplification LTC
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 160884 W: 41090 L: 41012 D: 78782
Ptnml(0-2): 133, 17883, 44321, 17983, 122
https://tests.stockfishchess.org/tests/view/67aef2e91a4c73ae1f930e85

closes https://github.com/official-stockfish/Stockfish/pull/5886

Bench: 2962718
2025-02-24 19:07:58 +01:00
FauziAkram
095d19afea Use neon_m128_reduce_add_epi32 for NEON vector reduction
Accomplishing the entire horizontal addition in a single NEON instruction

closes https://github.com/official-stockfish/Stockfish/pull/5885

No functional change
2025-02-24 19:07:29 +01:00
FauziAkram
ee7259e48b Small code cleanup
Use std::is_arithmetic_v as it is the more modern and concise way to
check for arithmetic types. While at it, fixing a static assert in
misc.h, thanks to Shawn and Disservin for helping.

closes https://github.com/official-stockfish/Stockfish/pull/5883

No functional change
2025-02-24 19:04:59 +01:00
Daniel Monroe
76c319f438 Simplify ttcut depth condition
Simplify ttcut depth condition in a recent tweak of Nonlinear (PR #5876)

Passed simplification STC
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 235328 W: 61646 L: 61644 D: 112038
Ptnml(0-2): 1039, 27947, 59676, 27977, 1025
https://tests.stockfishchess.org/tests/view/67abc7fba04df5eb8dbeb442

Passed simplification LTC
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 63744 W: 16306 L: 16128 D: 31310
Ptnml(0-2): 58, 6918, 17748, 7084, 64
https://tests.stockfishchess.org/tests/view/67abd776a04df5eb8dbeb9c1

closes https://github.com/official-stockfish/Stockfish/pull/5877

Bench: 2667779
2025-02-24 19:03:19 +01:00
Carlos Esparza
e9997afb1c Replace hint_common_parent_position() by backwards accumulator updates
Only calls to `evaluate()` now trigger NNUE accumulator updates. To make
sure that we are likely to find parent positions from which to update
the accumulators we perform a backwards NNUE update whenever we compute
the accumulator from scratch for some position.

passed STC
LLR: 2.93 (-2.94,2.94) <0.00,2.00>
Total: 39680 W: 10474 L: 10164 D: 19042
Ptnml(0-2): 171, 4068, 11042, 4398, 161
https://tests.stockfishchess.org/tests/view/67a27f26eb183d11c65945be

passed LTC
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 337308 W: 86408 L: 85550 D: 165350
Ptnml(0-2): 276, 30551, 106126, 31441, 260
https://tests.stockfishchess.org/tests/view/67a287efeb183d11c65945ee

then simplified:
STC
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 28608 W: 7641 L: 7413 D: 13554
Ptnml(0-2): 132, 3036, 7744, 3256, 136
https://tests.stockfishchess.org/tests/view/67a4703719f522d3866d3345

LTC
LLR: 2.96 (-2.94,2.94) <-1.75,0.25>
Total: 200226 W: 51026 L: 50990 D: 98210
Ptnml(0-2): 170, 18468, 62799, 18508, 168
https://tests.stockfishchess.org/tests/view/67a4f255229c1a170cc08964

The version in this PR is a bit different from the simplified version,
but it's compile-time changes only.

closes https://github.com/official-stockfish/Stockfish/pull/5870

No functional change
2025-02-24 19:01:23 +01:00
FauziAkram
fa6c30af81 FutilityValue formula tweak
Passed STC:
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 29600 W: 7979 L: 7662 D: 13959
Ptnml(0-2): 138, 3446, 7324, 3745, 147
https://tests.stockfishchess.org/tests/view/67ac7dff52879dfd14d7e7da

Passed LTC:
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 49662 W: 12850 L: 12502 D: 24310
Ptnml(0-2): 41, 5354, 13689, 5710, 37
https://tests.stockfishchess.org/tests/view/67acc1b252879dfd14d7e81d

closes https://github.com/official-stockfish/Stockfish/pull/5879

Bench: 2581469
2025-02-13 20:18:35 +01:00
Daniel Monroe
d54240c50a Decrease lmr depth if static eval decreases a lot
This tweak originally had some more conditions which have been simplified away.

Passed STC
LLR: 2.93 (-2.94,2.94) <0.00,2.00>
Total: 60064 W: 15797 L: 15439 D: 28828
Ptnml(0-2): 236, 7080, 15106, 7310, 300
https://tests.stockfishchess.org/tests/view/67a2af9cfedef70e42ac3325

Passed LTC
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 76794 W: 19740 L: 19337 D: 37717
Ptnml(0-2): 61, 8327, 21236, 8694, 79
https://tests.stockfishchess.org/tests/view/67a2c904fedef70e42ac374d

Passed Non-Regression VVLTC scaling check
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 29046 W: 7581 L: 7389 D: 14076
Ptnml(0-2): 2, 2557, 9213, 2749, 2
https://tests.stockfishchess.org/tests/view/67a54b591c4a3ea87241cb83

Passed simplification STC
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 212448 W: 55244 L: 55217 D: 101987
Ptnml(0-2): 932, 25283, 53707, 25430, 872
https://tests.stockfishchess.org/tests/view/67aaacb02554387b116f698f

Passed simplification LTC
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 185736 W: 47270 L: 47217 D: 91249
Ptnml(0-2): 141, 20568, 51394, 20627, 138
https://tests.stockfishchess.org/tests/view/67ab8efa133d55b1d3bc1397

closes https://github.com/official-stockfish/Stockfish/pull/5878

Bench: 2512420
2025-02-13 20:17:26 +01:00
Nonlinear2
a4edacb87a Tweak the cutnode depth condition for TT cutoffs
Passed STC:
https://tests.stockfishchess.org/tests/view/67ab396ab5c93ee812d851f3
LLR: 2.96 (-2.94,2.94) <0.00,2.00>
Total: 83648 W: 21964 L: 21571 D: 40113
Ptnml(0-2): 339, 9779, 21217, 10128, 361

Passed LTC:
https://tests.stockfishchess.org/tests/view/67ab9647133d55b1d3bc171e
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 68160 W: 17551 L: 17166 D: 33443
Ptnml(0-2): 62, 7353, 18870, 7728, 67

closes https://github.com/official-stockfish/Stockfish/pull/5876

Bench: 3087275
2025-02-13 19:52:06 +01:00
Michael Chaly
9cc15b3049 Do more reductions for cut nodes without a tt move
Logic is somewhat similar to IIR but in LMR.
Usually things like reducing more in IIR scale badly but this patch does
this in LMR where reducing more for cutNodes is in general good, so I
believe there is no non-linear scaling.

Passed STC:
https://tests.stockfishchess.org/tests/view/67abc9aaa04df5eb8dbeb452
LLR: 2.93 (-2.94,2.94) <0.00,2.00>
Total: 42304 W: 11223 L: 10892 D: 20189
Ptnml(0-2): 184, 4904, 10669, 5187, 208

Passed LTC:
https://tests.stockfishchess.org/tests/view/67abcd7ba04df5eb8dbeb96c
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 32334 W: 8386 L: 8074 D: 15874
Ptnml(0-2): 26, 3446, 8916, 3748, 31

closes https://github.com/official-stockfish/Stockfish/pull/5875

Bench: 2612849
2025-02-13 19:49:54 +01:00
Stefan Geschwentner
7258567804 Refactor reduction rules
Refactor reduction rules so that all ttPv/Pv related stuff is in one
rule and the scaling becomes more clear. No functional change

closes https://github.com/official-stockfish/Stockfish/pull/5871

No functional change
2025-02-13 19:46:53 +01:00
Daniel Monroe
3a0418c0d0 Simplify opponent worsening
Passed simplification STC
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 57120 W: 14712 L: 14526 D: 27882
Ptnml(0-2): 53, 6241, 15796, 6407, 63
https://tests.stockfishchess.org/tests/view/67a26153eb183d11c659454d

Passed simplification LTC
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 313452 W: 79893 L: 79973 D: 153586
Ptnml(0-2): 279, 35053, 86156, 34945, 293
https://tests.stockfishchess.org/tests/view/67a29fe0fedef70e42ac32ae

closes https://github.com/official-stockfish/Stockfish/pull/5867

Bench: 2582245
2025-02-13 19:45:55 +01:00
Carlos Esparza
e089f723d8 Remove two xors by setting the hash keys for unreachable squares to zero
performance before:
3.6714 +- 0.20%  Gcycles
3.6620 +- 0.12%  Gcycles
3.6704 +- 0.26%  Gcycles
3.6602 +- 0.27%  Gcycles
3.6799 +- 0.37%  Gcycles

after:
3.6540 +- 0.30%  Gcycles
3.6388 +- 0.25%  Gcycles
3.6557 +- 0.17%  Gcycles
3.6449 +- 0.15%  Gcycles
3.6460 +- 0.26%  Gcycles

(every line is a different `profile-build` and shows the number of
cycles needed for `./stockfish bench`, measured with `perf stat -r 10`)

closes https://github.com/official-stockfish/Stockfish/pull/5754

No functional change
2025-02-13 19:44:53 +01:00
Shawn Xu
d66e603070 Increase PCM bonus when cutOffCnt is low
Passed STC:
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 36832 W: 9763 L: 9438 D: 17631
Ptnml(0-2): 159, 4267, 9254, 4562, 174
https://tests.stockfishchess.org/tests/view/67a29dbafedef70e42ac329a

Passed LTC:
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 19728 W: 5124 L: 4839 D: 9765
Ptnml(0-2): 18, 2029, 5485, 2314, 18
https://tests.stockfishchess.org/tests/view/67a2a1abfedef70e42ac32b7

closes https://github.com/official-stockfish/Stockfish/pull/5865

Bench: 3197798
2025-02-05 19:00:25 +01:00
Daniel Monroe
3dfbc5de25 Remove non-pawn material check in qsearch pruning
Passed simplification STC
LLR: 2.96 (-2.94,2.94) <-1.75,0.25>
Total: 47712 W: 12621 L: 12409 D: 22682
Ptnml(0-2): 224, 5349, 12480, 5597, 206
https://tests.stockfishchess.org/tests/view/67a1b4fb612069de394afc37

Passed rebased simplification LTC
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 188274 W: 47727 L: 47677 D: 92870
Ptnml(0-2): 171, 20429, 52867, 20519, 151
https://tests.stockfishchess.org/tests/view/67a2a761fedef70e42ac3300

closes https://github.com/official-stockfish/Stockfish/pull/5866

bench 2654242
2025-02-05 18:56:12 +01:00
Disservin
4c6d2bf921 Show stdout/stderr in CI/CD tests
makes it easier to fix based on warnings shown with e.g. valgrind

closes https://github.com/official-stockfish/Stockfish/pull/5862

No functional change
2025-02-05 18:52:28 +01:00
Disservin
2a5b41fd12 Fixes a wrongly combined merge conflict from the previous merge wave.
Passed STC:
https://tests.stockfishchess.org/tests/view/67a288aaeb183d11c65945f1
LLR: 2.99 (-2.94,2.94) <0.00,2.00>
Total: 51424 W: 13588 L: 13237 D: 24599
Ptnml(0-2): 223, 6039, 12860, 6344, 246

Passed LTC:
https://tests.stockfishchess.org/tests/view/67a28c0aeb183d11c6594609
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 54144 W: 13900 L: 13543 D: 26701
Ptnml(0-2): 42, 5881, 14870, 6236, 43

closes https://github.com/official-stockfish/Stockfish/pull/5863

Bench: 2345723
2025-02-04 23:08:43 +01:00