Commit Graph
6911 Commits
Author SHA1 Message Date
mstemberaandJoost VandeVondele 8815d1ef02 Minor cleanup in full_threats.cpp
closes https://github.com/official-stockfish/Stockfish/pull/6509

No functional change
2026-01-01 16:13:44 +01:00
FauziAkramandJoost VandeVondele 5b9259e51f Replacing nested loops with a single range-based for loop
closes https://github.com/official-stockfish/Stockfish/pull/6503

No functional change
2026-01-01 16:12:35 +01:00
anematodeandJoost VandeVondele 593eeaf24c simplify find_nnz a bit
This code path is never taken for vector sizes >= 512, so we can simplify it.

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

No functional change
2026-01-01 16:08:03 +01:00
ppigazziniandJoost VandeVondele 0317c6ccec build: rename WINE_PATH to RUN_PREFIX for wrapper execution
WINE_PATH started as a Wine-specific knob, but it’s now used more generally
as a command prefix to run the built engine under wrappers
like Intel SDE, qemu-user, etc.

- Add RUN_PREFIX as the supported “run wrapper/prefix” variable in Makefile
- Set WINE_PATH as a deprecated alias
- Update CI and scripts to use RUN_PREFIX

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

No functional change
2026-01-01 16:06:25 +01:00
anematodeandJoost VandeVondele aeb3bf33a9 port get_changed_pieces to ARM NEON
passed STC:
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 71968 W: 18833 L: 18489 D: 34646
Ptnml(0-2): 192, 7310, 20643, 7640, 199
https://tests.stockfishchess.org/tests/view/69509e5c572093c1986d7a0a

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

No functional change
2026-01-01 16:04:43 +01:00
Michael ChalyandJoost VandeVondele ced9f69834 Adjust main history with every new root position
this patch dampens down main history to 3/4 of it value for all possible moves
at the start of ID loop, making it partially refresh with every new root
position.

Passed STC:
https://tests.stockfishchess.org/tests/view/694e33ff572093c1986d7234
LLR: 2.93 (-2.94,2.94) <0.00,2.00>
Total: 115520 W: 30164 L: 29735 D: 55621
Ptnml(0-2): 395, 13192, 30192, 13551, 430

Passed LTC:
https://tests.stockfishchess.org/tests/view/6950cbe6572093c1986d816c
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 63672 W: 16480 L: 16114 D: 31078
Ptnml(0-2): 46, 6524, 18329, 6892, 45

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

bench 2710946
2026-01-01 15:53:04 +01:00
Steinar H. GundersonandJoost VandeVondele 1453691496 Fix feature check
Use _POSIX_C_SOURCE to check for PTHREAD_MUTEX_ROBUST support. The latter is a enum, not a defined variable.

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

No functional change
2026-01-01 15:52:01 +01:00
Joost VandeVondele e0fb783c30 Fix incorrect initialization
Fixes https://github.com/official-stockfish/Stockfish/issues/6505

Missing initialization seemingly resulting in side effects, as discussed in the issue.

Credit to Sopel for spotting the bug.

PR used as a testcase for CoPilot, doing the right thing https://github.com/official-stockfish/Stockfish/pull/6478#discussion_r2655467218

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

No functional change
2026-01-01 15:51:09 +01:00
Timothy HerchenandDisservin 44d5467bbe Remove -Wstack-usage on (apple) clang
Clang pretends to be GCC, but is enraged by `-Wstack-usage`:

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

