Günther Demetz [Sun, 5 Nov 2017 18:49:17 +0000 (19:49 +0100)]
Handle BxN trade as good capture when history score is good
STC:
LLR: 2.95 (-2.94,2.94) [0.00,5.00]
Total: 19374 W: 3499 L: 3294 D: 12581
http://tests.stockfishchess.org/tests/view/
59fc23f50ebc590ccbb8a0bf
LTC:
LLR: 2.95 (-2.94,2.94) [0.00,5.00]
Total: 91030 W: 11680 L: 11274 D: 68076
http://tests.stockfishchess.org/tests/view/
59fc43ad0ebc590ccbb8a0d0
Bench:
5482249
Stefan Geschwentner [Fri, 3 Nov 2017 11:37:11 +0000 (12:37 +0100)]
Introduce capture history table for capture move sorting
Introduce capture move history table indexed by moved piece,
target square and captured piece type for sorting capture moves.
STC:
LLR: 2.95 (-2.94,2.94) [0.00,5.00]
Total: 11374 W: 2096 L: 1924 D: 7354
http://tests.stockfishchess.org/tests/view/
59fac8dc0ebc590ccbb89fc5
LTC:
LLR: 2.95 (-2.94,2.94) [0.00,5.00]
Total: 24791 W: 3196 L: 3001 D: 18594
http://tests.stockfishchess.org/tests/view/
59fae4d20ebc590ccbb89fd9
Bench:
5536775
Joost VandeVondele [Fri, 3 Nov 2017 12:51:53 +0000 (13:51 +0100)]
Replace easyMove with simple scheme
Reduces time for a stable bestMove, giving some of the won time for the next move.
the version before the pvDraw passed both STC and LTC
passed STC:
http://tests.stockfishchess.org/tests/view/
59e98d5a0ebc590ccbb896ec
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 78561 W: 13945 L: 13921 D: 50695
elo = 0.106 +- 1.445 LOS: 55.716%
passed LTC:
http://tests.stockfishchess.org/tests/view/
59eb9df90ebc590ccbb897ae
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 29056 W: 3640 L: 3530 D: 21886
elo = 1.315 +- 1.982 LOS: 90.314%
This version, rebased on pvDrawPR with the obvious change, was verified again on STC:
http://tests.stockfishchess.org/tests/view/
59ee104e0ebc590ccbb89899
LLR: 2.96 (-2.94,2.94) [-3.00,1.00]
Total: 19890 W: 3648 L: 3525 D: 12717
elo = 2.149 +- 2.895 LOS: 92.692%
and LTC:
http://tests.stockfishchess.org/tests/view/
59f9673a0ebc590ccbb89ea0
Total : 17966
Win : 2273 ( 12.652%)
Loss : 2149 ( 11.961%)
Draw : 13544 ( 75.387%)
Score : 50.345%
Sensitivity : 0.014%
2*(W-L)/(W+L) : 5.608%
LLR [-3.0, 1.0] : 2.95
BayesElo range : [ -1.161, 4.876, 10.830] (DrawElo: 341.132)
LogisticElo range : [ -0.501, 2.105, 4.677]
LOS : 94.369 %
LTC again:
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 17966 W: 2273 L: 2149 D: 13544
LogisticElo range : [ -0.501, 2.105, 4.677]
LOS : 94.369 %
unchanged bench:
5234652
Cooffe [Fri, 27 Oct 2017 18:05:19 +0000 (21:05 +0300)]
Update Copyright year inMakefile
No functional change.
Joost VandeVondele [Fri, 20 Oct 2017 17:17:49 +0000 (19:17 +0200)]
Extra thinking before accepting draw PVs.
If the PV leads to a draw (3-fold / 50-moves) position
and we're ahead of time, think a little longer, possibly
finding a better way.
As this is most likely effective at higher draw rates,
tried speculative LTC after a yellow STC:
STC:
http://tests.stockfishchess.org/tests/view/
59eb173a0ebc590ccbb8975d
LLR: -2.95 (-2.94,2.94) [0.00,5.00]
Total: 56095 W: 10013 L: 9902 D: 36180
elo = 0.688 +- 1.711 LOS: 78.425%
LTC:
http://tests.stockfishchess.org/tests/view/
59eba1670ebc590ccbb897b4
LLR: 2.95 (-2.94,2.94) [0.00,5.00]
Total: 59579 W: 7577 L: 7273 D: 44729
elo = 1.773 +- 1.391 LOS: 99.381%
bench:
5234652
IIvec [Sun, 15 Oct 2017 14:44:29 +0000 (16:44 +0200)]
Fix premature using of all available time in x/y TC
In x/y time controls there was a theoretical possibility
to use all available time few moves before the clock will
be updated with new time. This patch fixes that issue.
Tested at 60/15 time control:
LLR: 2.96 (-2.94,2.94) [-3.00,1.00]
Total: 113963 W: 20008 L: 20042 D: 73913
The test was done without adjudication rules!
Bench
5234652
Gian-Carlo Pascutto [Wed, 18 Oct 2017 08:25:12 +0000 (10:25 +0200)]
Don't filter root moves if MultiPV mode is enabled
A band-aid patch to workaround current TB code
limitations with multi PV.
Hopefully this will be removed after committing the
big update of TB impementation, now under discussion.
No functional change.
ceebo [Sun, 22 Oct 2017 05:00:46 +0000 (06:00 +0100)]
Add initiative to trace
No functional change
Joost VandeVondele [Wed, 11 Oct 2017 05:49:58 +0000 (07:49 +0200)]
Fix issue #1268
If the search is quit before skill.pick_best is called,
skill.best_move might be MOVE_NONE.
Ensure skill.best is always assigned anyhow.
Also retire the tricky best_move() and let the underlying
semantic to be clear and explicit.
No functional change.
Alain SAVARD [Sat, 7 Oct 2017 20:35:19 +0000 (16:35 -0400)]
Simplify bonus for bishop on long diagonal
Removing 2 conditions, and increase the ThreatbyPawn to compensate.
Passed STC
http://tests.stockfishchess.org/tests/view/
59dbde900ebc5916ff64be6d
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 14236 W: 2615 L: 2483 D: 9138
Passed LTC
http://tests.stockfishchess.org/tests/view/
59dc26470ebc5916ff64be92
LLR: 2.96 (-2.94,2.94) [-3.00,1.00]
Total: 16552 W: 2136 L: 2010 D: 12406
Bench:
5234652
Niklas Fiekas [Thu, 5 Oct 2017 09:00:01 +0000 (11:00 +0200)]
WLDEntryPiece -> WDLEntryPiece for consistency
No functional change.
Stéphane Nicolet [Sun, 1 Oct 2017 22:41:06 +0000 (00:41 +0200)]
Good bishops on the main diagonals
Bonus in midgame for bishops on long diagonals when the central squares are not occupied by pawns.
Author: ElbertoOne
Passed STC:
LLR: 2.96 (-2.94,2.94) [0.00,5.00]
Total: 10801 W: 1955 L: 1786 D: 7060
http://tests.stockfishchess.org/tests/view/
59cf5c1d0ebc5916ff64b9da
and LTC:
LLR: 2.97 (-2.94,2.94) [0.00,5.00]
Total: 83978 W: 10685 L: 10303 D: 62990
http://tests.stockfishchess.org/tests/view/
59cf6f6c0ebc5916ff64b9e4
Bench:
5620312
VoyagerOne [Sat, 30 Sep 2017 14:16:28 +0000 (10:16 -0400)]
Decrease reduction for exact PV nodes
STC:
LLR: 2.96 (-2.94,2.94) [0.00,5.00]
Total: 59004 W: 10621 L: 10249 D: 38134
LTC:
LLR: 2.95 (-2.94,2.94) [0.00,5.00]
Total: 25801 W: 3306 L: 3108 D: 19387
Bench:
5742466
Joost VandeVondele [Fri, 29 Sep 2017 14:39:12 +0000 (16:39 +0200)]
Measure nodes after search finished.
Only affects nmpsec in the multithreaded case.
No functional change.
GuardianRM [Thu, 21 Sep 2017 06:58:29 +0000 (09:58 +0300)]
Tweak statScore condition
The first change (ss->statScore >= 0) does nothing.
The second change ((ss-1)->statScore >= 0 ) has a massive change.
(ss-1)->statScore is not set until (ss-1) begins to apply LMR to moves.
So we now increase the reduction for bad quiets when our opponent is
running through the first captures and the hash move.
STC
LLR: 2.95 (-2.94,2.94) [0.00,4.00]
Total: 57762 W: 10533 L: 10181 D: 37048
LTC
LLR: 2.95 (-2.94,2.94) [0.00,5.00]
Total: 19973 W: 2662 L: 2480 D: 14831
Bench:
5037819
syzygy [Sat, 16 Sep 2017 19:49:29 +0000 (21:49 +0200)]
Let ss->ply denote the number of plies from the root to the current node
This patch lets ss->ply be equal to 0 at the root of the search.
Currently, the root has ss->ply == 1, which is less intuitive:
- Setting the rootNode bool has to check (ss-1)->ply == 0.
- All mate values are off by one: the code seems to assume that mated-in-0
is -VALUE_MATE, mate-1-in-ply is VALUE_MATE-1, mated-in-2-ply is VALUE_MATE+2, etc.
But the mate_in() and mated_in() functions are called with ss->ply, which is 1 in
at the root.
- The is_draw() function currently needs to explain why it has "ply - 1 > i" instead
of simply "ply > i".
- The ss->ply >= MAX_PLY tests in search() and qsearch() already assume that
ss->ply == 0 at the root. If we start at ss->ply == 1, it would make more sense to
go up to and including ss->ply == MAX_PLY, so stop at ss->ply > MAX_PLY. See also
the asserts testing for 0 <= ss->ply && ss->ply < MAX_PLY.
The reason for ss->ply == 1 at the root is the line "ss->ply = (ss-1)->ply + 1" at
the start for search() and qsearch(). By replacing this with "(ss+1)->ply = ss->ply + 1"
we keep ss->ply == 0 at the root. Note that search() already clears killers in (ss+2),
so there is no danger in accessing ss+1.
I have NOT changed pv[MAX_PLY + 1] to pv[MAX_PLY + 2] in search() and qsearch().
It seems to me that MAX_PLY + 1 is exactly right:
- MAX_PLY entries for ss->ply running from 0 to MAX_PLY-1, and 1 entry for the
final MOVE_NONE.
I have verified that mate scores are reported correctly. (They were already reported
correctly due to the extra ply being rounded down when converting to moves.)
The value of seldepth output to the user should probably not change, so I add 1 to it.
(Humans count from 1, computers from 0.)
A small optimisation I did not include: instead of setting ss->ply in every invocation
of search() and qsearch(), it could be set once for all plies at the start of
Thread::search(). This saves a couple of instructions per node.
No functional change (unless the search searches a branch MAX_PLY deep), so bench
does not change.
Stéphane Nicolet [Sat, 16 Sep 2017 12:07:41 +0000 (14:07 +0200)]
Score unopposed weak pawns only if majors
Do not use the opposed flag for scoring backward and isolated pawns
in pawns.cpp, instead give a S(5,25) bonus for each opponent unopposed
weak pawns when we have a rook or a queen on the board.
STC run stopped after 113188 games:
LLR: 1.63 (-2.94,2.94) [0.00,5.00]
Total: 113188 W: 20804 L: 20251 D: 72133
http://tests.stockfishchess.org/tests/view/
59b58e4d0ebc5916ff64b12e
LTC:
LLR: 2.95 (-2.94,2.94) [0.00,5.00]
Total: 66673 W: 8672 L: 8341 D: 49660
http://tests.stockfishchess.org/tests/view/
59b902580ebc5916ff64b231
This is Alain Savard's idea, just with a different bonus.
Original patch there:
green STC, http://tests.stockfishchess.org/tests/view/
597dcd2b0ebc5916ff64a09b
yellow LTC, http://tests.stockfishchess.org/tests/view/
597ea69e0ebc5916ff64a0e6
Bench:
6259498
IIvec [Wed, 6 Sep 2017 20:55:03 +0000 (22:55 +0200)]
Higher Move Overhead
This shoudl reduce time losses experienced by
users after new time management code.
Verified for no regression in very short TC (4sec + 0.1)
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 35262 W: 7426 L: 7331 D: 20505
Bench
5322108
ianfab [Wed, 6 Sep 2017 06:12:32 +0000 (08:12 +0200)]
Extend ShelterWeakness array by dimension isKingFile
Use different penalties for weaknesses in the pawn shelter
depending on whether it is on the king's file or not.
STC
LLR: 2.96 (-2.94,2.94) [0.00,5.00]
Total: 71617 W: 13471 L: 13034 D: 45112
LTC
LLR: 2.95 (-2.94,2.94) [0.00,5.00]
Total: 48708 W: 6463 L: 6187 D: 36058
Bench:
5322108
VoyagerOne [Mon, 4 Sep 2017 20:27:22 +0000 (16:27 -0400)]
Streamlline reduction based on movecount
Use MoveCount History only at quiet moves and simply reduce
reduction by one depth instead of increasing moveCount in formula.
STC:
LLR: 2.96 (-2.94,2.94) [0.00,4.00]
Total: 27511 W: 5171 L: 4919 D: 17421
LTC:
LLR: 2.96 (-2.94,2.94) [0.00,4.00]
Total: 92337 W: 12135 L: 11748 D: 68454
Bench:
6351176
syzygy [Sun, 3 Sep 2017 20:02:49 +0000 (22:02 +0200)]
Small simplication of see_ge()
Two simplifications:
- Remove the initialisation to 0 of occupied, which is now unnecessary.
- Remove the initial check for nextVictim == KING
If nextVictim == KING, then PieceValue[MG][nextVictim] will be 0, so that
balance >= threshold is true. So see_ge() returns true anyway.
No functional change.
Marco Costalba [Sun, 3 Sep 2017 07:25:02 +0000 (09:25 +0200)]
Travis CI: Make all warnings into errors
Compile with -Werror flag. To make debugging easier
also show compile ourput.
This flag is enabled only in Travis CI, not in the shipped
Makefile becuase we can't test on every possible platform.
Joost VandeVondele [Fri, 1 Sep 2017 19:24:32 +0000 (21:24 +0200)]
Remove unneeded compile options.
In light of issue #1232, a test was performed about the value of '-fno-exceptions' and a second one of the combination '-fno-exceptions -fno-rtti'. It turns out these options are can be removed without introducing slowdown.
STC for removing '-fno-exceptions'
LLR: 2.94 (-2.94,2.94) [-3.00,1.00]
Total: 13678 W: 2572 L: 2439 D: 8667
STC for removing '-fno-exceptions -fno-rtti' (current patch)
LLR: 2.96 (-2.94,2.94) [-3.00,1.00]
Total: 32557 W: 6074 L: 5973 D: 20510
No functional change.
syzygy [Sat, 2 Sep 2017 02:14:02 +0000 (04:14 +0200)]
Prevent Stockfish from exiting if DTZ table is not present
During TB initialisation, Stockfish checks for the presence of WDL
tables but not for the presence of DTZ tables. When attempting to probe
a DTZ table, it is therefore possible that the table is not present.
In that case, Stockfish should neither exit nor report an error.
To verify the bug:
$ ./stockfish
setoption name SyzygyTable value <path_to_WDL_dir>
position fen 8/8/4r3/4k3/8/1K2P3/3P4/6R1 w - -
go infinite
Could not mmap() /opt/tb/regular/KRPPvKR.rtbz
$
(On my system, the WDL tables are in one directory and the DTZ tables
in another. If they are in the same directory, it will be difficult
to trigger the bug.)
The fix is trivial: check the file descriptor/handle after opening
the file.
No functional change.
Marco Costalba [Thu, 31 Aug 2017 07:01:20 +0000 (09:01 +0200)]
Fix a warning with MSVC
warning C4244: '*=': conversion from 'double' to 'int', possible loss of data
No functional change.
Joost VandeVondele [Thu, 31 Aug 2017 20:11:09 +0000 (22:11 +0200)]
Multi-threaded search testing with valgrind
Also check with valgrind the multi-threaded search.
On top of the fix for issue #1227 (PR #1235).
No functional change.
Joost VandeVondele [Thu, 31 Aug 2017 07:34:32 +0000 (09:34 +0200)]
Fix uninitialized memory usage
After increasing the number of threads, the histories were not cleared,
resulting in uninitialized memory usage.
This patch fixes this by clearing threads histories in Thread c'tor as
is the idomatic way.
This fixes issue 1227
No functional change.
VoyagerOne [Tue, 29 Aug 2017 17:06:19 +0000 (13:06 -0400)]
Adjust moveCount history only at LMR
STC:
LLR: 3.32 (-2.94,2.94) [-3.00,1.00]
Total: 17584 W: 3277 L: 3131 D: 11176
LTC:
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 26412 W: 3447 L: 3334 D: 19631
Bench:
5417521
Joost VandeVondele [Fri, 25 Aug 2017 13:15:26 +0000 (15:15 +0200)]
Simplify away non-normal moves in SEE
credit goes to @mstembera for suggesting this approach.
SEE now deals with castling, promotion and en passant in a similar way.
passed STC
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 32902 W: 6079 L: 5979 D: 20844
passed LTC
LLR: 3.92 (-2.94,2.94) [-3.00,1.00]
Total: 110698 W: 14198 L: 14145 D: 82355
Bench:
5713905
Marco Costalba [Tue, 22 Aug 2017 09:58:44 +0000 (11:58 +0200)]
Appveyor: do a Debug and Release build
And set x86 and x64 platforms for real.
Currently this is broken and the same binary is compiled for all platforms.
This is becuase we use a custom build step. OTH the default
build step seems not compatible with cmake generated *sln file.
No functional change.
Joost VandeVondele [Fri, 18 Aug 2017 17:38:18 +0000 (19:38 +0200)]
Improve multi-threaded mate finding
If any thread found a 'mate in x' stop the search. Previously only
mainThread would do so. Requires the bestThread selection to be
adjusted to always prefer mate scores, even if the search depth is less.
I've tried to collect some data for this patch. On 30 cores, mate finding
seems 5-30% faster on average. It is not so easy to get numbers for this,
as the time to find a mate fluctuates significantly with multi-threaded runs,
so it is an average over 100 searches for the same position. Furthermore,
hash size and position make a difference as well.
Bench:
5965302
Stéphane Nicolet [Fri, 25 Aug 2017 21:50:11 +0000 (23:50 +0200)]
Count all weak squares in the king ring with a single popcount
Passed STC:
LLR: 2.95 (-2.94,2.94) [0.00,4.00]
Total: 26966 W: 4993 L: 4745 D: 17228
http://tests.stockfishchess.org/tests/view/
599e798a0ebc5916ff64aa8c
and LTC:
LLR: 2.95 (-2.94,2.94) [0.00,4.00]
Total: 39570 W: 5104 L: 4857 D: 29609
http://tests.stockfishchess.org/tests/view/
599ee5230ebc5916ff64aabe
Bench:
5965302
Joost VandeVondele [Wed, 23 Aug 2017 19:00:28 +0000 (21:00 +0200)]
Use moveCount history for reduction
Use less reduction for moves with larger moveCount if your
opponent did an unexpected (== high moveCount) move in the
previous ply... unexpected moves might need unexpected answers.
passed STC:
http://tests.stockfishchess.org/tests/view/
599f08cc0ebc5916ff64aace
LLR: 2.97 (-2.94,2.94) [0.00,5.00]
Total: 9638 W: 1889 L: 1720 D: 6029
passed LTC:
http://tests.stockfishchess.org/tests/view/
599f1e5c0ebc5916ff64aadc
LLR: 2.95 (-2.94,2.94) [0.00,5.00]
Total: 28308 W: 3742 L: 3533 D: 21033
Bench:
5747429
Stéphane Nicolet [Mon, 21 Aug 2017 16:59:24 +0000 (18:59 +0200)]
Avoid constructing an empty tuple in qsearch
Avoid constructing, passing as a parameter and binding a useless empty tuple of pointers in the qsearch move picker constructor.
Also reformat the scoring function in movepicker.cpp and do some cleaning in evaluate.cpp while there.
No functional change.
Marco Costalba [Sun, 20 Aug 2017 13:29:11 +0000 (15:29 +0200)]
Improve appeyor build
Check bench number and do not
hard-code *.cpp file names.
No functional change.
lucasart [Sun, 20 Aug 2017 11:59:46 +0000 (19:59 +0800)]
Restore safety margin of 60ms
What this patch does is:
* increase safety margin from 40ms to 60ms. It's worth noting that the previous
code not only used 60ms incompressible safety margin, but also an additional
buffer of 30ms for each "move to go".
* remove a whart, integrating the extra 10ms in Move Overhead value instead.
Additionally, this ensures that optimumtime doesn't become bigger than maximum
time after maximum time has been artificially discounted by 10ms. So it keeps
the code more logical.
Tested at 3 different time controls:
Standard 10+0.1
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 58008 W: 10674 L: 10617 D: 36717
Sudden death 16+0
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 59664 W: 10945 L: 10891 D: 37828
Tournament 40/10
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 16371 W: 3092 L: 2963 D: 10316
bench:
5479946
Marco Costalba [Sat, 19 Aug 2017 12:32:31 +0000 (14:32 +0200)]
Fix some Clang warnings
Found by Clang in extra verbose mode :-)
No functional change.
Marco Costalba [Tue, 15 Aug 2017 09:51:14 +0000 (02:51 -0700)]
Wide bench coverage
Add tests for:
- Positions with move list
- Chess960 positions
Now bench covers almost all cases, only few endgames
are still out of reach (verified with lcov)
It is a non functionality patch, but bench
changed because we added new test positions.
bench:
5479946
Marco Costalba [Tue, 15 Aug 2017 08:05:22 +0000 (01:05 -0700)]
Restore perft
Rewrite perft to be placed naturally inside new
bench code. In particular we don't have special
custom code to run perft anymore but perft is
just a new parameter of 'go' command.
So user API is now changed, old style command:
$perft 5
becomes
$go perft 4
No functional change.
Marco Costalba [Mon, 14 Aug 2017 17:41:04 +0000 (10:41 -0700)]
Rewrite benchmark
First step in improving bench to handle
arbitrary UCI commands so to test many
more code paths.
This first patch just set the new code
structure.
No functional change.
Marco Costalba [Fri, 18 Aug 2017 15:44:37 +0000 (08:44 -0700)]
Reformat time manager code
In particular clarify that 'sd'
parameter is used only in !movesToGo
case.
Verified with Ivan's check tool it is
equivalent to original code.
No functional change.
Joost VandeVondele [Fri, 18 Aug 2017 07:38:27 +0000 (09:38 +0200)]
Collect more corrections to optimum/maximum
The only call site of Time.maximum() corrected by 10.
Do this directly in remaining().
Ponder increased Time.optimum by 25% in init(). Idem.
Delete unused includes.
No functional change.
Marco Costalba [Wed, 16 Aug 2017 09:28:54 +0000 (02:28 -0700)]
Speed up Trevis CI
Avoid a couple of redundant rebuilds and compile
with 2 threads since travis gives 2vCPUs.
Also enable -O1 optimization for valgrind and
sanitizers, it should be safe withouth false
positives and it gives a very sensible speed
up, especially with valgrind.
The spee dup allow us to increase testing to
depth 10, useful for thread sanitizer.
No functional change.
Marco Costalba [Fri, 18 Aug 2017 09:02:35 +0000 (02:02 -0700)]
Clarify stats range
Current update formula ensures that the
possible value range is [-32 * D, 32 * D].
So we never overflow if abs(32 * D) < INT16_MAX
Thanks to Joost and mstembera to clarify this.
No functional change.
IIvec [Fri, 7 Oct 2016 16:12:19 +0000 (18:12 +0200)]
Time management simplification
STC (http://tests.stockfishchess.org/tests/view/
598188a40ebc5916ff64a21b):
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 25363 W: 4658 L: 4545 D: 16160
LTC (http://tests.stockfishchess.org/tests/view/
5981d59a0ebc5916ff64a229):
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 75356 W: 9690 L: 9640 D: 56026
40/10 TC (http://tests.stockfishchess.org/tests/view/
5980c5780ebc5916ff64a1ed):
LLR: 2.96 (-2.94,2.94) [-3.00,1.00]
Total: 19377 W: 3650 L: 3526 D: 12201
15+0 TC (http://tests.stockfishchess.org/tests/view/
5982cb730ebc5916ff64a25d):
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 5913 W: 1217 L: 1069 D: 3627
This time management handles base time and movestogo cases separatelly. One can test one case without affecting the other. Also, increment usage can be tested separately without (necessarily) affecting sudden death or x moves in y seconds performance.
On stable machines there are no time losses on 0.1+0.001 time control (tested on i7 + Windows 10 platform).
Bench
5608839
Marco Costalba [Sun, 13 Aug 2017 18:01:26 +0000 (11:01 -0700)]
Fix involuntary conversions of ExtMove to Move
The trick is to create an ambiguity for the
compiler in case an unwanted conversion to
Move is attempted like in:
ExtMove m1{Move(17),4}, m2{Move(4),17};
std::cout << (m1 < m2) << std::endl; // 1
std::cout << (m1 > m2) << std::endl; // 1(!)
This fixes issue #1204
No functional change.
Marco Costalba [Thu, 17 Aug 2017 08:47:32 +0000 (01:47 -0700)]
Unify stats update()
Now that is a bit bigger makes sense to
unify some duplicated code.
No functional change.
lucasart [Wed, 9 Aug 2017 11:35:05 +0000 (19:35 +0800)]
Use int16_t in History values
Reduces memory footprint by ~1.2MB (per thread).
Strong pressure: small but mesurable gain
LLR: 2.96 (-2.94,2.94) [0.00,4.00]
Total: 258430 W: 46977 L: 45943 D: 165510
Low pressure: no regression
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 73542 W: 13058 L: 13026 D: 47458
Strong pressure + LTC: elo gain confirmed
LLR: 2.96 (-2.94,2.94) [0.00,4.00]
Total: 31489 W: 4532 L: 4295 D: 22662
Tested for crashing on overflow and after 70K
games at STC we have only 4 time losses,
possible candidate for an overflow.
No functional change.
Marco Costalba [Mon, 14 Aug 2017 16:12:16 +0000 (09:12 -0700)]
Fix incorrect StateInfo
We use Position::set() to set root position across
threads. But there are some StateInfo fields (previous,
pliesFromNull, capturedPiece) that cannot be deduced
from a fen string, so set() clears them and to not lose
the info we need to backup and later restore setupStates->back().
Note that setupStates is shared by threads but is accessed
in read-only mode.
This fixes regression introduced by
df6cb446eaf21
Tested with 3 threads at STC:
LLR: 2.95 (-2.94,2.94) [-4.00,0.00]
Total: 14436 W: 2304 L: 2196 D: 9936
Bench:
5608839
Marco Costalba [Sun, 13 Aug 2017 12:33:25 +0000 (05:33 -0700)]
Run clang-tidy 'modernize'
Some warnings after a run of:
$ clang-tidy-3.8 -checks='modernize-*' *.cpp syzygy/*.cpp -header-filter=.* -- -std=c++11
I have not fixed all suggestions, for instance I still prefer
to declare the type instead of a spread use of 'auto'. I also
perfer good old 'typedef' to the new 'using' form.
I have not fixed some warnings in the last functions of
syzygy code because those are still the original functions
and need to be completely rewritten anyhow.
Thanks to erbsenzaehler for the original idea.
No functional change.
Marco Costalba [Sun, 13 Aug 2017 06:58:31 +0000 (23:58 -0700)]
Thread code reformat
Simplify out low level sync stuff (mutex
and friends) and avoid to use them directly
in many functions.
Also some renaming and better comment while
there.
No functional change.
Marco Costalba [Sun, 13 Aug 2017 06:38:39 +0000 (23:38 -0700)]
Retire States global variable
And other small touches in uci.cpp
No functional change.
tthsqe12 [Sat, 12 Aug 2017 08:50:38 +0000 (10:50 +0200)]
Fix the handling of opposite bishops in KXK endgame evaluation
The case of three or more bishops against a long king must look at all of the
bishops and not just the first two in the piece lists. This patch makes sure
that the position is treated as a win when there are bishops on opposite
colors. This functional change is very small because bench remains the same.
LLR: 2.95 (-2.94,2.94) [-4.00,0.00]
Total: 24249 W: 4349 L: 4275 D: 15625
http://tests.stockfishchess.org/tests/view/
598186530ebc5916ff64a218
Bench:
5608839
Joost VandeVondele [Fri, 4 Aug 2017 17:48:07 +0000 (19:48 +0200)]
Simplify finished search in ponder/infinite mode.
In this rare case (e.g. go infinite on a stalemate),
just spin till ponderhit/stop comes.
The Thread::wait() is a renmant of the old YBWC
code, today with lazy SMP, threads don't need to
wait when outside of their idle loop.
No functional change.
Marco Costalba [Thu, 10 Aug 2017 19:32:50 +0000 (12:32 -0700)]
Re-apply the fix for Limits::ponder race
But this time correctly set Threads.ponder
We avoid using 'limits' for passing pondering
flag because we don't want to have 2 ponder
variables in search scope: Search::Limits.ponder
and Threads.ponder. This would be confusing also
because limits.ponder is set at the beginning of
the search and never changes, instead Threads.ponder
can change value asynchronously during search.
No functional change.
Marco Costalba [Thu, 10 Aug 2017 17:57:28 +0000 (10:57 -0700)]
Revert "Fix a race on Limits::ponder"
This reverts commit
5410424e3d036b43715c7989aa99e449cdcde18e.
After the commit pondering is broken, so revert for now. I will
resubmit with a proper fix.
The issue is mine, Joost original code is correct.
No functional change.
Joost VandeVondele [Thu, 27 Jul 2017 06:31:25 +0000 (08:31 +0200)]
Fix a race on Limits::ponder
Limits::ponder was used as a signal between uci and search threads,
but is not an atomic variable, leading to the following race as
flagged by a sanitized binary.
Expect input:
```
spawn ./stockfish
send "uci\n"
expect "uciok"
send "setoption name Ponder value true\n"
send "go wtime 4000 btime 4000\n"
expect "bestmove"
send "position startpos e2e4 d7d5\n"
send "go wtime 4000 btime 4000 ponder\n"
sleep 0.01
send "ponderhit\n"
expect "bestmove"
send "quit\n"
expect eof
```
Race:
```
WARNING: ThreadSanitizer: data race (pid=7191)
Read of size 4 at 0x0000005c2260 by thread T1:
Previous write of size 4 at 0x0000005c2260 by main thread:
Location is global 'Search::Limits' of size 88 at 0x0000005c2220 (stockfish+0x0000005c2260)
```
The reason of teh race is that ponder is not just set in UCI go()
assignment but also is signaled by an async ponderhit in uci.cpp:
else if (token == "ponderhit")
Search::Limits.ponder = 0; // Switch to normal search
The fix is to add an atomic bool to the threads structure to
signal the ponder status, letting Search::Limits to reflect just
what was passed to 'go'.
No functional change.
Marco Costalba [Sun, 6 Aug 2017 11:43:02 +0000 (04:43 -0700)]
Fix some races and clarify the code
Better split code that should be run at
startup from code run at ucinewgame. Also
fix several races when 'bench', 'perft' and
'ucinewgame' are sent just after 'bestomve'
from the engine threads are still running.
Also use a specific UI thread instead of
main thread when setting up the Position
object used by UI uci loop. This fixes a
race when sending 'eval' command while searching.
We accept a race on 'setoption' to allow the
GUI to change an option while engine is searching
withouth stalling the pipe. Note that changing an
option while searchingg is anyhow not mandated by
UCI protocol.
No functional change.
AndyGrant [Thu, 10 Aug 2017 01:43:30 +0000 (21:43 -0400)]
Make variable naming consistent
moved_piece is the only variable in search not using camel case
Joost VandeVondele [Wed, 9 Aug 2017 12:04:59 +0000 (14:04 +0200)]
Unify scoring functions in MovePicker
No functional change.
Joost VandeVondele [Fri, 30 Jun 2017 15:20:00 +0000 (17:20 +0200)]
Remove Stack/thread dependence in movepick
as a lower level routine, movepicker should not depend on the
search stack or the thread class, removing a circular dependency.
Instead of copying the search stack into the movepicker object,
as well as accessing the thread class for one of the histories,
pass the required fields explicitly to the constructor (removing
the need for thread.h and implicitly search.h in movepick.cpp).
The signature is thus longer, but more explicit:
Also some renaming of histories structures while there.
passed STC [-3,1], suggesting a small elo impact:
LLR: 3.13 (-2.94,2.94) [-3.00,1.00]
Total: 381053 W: 68071 L: 68551 D: 244431
elo = -0.438 +- 0.660 LOS: 9.7%
No functional change.
snicolet [Wed, 2 Aug 2017 01:40:27 +0000 (18:40 -0700)]
Tweak connected pawns seed[] array values
Raise a little bit the values in the connected pawns seed[] array.
STC:
LLR: 2.96 (-2.94,2.94) [0.00,4.00]
Total: 99033 W: 17939 L: 17448 D: 63646
http://tests.stockfishchess.org/tests/view/
597355630ebc5916ff649e3e
LTC:
LLR: 2.95 (-2.94,2.94) [0.00,4.00]
Total: 48044 W: 6371 L: 6099 D: 35574
http://tests.stockfishchess.org/tests/view/
597596610ebc5916ff649eba
Bench:
5608839
Closes #1182
Rocky640 [Wed, 2 Aug 2017 01:36:33 +0000 (18:36 -0700)]
Rework the "unsupported" penalty into a "supported" bonus
A pawn (according to all the searched positions of a bench run) is not supported 85% of the time,
(in current master it is either isolated, backward or "unsupported").
So it made sense to try moving the S(17, 8) "unsupported" penalty value into the base pawn value hoping for a more representative pawn value, and accordingly
a) adjust backward and isolated so that they stay more or less the same as master
b) increase the mg connected bonus in the supported case by S(17, 0) and let the Connected formula find a suitable eg value according to rank.
Tested as a simplification SPRT(-3, 1)
Passed STC
http://tests.stockfishchess.org/tests/view/
5970dbd30ebc5916ff649dd6
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 19613 W: 3663 L: 3540 D: 12410
Passed LTC
http://tests.stockfishchess.org/tests/view/
597137780ebc5916ff649de3
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 24721 W: 3306 L: 3191 D: 18224
Bench:
5581946
Closes #1179
VoyagerOne [Thu, 27 Jul 2017 09:14:18 +0000 (02:14 -0700)]
Remove redundant if-statements
No functional change
Closes #1173
mstembera [Wed, 5 Jul 2017 20:05:29 +0000 (13:05 -0700)]
Tuned PSQT using a custom tuner.
bench:
5878420
Closes #1177
VoyagerOne [Mon, 24 Jul 2017 00:25:23 +0000 (17:25 -0700)]
Simplify aspiration window
Don't modify alpha window on fail-high
Bench:
5875983
Closes #1172
Joost VandeVondele [Sat, 15 Jul 2017 08:25:35 +0000 (10:25 +0200)]
Faster travis checks
in the last month a couple of timeouts have been seen in travis valgrind testing, leading to undesired false positives. The precise cause of this is unclear: a normal valgrind instrumented run is about 6min, the timeout is 10min. Either there are rare hangs (not reproduced locally), or maybe the actual runtime fluctuates on the travis infrastructure (which uses VMs on AWS as far as I know). This patch leads to roughly a 2x speedup of the instrumented testing by reducing the depth from 10 to 9. If timeouts persist, it needs further analysis.
No functional change.
Closes #1171
Marco Costalba [Sun, 9 Jul 2017 09:45:31 +0000 (11:45 +0200)]
Move game_phase() to material.cpp
For some reason, although game phase is used
only in material, it is computed in Position.
Move computation to material, where it belongs,
and remove the useless call chain.
No functional change.
Joona Kiiski [Thu, 13 Jul 2017 23:36:27 +0000 (16:36 -0700)]
Revert "Remove questionable gcc flags from profile-build"
This reverts commit
0371a8f8c4a043cb3e7d08b5b8e7d08d49f28324.
joergoster [Thu, 13 Jul 2017 23:30:03 +0000 (16:30 -0700)]
Provide selective search depth info for each pv move
No functional change
Closes #1166
Joost VandeVondele [Thu, 13 Jul 2017 23:07:19 +0000 (16:07 -0700)]
Move stop signal to Threads
Instead of having Signals in the search namespace,
make the stop variables part of the Threads structure.
This moves more of the shared (atomic) variables towards
the thread-related structures, making their role more clear.
No functional change
Closes #1149
Joona Kiiski [Sat, 8 Jul 2017 21:19:03 +0000 (14:19 -0700)]
Remove questionable gcc flags from profile-build
Optimization options for official stockfish should be
consistent, easy, future proof and simple.
We don't want to optimize for any specific version of gcc
No functional change
Closes #1165
GuardianRM [Sat, 8 Jul 2017 21:07:25 +0000 (14:07 -0700)]
Queen vs. Minors imbalance
Addition of correction values in case of Imbalance of queens,
depending on the number of light pieces on the side without a queen.
Passed patch:
STC:
LLR: 2.95 (-2.94,2.94) [0.00,5.00]
Total: 29036 W: 5379 L: 5130 D: 18527
LTC:
LLR: 2.96 (-2.94,2.94) [0.00,5.00]
Total: 13680 W: 1836 L: 1674 D: 10170
Bench:
6258930
Closes #1155
Marco Costalba [Sun, 2 Jul 2017 10:10:50 +0000 (03:10 -0700)]
Don't uselessy share rootDepth
It is not needed becuase the only case is a real special
one (bench on depth with many threads) and can be easily
rewritten to avoid sharing rootDepth.
Verified with ThreadSanitizer.
No functional change.
Closes #1159
Marco Costalba [Sun, 2 Jul 2017 11:39:58 +0000 (13:39 +0200)]
Fix some warnings with clang static analyzer
Only one remains (also in tbprobe.cpp), but is bougus.
As a side note, tbprobe.cpp is almost clean, only the last 3
functions probe_wdl(), root_probe() and root_probe_wdl()
are still the original ones and are quite hacky.
Somewhere in the future we will reformat also the last 3
ones. The reason why has not been done before it is because
these functions are really wrong by design and should be
rewritten entirely, not only reformatted.
No functional change.
Closes #1160
Marco Costalba [Sat, 1 Jul 2017 05:58:38 +0000 (07:58 +0200)]
Indentation fix in index()
No functional change.
Closes #1158
Alain SAVARD [Fri, 23 Jun 2017 04:03:58 +0000 (00:03 -0400)]
Tidy up
No functional change
Closes #1148
mstembera [Thu, 29 Jun 2017 00:11:17 +0000 (17:11 -0700)]
Magic::index()
Make magic_index() a member of Magic since it uses all it's members
and keep us from having to pass the function pointer around to
init_magics().
No functional change
Closes #1146
Joost VandeVondele [Fri, 23 Jun 2017 16:23:27 +0000 (18:23 +0200)]
Remove race suppression.
Pull #1134 fixed another race, so that can be removed from the thread sanitizer suppressions.
No functional change.
Closes #1150
Marco Costalba [Sat, 24 Jun 2017 05:15:46 +0000 (07:15 +0200)]
Only main thread checks time
The main change of the patch is that now time check
is done only by main thread. In the past, before lazy
SMP, we needed all the threds to check for available
time because main thread could have been blocked on
a split point, now this is no more the case and main
thread can do the job alone, greatly simplifying the logic.
Verified for regression testing on STC with 7 threads:
LLR: 2.96 (-2.94,2.94) [-3.00,1.00]
Total: 11895 W: 1741 L: 1608 D: 8546
No functional change.
Closes #1152
Marco Costalba [Sat, 24 Jun 2017 10:36:07 +0000 (12:36 +0200)]
Simplify pos_is_ok()
Now we don't need anymore the tricky pointer to
show the failed test. Added some few tests too.
Also small rename in see_ge() while there.
No functional change
Closes #1151
VoyagerOne [Wed, 21 Jun 2017 21:05:14 +0000 (14:05 -0700)]
Increase reduction if tt-move is a capture
The idea is that chances are the tt-move is best and will be difficult to raise alpha when playing a quiet move.
STC:
LLR: 2.95 (-2.94,2.94) [0.00,5.00]
Total: 7582 W: 1415 L: 1259 D: 4908
LTC:
LLR: 2.97 (-2.94,2.94) [0.00,5.00]
Total: 59553 W: 7885 L: 7573 D: 44095
Bench:
5725676
Closes #1147
snicolet [Wed, 21 Jun 2017 21:01:59 +0000 (14:01 -0700)]
Improve readability of evaluation functions
This patch puts the evaluation helper functions inside EvalInfo struct, which simplifies a bit their signature and (most importantly, IMHO) makes their C++ code much cleaner and simpler to read (by removing the "ei." qualifiers all around in evaluate.cpp).
Also rename the EvalInfo struct into Evaluation class to get a natural invocation v = Evaluation(p).value() to evaluation position p.
The downside is an increase of 20 lines in evaluate.cpp (for the prototypes of the helper functions). The upsides are better readability and a speed-up of 0.6% (by generating all the helpers for the NO_TRACE case together, which helps the instruction cache).
No functional change
Closes #1135
VoyagerOne [Sun, 18 Jun 2017 19:03:18 +0000 (15:03 -0400)]
Update Top CPU - Bench:
6599721
Closes #1145
Joona Kiiski [Wed, 21 Jun 2017 20:44:05 +0000 (13:44 -0700)]
Revert "Prefetch earlier in qsearch()"
This reverts commit
b73016bb41d4c2fad3126b2e0018d71a36e78331.
No functional change
Closes #1144
Joost VandeVondele [Wed, 21 Jun 2017 20:36:53 +0000 (13:36 -0700)]
Fix four data races.
the nodes, tbHits, rootDepth and lastInfoTime variables are read by multiple threads, but not declared atomic, leading to data races as found by -fsanitize=thread. This patch fixes this issue. It is based on top of the CI-threading branch (PR #1129), and should fix the corresponding CI error messages.
The patch passed an STC check for no regression:
http://tests.stockfishchess.org/tests/view/
5925d5590ebc59035df34b9f
LLR: 2.96 (-2.94,2.94) [-3.00,1.00]
Total: 169597 W: 29938 L: 30066 D: 109593
Whereas rootDepth and lastInfoTime are not performance critical, nodes and tbHits are. Indeed, an earlier version using relaxed atomic updates on the latter two variables failed STC testing (http://tests.stockfishchess.org/tests/view/
592001700ebc59035df34924), which can be shown to be due to x86-32 (http://tests.stockfishchess.org/tests/view/
592330ac0ebc59035df34a89). Indeed, the latter have no instruction to atomically update a 64bit variable. The proposed solution thus uses a variable in Position that is accessed only by one thread, which is copied every few thousand nodes to the shared variable in Thread.
No functional change.
Closes #1130
Closes #1129
Alain SAVARD [Sun, 11 Jun 2017 21:31:15 +0000 (17:31 -0400)]
Misc coding style fixes
a few comment and blank fixes.
No functional change
Closes #1141
snicolet [Sat, 17 Jun 2017 02:52:38 +0000 (19:52 -0700)]
Prefetch earlier in qsearch()
Closes #1139
Marco Costalba [Sun, 4 Jun 2017 09:03:23 +0000 (11:03 +0200)]
Better naming in endgame code
And small clean-up of magic bitboards code.
No functional change.
Closes #1138
Brian Sheppard [Sat, 17 Jun 2017 02:27:36 +0000 (19:27 -0700)]
Move depth calculation in probCut
The change passed an STC regression:
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 59350 W: 10793 L: 10738 D: 37819
I verified that there was no change in performance on my machine, but of course YMMV:
Results for 40 tests for each version:
Base Test Diff
Mean
2014338 2016121 -1783
StDev 62655 63441 3860
p-value: 0.678
speedup: 0.001
No functional change.
Closes #1137
Joost VandeVondele [Tue, 6 Jun 2017 07:48:57 +0000 (09:48 +0200)]
Call TT.new_search() earlier.
TT.new_search() was being called by mainThread in Thread::search(). However, mainThread is the last to start searching, and helper threads could reach a measured rootDepth 10 (on 64 cores) before mainThread increments the TT generation. Fixed by moving the call to MaintThread::search() before helper threads start searching.
No functional change.
Closes #1134
mstembera [Tue, 6 Jun 2017 17:20:43 +0000 (10:20 -0700)]
Reordering magic data
Gather all magic relevant data into a struct.
This changes memory layout putting everything necessary for processing a single square
in the same memory location thus speeding up access.
Original patch by @snicolet
No functional change.
Closes #1127
Closes #1128
atumanian [Tue, 6 Jun 2017 17:13:10 +0000 (10:13 -0700)]
Don't score as an immediate draw 2-fold repetitions of the root position
In the current version a search stops when the current position is the same as
any position earlier in the search stack,
including the root position but excluding positions before the root.
The new version makes an exception for repeating the root position.
This gives correct scores for moves in the MultiPV > 1 mode.
Fixes #948 (see it for the detailed description of the bug).
LTC: http://tests.stockfishchess.org/tests/view/
587910bc0ebc5915193f754b
ELO: 0.38 +-1.7 (95%) LOS: 66.8%
Total: 40000 W: 5166 L: 5122 D: 29712
STC: http://tests.stockfishchess.org/tests/view/
5922e6230ebc59035df34a50
LLR: 2.94 (-2.94,2.94) [-3.00,1.00]
Total: 94622 W: 17059 L: 17064 D: 60499
LTC: http://tests.stockfishchess.org/tests/view/
59273a000ebc59035df34c03
LLR: 2.96 (-2.94,2.94) [-3.00,1.00]
Total: 61259 W: 7965 L: 7897 D: 45397
Bench:
6599721
Closes #1126
Joost VandeVondele [Sun, 28 May 2017 07:58:52 +0000 (09:58 +0200)]
use auto& for histories
No functional change.
Closes #1113
Marco Costalba [Fri, 26 May 2017 06:42:50 +0000 (08:42 +0200)]
History code rewrite (#1122)
Rearrange and rename all history heuristic code. Naming
is now based on chessprogramming.wikispaces.com conventions
and the relations among the various heuristics are now more
clear and consistent.
No functional change.
Nathan Rugg [Tue, 23 May 2017 06:56:49 +0000 (14:56 +0800)]
Changed spelling back to "Bishops" in eval output
No functional change.
Closes #1124
VoyagerOne [Mon, 22 May 2017 01:25:20 +0000 (18:25 -0700)]
Evasion Pruning Tweak
Use moveCount to decide when to prune for evasion pruning
STC:
LLR: 2.95 (-2.94,2.94) [0.00,5.00]
Total: 24476 W: 4518 L: 4289 D: 15669
LTC:
LLR: 2.96 (-2.94,2.94) [0.00,5.00]
Total: 18362 W: 2476 L: 2298 D: 13588
Bench:
6469989
Closes #1120
snicolet [Thu, 18 May 2017 01:23:07 +0000 (18:23 -0700)]
Do check analysis later in the game
The previous patch has added a fraction of the king danger score to the
endgame score of the tapered eval, so it seems natural to perform the
king danger computation later in the endgame.
With this patch we extend the limit of such check analysis down to the
material of Rook+Knight, when we have at least two pieces attacking the
opponent king zone.
Passed STC:
LLR: 2.95 (-2.94,2.94) [0.00,5.00]
Total: 7446 W: 1409 L: 1253 D: 4784
http://tests.stockfishchess.org/tests/view/
591c097c0ebc59035df3477c
and LTC:
LLR: 2.96 (-2.94,2.94) [0.00,5.00]
Total: 14234 W: 1946 L: 1781 D: 10507
http://tests.stockfishchess.org/tests/view/
591c24f10ebc59035df3478c
Bench:
5975183
Closes #1121
snicolet [Thu, 18 May 2017 01:19:47 +0000 (18:19 -0700)]
Use a fraction of king danger in endgame score
When SF has an attack on the opponent king in one flank, the huge
midgame -> endgame gradient of the tapered eval prevents us to properly
evaluate neutral exchanges on the other flank as the current king
danger score is a pure midgame term. This may affect SF's ability to
switch to defense in some positions. We add a small contribution
of the king danger to the endgame score to limit this
effect.
Again suggested in the following forum thread:
https://groups.google.com/forum/?fromgroups=#!topic/fishcooking/xrUCQ7b0ObE
Passed STC:
LLR: 2.96 (-2.94,2.94) [0.00,5.00]
Total: 12719 W: 2371 L: 2192 D: 8156
http://tests.stockfishchess.org/tests/view/
5919761a0ebc59035df3468f
And LTC:
LLR: 2.95 (-2.94,2.94) [0.00,5.00]
Total: 31293 W: 4194 L: 3974 D: 23125
http://tests.stockfishchess.org/tests/view/
591980450ebc59035df34695
Bench:
5961548
Closes #1118
Joost VandeVondele [Thu, 18 May 2017 01:15:01 +0000 (18:15 -0700)]
Fix memory access in Search::clear()
Fixes a bug in Search::clear, where the filling of CounterMoveStats&, overwrote (currently presumably unused) memory because sizeof(cm) returns the size in bytes, whereas elements was needed.
No functional change
Closes #1119