No functional change
2025-12-28 14:59:26 +01:00
969285fa5d Shared pawn history
[Passed STC SMP](https://tests.stockfishchess.org/tests/view/694e506c572093c1986d7276):
```
LLR: 2.97 (-2.94,2.94) <0.00,2.00>
Total: 14992 W: 3924 L: 3653 D: 7415
Ptnml(0-2): 20, 1547, 4090, 1820, 19
```

[Passed LTC SMP](https://tests.stockfishchess.org/tests/live_elo/694ead61572093c1986d7365):
```
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 41146 W: 10654 L: 10342 D: 20150
Ptnml(0-2): 17, 3999, 12225, 4319, 13
```

[Passed a sanity check STC SMP post-refactoring](https://tests.stockfishchess.org/tests/view/69503997572093c1986d763a):
```
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 46728 W: 12178 L: 11863 D: 22687
Ptnml(0-2): 82, 5093, 12685, 5436, 68
```

(The large gain of the first STC was probably a fluke, and this result
is more reasonable!)

After shared correction history, Viz suggested we try sharing other
histories, especially `pawnHistory`. As far as we're aware, sharing
history besides correction history (like Caissa does) is novel. The
implementation follows the same pattern as shared correction history –
the size of the history table is scaled with
`next_power_of_two(threadsInNumaNode)` and the entry is prefetched in
`do_move`.

A bit of refactoring was done to accommodate this new history. Note that
we prefetch `&history->pawn_entry(*this)[pc][to]` rather than
`&history->pawn_entry(*this)` because unlike the other entries, each
entry contains multiple cache lines.

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

Bench: 2503391

Co-authored-by: Michael Chaly <Vizvezdenec@gmail.com>
2025-12-28 14:59:09 +01:00
Stefan GeschwentnerandDisservin 1780c1fd6e For expected ALL nodes scale up reduction with depth dependent factor.
Passed STC:
LLR: 2.93 (-2.94,2.94) <0.00,2.00>
Total: 141120 W: 36860 L: 36390 D: 67870
Ptnml(0-2): 470, 16441, 36314, 16819, 516
https://tests.stockfishchess.org/tests/view/694978e93c8768ca45072763

Passed LTC:
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 66576 W: 17078 L: 16700 D: 32798
Ptnml(0-2): 45, 7093, 18628, 7483, 39
https://tests.stockfishchess.org/tests/view/694bb608572093c1986d6ba6

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

Bench: 2503391
2025-12-28 14:55:55 +01:00
KazAppsandDisservin b2e60960b3 Fix nonPawnKey
Fix incorrect nonPawnKey update

Passed non-reg SMP STC:
```
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 139424 W: 35792 L: 35690 D: 67942
Ptnml(0-2): 197, 15783, 37665, 15855, 212
```
https://tests.stockfishchess.org/tests/view/694b7b7e572093c1986d6b0d

Passed non-reg SMP LTC:
```
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 88880 W: 22863 L: 22718 D: 43299
Ptnml(0-2): 16, 8947, 26401, 9028, 48
```
https://tests.stockfishchess.org/tests/view/694d2ceb572093c1986d6fc8

fixes https://github.com/official-stockfish/Stockfish/issues/6492

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

Bench: 2475788
2025-12-28 14:55:47 +01:00
Daniel MonroeandDisservin 1047f844d1 Simplify doDeeperSearch
Passed simplification STC
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 92096 W: 23888 L: 23728 D: 44480
Ptnml(0-2): 336, 10796, 23608, 10988, 320
https://tests.stockfishchess.org/tests/view/694b6b9d572093c1986d6ae0

Passed simplification LTC
LLR: 2.96 (-2.94,2.94) <-1.75,0.25>
Total: 50064 W: 12789 L: 12598 D: 24677
Ptnml(0-2): 24, 5350, 14103, 5521, 34
https://tests.stockfishchess.org/tests/view/694d49aa572093c1986d7021

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

Bench: 2494221
2025-12-28 14:53:12 +01:00
Joost VandeVondeleandDisservin 06819ad54c Update Top CPU Contributors
update to current

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

No functional change
2025-12-28 14:51:56 +01:00
FauziAkramandDisservin 9d69577e19 Removing redundant parentheses
closes https://github.com/official-stockfish/Stockfish/pull/6490

No functional change
2025-12-28 14:50:36 +01:00
FauziAkramandDisservin cd3a837324 Refine reduction logic based on next-ply cutoff count
Passed STC:
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 38208 W: 10076 L: 9754 D: 18378
Ptnml(0-2): 139, 4390, 9742, 4676, 157
https://tests.stockfishchess.org/tests/view/6945bb6446f342e1ec211d93

Passed LTC:
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 64086 W: 16529 L: 16157 D: 31400
Ptnml(0-2): 34, 6808, 17990, 7174, 37
https://tests.stockfishchess.org/tests/view/69479d303c8768ca45072446

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

Bench: 2442415
2025-12-28 14:49:19 +01:00
Taras VukandDisservin c475024be7 Incorporate statscore into history bonus
Passed STC:
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 80128 W: 20879 L: 20498 D: 38751
Ptnml(0-2): 274, 9318, 20496, 9705, 271
https://tests.stockfishchess.org/tests/view/6945d11f3c8768ca45072218

Passed LTC:
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 134298 W: 34497 L: 33983 D: 65818
Ptnml(0-2): 81, 14334, 37812, 14834, 88
https://tests.stockfishchess.org/tests/view/6947bf033c8768ca45072491

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

Bench: 2325401
2025-12-23 21:42:45 +01:00
Disservin 73b3b18595 Init threat offsets at compile time
Init threat offsets at compile time. Avoid another global init function call.

Passed STC Non-Regression:
https://tests.stockfishchess.org/tests/view/694971a83c8768ca4507275c
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 43296 W: 11284 L: 11077 D: 20935
Ptnml(0-2): 152, 4611, 11924, 4800, 161

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

No functional change
2025-12-23 21:42:45 +01:00
FauziAkramandDisservin 4d4c6ebd02 Simplify doDeeperSearch formula
Passed STC:
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 211776 W: 54939 L: 54911 D: 101926
Ptnml(0-2): 714, 24971, 54484, 25011, 708
https://tests.stockfishchess.org/tests/view/6938971875b70713ef796b70

Passed LTC:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 216774 W: 55346 L: 55326 D: 106102
Ptnml(0-2): 105, 23599, 60980, 23577, 126
https://tests.stockfishchess.org/tests/view/693fc91f46f342e1ec20f9f6

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

Bench: 3267755
2025-12-23 21:42:45 +01:00
Michael ChalyandDisservin 447f66acac Less penalty for quiet late moves that didn't beat the best move.
This moves since they are late in move ordering probably already have pretty bad stats anyway.
Passed STC:
https://tests.stockfishchess.org/tests/view/6943bcd546f342e1ec210e25
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 96704 W: 25206 L: 24798 D: 46700
Ptnml(0-2): 357, 11244, 24767, 11602, 382
Passed LTC:
https://tests.stockfishchess.org/tests/view/6946a8723c8768ca450722f0
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 89814 W: 23193 L: 22770 D: 43851
Ptnml(0-2): 53, 9532, 25321, 9941, 60
bench 2717363

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

Bench: 2791988
2025-12-23 21:42:45 +01:00
anematodeandDisservin 1a67ccc72e Share correction history between threads
We did quite a few tests because this is a pretty involved change with
unknown scaling behavior, but results are decent.

[STC 10+0.1 1th, non-regression](https://tests.stockfishchess.org/tests/live_elo/6941ce3b46f342e1ec210180)
```
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 83200 W: 21615 L: 21452 D: 40133
Ptnml(0-2): 247, 9064, 22844, 9169, 276
```

[STC 5+0.05 8th](https://tests.stockfishchess.org/tests/live_elo/693dc38346f342e1ec20f555)
```
LLR: 3.48 (-2.94,2.94) <0.00,2.00>
Total: 58536 W: 15067 L: 14688 D: 28781
Ptnml(0-2): 87, 6474, 15781, 6825, 101
```

[LTC 20+0.2 8th](https://tests.stockfishchess.org/tests/live_elo/693f2afb46f342e1ec20f847)
```
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 27716 W: 7211 L: 6925 D: 13580
Ptnml(0-2): 8, 2674, 8207, 2962, 7
```

[LTC 10+0.1 64th](https://tests.stockfishchess.org/tests/live_elo/694003aa46f342e1ec20fac4):
```
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 16918 W: 4439 L: 4182 D: 8297
Ptnml(0-2): 3, 1493, 5213, 1744, 6
```

[NUMA test, 5+0.05 256th](https://tests.stockfishchess.org/tests/view/6941ee4e46f342e1ec210203)
```
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 7124 W: 1910 L: 1678 D: 3536
Ptnml(0-2): 0, 560, 2211, 790, 1
```

[LTC 60+0.6 64th](https://tests.stockfishchess.org/tests/live_elo/6940a85346f342e1ec20fcde):
```
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 15504 W: 4045 L: 3826 D: 7633
Ptnml(0-2): 0, 1002, 5530, 1219, 1
```

Bonus (courtesy of Viz): The 1 double kill in this last test was master
blundering a cool mate in 3: https://lichess.org/jyNZuRl4

Basically the idea here is to share correction history between threads.
That way, T1 can use the correction values produced by T2, which already
searched positions with that pawn structure etc., so that T1 can search
more efficiently. The table size per thread is about the same, so we
shouldn't get a large increase in hash collisions; in fact, I'd expect a
lower collision rate overall.

Although I came up with and implemented the idea independently,
[Caissa](https://github.com/Witek902/Caissa) was the first engine to
implement corrhist sharing (and corrhist in the first place) – this idea
is not completely novel.

The table size is rounded to a power of two. In particular, it's `65536
* nextPowerOfTwo(threadCount)`. That way, the indexing operation becomes
an AND of the key bits with a mask, rather than something more expensive
(e.g., a `mul_hi64`-style approach or a modulo).

The updates are racy, like the TT, but because `entry` is hoisted into a
register, there's no risk of writing back a value that's out of the
designated range `[-D, D]`. Various attempts at rewriting using atomics
led to substantial slowdowns, so we begrudgingly ignored the functions
in thread sanitizer, but at some point we'd like to make this better.

We allocate one shared correction history per NUMA node, because the
penalty associated with crossing nodes is substantial – I get a 40% hit
with NPS=4 and 256 threads, which is intolerable. With separate tables
per NUMA node I get a 6% penalty for nodes per second, which isn't ideal
but apparently compensated for.

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

Bench: 2690604

Co-authored-by: Disservin <disservin.social@gmail.com>
2025-12-23 21:42:29 +01:00
FauziAkramandDisservin fb41f2953f Remove low ply history for check evasions scoring
Passed STC:
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 81888 W: 21336 L: 21166 D: 39386
Ptnml(0-2): 284, 9438, 21342, 9584, 296
https://tests.stockfishchess.org/tests/view/692ada47b23dfeae38cffce5

Passed LTC:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 107328 W: 27534 L: 27404 D: 52390
Ptnml(0-2): 55, 11390, 30659, 11490, 70
https://tests.stockfishchess.org/tests/view/692d7a01b23dfeae38d011ab

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

Bench: 3006182
2025-12-23 21:41:34 +01:00
AliceRoseliaandDisservin c467fe5ba4 Simplify futility pruning
Passed non regression STC:
https://tests.stockfishchess.org/tests/view/693e642c46f342e1ec20f68d
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 107968 W: 28080 L: 27937 D: 51951
Ptnml(0-2): 381, 12708, 27626, 12925, 344

Passed non regression LTC:
https://tests.stockfishchess.org/tests/view/693ff10c46f342e1ec20fa6a
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 334266 W: 85271 L: 85370 D: 163625
Ptnml(0-2): 179, 36395, 94086, 36292, 181

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

Bench: 2987379
2025-12-21 15:43:32 +01:00
Shawn XuandDisservin 495296fc76 Remove Secondary TT Aging
Passed VVLTC w/ STC Bounds:
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 107006 W: 27676 L: 27326 D: 52004
Ptnml(0-2): 21, 9505, 34097, 9863, 17
https://tests.stockfishchess.org/tests/view/6939ac5b75b70713ef796f11

Passed VVLTC w/ LTC Bounds:
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 263190 W: 67547 L: 66837 D: 128806
Ptnml(0-2): 32, 23939, 82942, 24651, 31
https://tests.stockfishchess.org/tests/view/692165823b03dd3a060e666d

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

Bench: 2800411
2025-12-21 15:43:32 +01:00
sscg13andDisservin 32292d1e62 Represent threat weights directly as i8
LEB128 adds no additional compression and adds extra complexity to the
code currently.

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

No functional change
2025-12-21 15:43:32 +01:00
Daniel MonroeandDisservin b4b01d0ca2 Remove rootDepth condition in newDepth clamping
Passed simplification STC
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 132256 W: 34462 L: 34347 D: 63447
Ptnml(0-2): 470, 15625, 33833, 15720, 480
https://tests.stockfishchess.org/tests/view/69325fe0a24a6df719fcca16

Passed simplification LTC
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 128220 W: 32503 L: 32392 D: 63325
Ptnml(0-2): 94, 13900, 35982, 14069, 65
https://tests.stockfishchess.org/tests/view/6934c2b3a24a6df719fcdf1e

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

Bench: 2926903
2025-12-21 15:43:32 +01:00
ppigazziniandDisservin d92e6b458a chore(ci): bump runner to macos-15
closes https://github.com/official-stockfish/Stockfish/pull/6475

No functional change
2025-12-21 15:43:32 +01:00
Pieter te BrakeandDisservin 955c927265 Removed redundant board updates
Contrary to what the comment says, `remove_piece` does in fact set the
relevant `board` elements to `NO_PIECE`.

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

No functional change
2025-12-21 15:43:32 +01:00
Timothy HerchenandDisservin e0e6fdf094 Tweak nnue_accumulator indexing
```
LLR: 2.93 (-2.94,2.94) <0.00,2.00>
Total: 92736 W: 24149 L: 23764 D: 44823
Ptnml(0-2): 280, 10056, 25334, 10395, 303
```

The use of `IndexType` in the loops is suboptimal because it requires
truncation to 32 bits, and thereby defeats some optimizations. Using
`size_t` for the loop body works nicely, and a signed index into the
index lists allows the compiler to assume the case `added.size() ==
UINT_MAX`, which would be an infinite loop, to not happen.

Passed STC
https://tests.stockfishchess.org/tests/live_elo/692fd98ab23dfeae38d01d98

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

No functional change
2025-12-21 15:43:32 +01:00
mstemberaandDisservin e1c919fd7e Fix one error and all warnings on MSVC 2026
The error is "C1001: Internal compiler error." in uci.cpp on line 370 of
master.  For some reason the compiler can't handle the
std::size(hashfullAges) inside the lambda.  Older MSVC versions had no
problem.

Most of the warnings are due to implicit type conversions "conversion
from type A to type B, possible loss of data"
many of which have been present for a while.

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

No functional change
2025-12-21 15:43:32 +01:00
Daniel MonroeandDisservin 8449e5eb9d Remove non-functional term in isShuffling
closes https://github.com/official-stockfish/Stockfish/pull/6462

No functional change
2025-12-21 15:43:32 +01:00
Timothy HerchenandDisservin a98c3f6878 Small threat-related cleanups
Remove a couple unused things, mark `noRaysContaining` as
`[[maybe_unused]]` (suggested by Viz) to silence a warning on GCC 10,
update a comment, and replace inline constants

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

No functional change
2025-12-21 15:43:32 +01:00
FauziAkramandDisservin 863c0ec6d0 Simplify piece threat calculation
Passed STC:
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 105984 W: 27206 L: 27067 D: 51711
Ptnml(0-2): 260, 11556, 29245, 11647, 284
https://tests.stockfishchess.org/tests/view/6914798e7ca87818523317cf

Passed LTC:
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 53028 W: 13635 L: 13456 D: 25937
Ptnml(0-2): 28, 5184, 15908, 5369, 25
https://tests.stockfishchess.org/tests/view/6918c5fc7ca8781852332312

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

No functional change
2025-12-21 15:43:25 +01:00
FauziAkramandDisservin 5edfabd070 Fix Typo
closes https://github.com/official-stockfish/Stockfish/pull/6436

No functional change
2025-12-21 15:22:06 +01:00
Timothy HerchenandJoost VandeVondele c109a88ebe fix missing condition
Fixes a bug in https://github.com/official-stockfish/Stockfish/pull/6453
https://github.com/official-stockfish/Stockfish/commit/abd835dcbc3a28481224f6253b00b7420d062513
The modifications to the DirtyThreats bitboards should only happen if PutPiece is true.
This somehow didn't affect bench at the default parameters.

Reference AVX2:
./stockfish.killdeer-fix.avx2 bench 64 1 23
Nodes searched  : 178140156
Nodes/second    : 1503152

before patch:
./stockfish.master.avx512icl  bench 64 1 23
Nodes searched  : 218349728
Nodes/second    : 1743450

after patch:
./stockfish.killdeer-fix.avx512icl bench 64 1 23
Nodes searched  : 178140156
Nodes/second    : 1727520

passed STC:
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 39328 W: 10293 L: 10080 D: 18955
Ptnml(0-2): 113, 4306, 10629, 4487, 129
https://tests.stockfishchess.org/tests/view/692fb2d8b23dfeae38d01c81

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

Bench: 2912398
2025-12-03 12:32:29 +01:00
Daniel MonroeandJoost VandeVondele 5297ba0a1a Move hindsight reductions above cutoffs
Passed STC
LLR: 2.93 (-2.94,2.94) <0.00,2.00>
Total: 52640 W: 13701 L: 13361 D: 25578
Ptnml(0-2): 168, 6143, 13356, 6487, 166
https://tests.stockfishchess.org/tests/view/6918dc407ca8781852332339

Passed LTC
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 207690 W: 53187 L: 52520 D: 101983
Ptnml(0-2): 93, 22515, 57994, 23118, 125
https://tests.stockfishchess.org/tests/view/6919dd307ca87818523324c7

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

Bench: 2912398
2025-12-01 17:35:34 +01:00
Timothy HerchenandJoost VandeVondele abd835dcbc Improve update_piece_threats
passed on avx512ICL:
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 30240 W: 8026 L: 7726 D: 14488
Ptnml(0-2): 95, 3235, 8171, 3513, 106
https://tests.stockfishchess.org/tests/view/69281d9ab23dfeae38cfeeb8

passed on generic architectures:
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 73184 W: 19183 L: 18821 D: 35180
Ptnml(0-2): 258, 7988, 19744, 8338, 264
https://tests.stockfishchess.org/tests/view/6928ba11b23dfeae38cff276

subsequent cleanups tested as:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 72480 W: 18678 L: 18502 D: 35300
Ptnml(0-2): 242, 7925, 19718, 8125, 230
https://tests.stockfishchess.org/tests/view/692a26adb23dfeae38cff566

We add an argument noRaysContaining, which skips all discoveries which contain
all bits in the argument; if the argument is from | to, then this will
eliminate the discovery. Separately, on AVX512ICL we can speed up the
computation of DirtyThreats by moving from a pop_lsb loop to a vector
extraction with vpcompressb. See PR for details.

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

No functional change
2025-12-01 17:26:50 +01:00
Joost VandeVondeleandDisservin 9e2ee13e77 Update main network to nn-2962dca31855.nnue
trained with https://github.com/vondele/nettest/blob/dd921672bd4ad8eb09fa45248078450857e81884/threats.yaml

on top off and tested against https://github.com/official-stockfish/Stockfish/pull/6452

passed STC
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 130720 W: 34028 L: 33570 D: 63122
Ptnml(0-2): 435, 15348, 33384, 15710, 483
https://tests.stockfishchess.org/tests/view/69294539b23dfeae38cff3ad

passed LTC
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 51144 W: 13140 L: 12794 D: 25210
Ptnml(0-2): 38, 5370, 14408, 5720, 36
https://tests.stockfishchess.org/tests/view/692a9c37b23dfeae38cffa4f

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

Bench: 2823033
2025-11-30 21:58:35 +01:00
KazAppsandDisservin 74303ca7f9 Update AUTHORS (KazApps)
closes https://github.com/official-stockfish/Stockfish/pull/6454

No functional change
2025-11-30 21:58:35 +01:00
Joost VandeVondeleandDisservin 4fe04a2cc6 Update main network to nn-87a9d7857d88.nnue
trained with https://github.com/vondele/nettest/blob/842d95177f882c0e9b5262247c38d8fcb3e0f3db/threats.yaml

passed STC:
LLR: 2.93 (-2.94,2.94) <0.00,2.00>
Total: 114880 W: 30291 L: 29851 D: 54738
Ptnml(0-2): 499, 13547, 28947, 13909, 538
https://tests.stockfishchess.org/tests/view/6923ec4bba083df4ca63dd39

passed LTC:
LLR: 2.97 (-2.94,2.94) <0.50,2.50>
Total: 113268 W: 29115 L: 28634 D: 55519
Ptnml(0-2): 114, 12295, 31340, 12766, 119
https://tests.stockfishchess.org/tests/view/6925cd01b23dfeae38cfe134

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

Bench: 3028457
2025-11-30 21:58:35 +01:00
FauziAkramandDisservin c95386256e Simplify the highBestMoveEffort formula in Time management
Passed STC:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 22272 W: 5885 L: 5655 D: 10732
Ptnml(0-2): 76, 2329, 6108, 2535, 88
https://tests.stockfishchess.org/tests/view/69244d07ba083df4ca63e02b

Passed LTC:
LLR: 2.95 (-2.94,2.94) <-1.75,0.25>
Total: 48690 W: 12405 L: 12221 D: 24064
Ptnml(0-2): 29, 4755, 14597, 4931, 33
https://tests.stockfishchess.org/tests/view/6924de9aba083df4ca63e327

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

No functional change
2025-11-30 21:58:35 +01:00
Timothy HerchenandDisservin 7c7c574e6b Fix msvc macro
closes https://github.com/official-stockfish/Stockfish/pull/6449

No functional change
2025-11-30 21:58:35 +01:00
Shawn XuandDisservin 45d034fa50 Formatting fixups
closes https://github.com/official-stockfish/Stockfish/pull/6446

No functional change
2025-11-30 21:58:35 +01:00
pb00067andDisservin c73f21df97 Fix for SF getting stuck during search (issue #5023)
Among several passed similar versions this is the simpliest one.

Passed STC non-regression
https://tests.stockfishchess.org/tests/view/691f3b4aacb6dbdf23d07d11
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 126368 W: 32607 L: 32489 D: 61272
Ptnml(0-2): 408, 13974, 34298, 14100, 404

Passed LTC non-regression
https://tests.stockfishchess.org/tests/view/69209712acb6dbdf23d0836a
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 114786 W: 29097 L: 28976 D: 56713
Ptnml(0-2): 53, 11841, 33488, 11954, 57

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

Bench: 2941767
2025-11-30 21:58:34 +01:00
Carlos EsparzaandDisservin f4244e13e4 Some more work on FullThreats::make_index
[Passed STC](https://tests.stockfishchess.org/tests/live_elo/691fc321acb6dbdf23d07e4b):

```
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 215360 W: 55651 L: 55108 D: 104601
Ptnml(0-2): 520, 22399, 61290, 22960, 511
```

This PR is on top of ces42's work so I'll rebase if that PR changes.
Essentially, it comprises my adjustments to `make_index` that remained
unmerged before threat inputs was finalized.

The unsigned intermediate variables let us skip a bunch of useless sign
extensions (because Square and Piece inherit from `int8_t`, and C/C++
semantics require narrow integers to be promoted to `int` before doing
arithmetic on them). Additionally, by removing the special usage of
`offsets[][64]` and `[65]` the indexing becomes more efficient. (This
usage was a temporary hack from sscg anyway, so I think he'll like that
it's gone.) Finally, the `sf_assume` condition was fixed so that it
actually makes a difference to the compiler.

The speedup is fairly nice locally (combining both ces42's and these changes):

```
Result of 100 runs
==================
base (...kfish.master) =    1691982  +/- 1907
test (./stockfish    ) =    1714349  +/- 1789
diff                   =     +22367  +/- 2465

speedup        = +0.0132
P(speedup > 0) =  1.0000
```

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

No functional change
2025-11-30 21:45:14 +01:00
Shawn XuandDisservin 93f2d14d95 Simplify Incremental Updates
Passed Non-regression STC:
LLR: 3.03 (-2.94,2.94) <-1.75,0.25>
Total: 277856 W: 71575 L: 71611 D: 134670
Ptnml(0-2): 842, 30719, 75836, 30695, 836
https://tests.stockfishchess.org/tests/view/69169dc17ca8781852331d76

Supersedes #6430

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

No functional change
2025-11-30 21:43:54 +01:00
Shawn XuandDisservin 1132d893e0 Simplify Accumulator Updates
Passed Non-regression STC:
LLR: 2.93 (-2.94,2.94) <-1.75,0.25>
Total: 146848 W: 37915 L: 37820 D: 71113
Ptnml(0-2): 415, 16159, 40186, 16244, 420
https://tests.stockfishchess.org/tests/view/691772217ca878185233202b

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

No functional change
2025-11-30 21:41:51 +01:00
Daniel MonroeandJoost VandeVondele d9fd516547 Post-NNUEv10 tune
Tune search parameters after the switch to NNUEv10.

The change is neutral at STC but increases with the TC. The main changes are more aggressive corrections, futility pruning, and extensions.

Failed STC
LLR: -2.96 (-2.94,2.94) <0.00,2.00>
Total: 108320 W: 27616 L: 27719 D: 52985
Ptnml(0-2): 332, 12833, 27884, 12828, 283
https://tests.stockfishchess.org/tests/view/69212e623b03dd3a060e6114

Passed LTC
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 43272 W: 11117 L: 10788 D: 21367
Ptnml(0-2): 20, 4543, 12180, 4874, 19
https://tests.stockfishchess.org/tests/view/692130813b03dd3a060e6123

Passed VLTC
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 22714 W: 5840 L: 5581 D: 11293
Ptnml(0-2): 2, 2152, 6795, 2401, 7
https://tests.stockfishchess.org/tests/view/6921387b3b03dd3a060e6191

Passed VLTC SMP
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 11868 W: 3142 L: 2896 D: 5830
Ptnml(0-2): 0, 1007, 3676, 1249, 2
https://tests.stockfishchess.org/tests/view/69212e953b03dd3a060e611b

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

bench 2907929
2025-11-22 07:56:47 +01:00
Shawn XuandJoost VandeVondele 035cb146d4 Do more futility pruning
closes https://github.com/official-stockfish/Stockfish/pull/6433

Bench: 2469519
2025-11-17 14:03:02 +01:00
Joost VandeVondele 61149ac9ee Update main net to nn-c0ae49f08b40.nnue
Trained using the recipe https://github.com/vondele/nettest/blob/d39f72420504e474a716b9977c1380541a7b482e/threats.yaml

fix CI check for negative evals.

fix format

passed STC:
LLR: 2.95 (-2.94,2.94) <0.00,2.00>
Total: 84032 W: 21876 L: 21490 D: 40666
Ptnml(0-2): 239, 9821, 21553, 10121, 282
https://tests.stockfishchess.org/tests/view/6914b81e7ca87818523318aa

passed LTC:
LLR: 2.95 (-2.94,2.94) <0.50,2.50>
Total: 126420 W: 32429 L: 31927 D: 62064
Ptnml(0-2): 56, 13748, 35118, 14214, 74
https://tests.stockfishchess.org/tests/view/6916c1277ca8781852331dd8

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

Bench: 2513286
2025-11-17 14:00:33 +01:00