1
0
Fork 0
mirror of https://github.com/sockspls/badfish synced 2025-05-01 09:13:08 +00:00
BadFish/src
Michael Chaly d9ec82e743 Adjust stand pat in qsearch on pv nodes
Instead of immediately returning a fail high do this only at non-pv nodes, for
pv nodes adjust bestValue to value between alpha and beta and continue
searching. Idea is to do it the same way as it's done in search where we don't
return positive beta cutoffs after ttHits / zero window search at PvNodes and
instead fully search lines.

Passed STC:
https://tests.stockfishchess.org/tests/view/65739b0af09ce1261f122f33
LLR: 2.94 (-2.94,2.94) <0.00,2.00>
Total: 189216 W: 48142 L: 47598 D: 93476
Ptnml(0-2): 584, 22463, 48051, 22845, 665

Passed LTC:
https://tests.stockfishchess.org/tests/view/657701214d789acf40aac194
LLR: 2.94 (-2.94,2.94) <0.50,2.50>
Total: 82506 W: 20689 L: 20269 D: 41548
Ptnml(0-2): 56, 9236, 22268, 9618, 75

Two issues had to be resolved:
    - in rare cases it set alpha to the same value as beta and thus broke some asserts;
    - messed up with returning tb win values.

      Fix passed non-regression LTC vs this patch:
      https://tests.stockfishchess.org/tests/view/6578113b4d789acf40aad544
      LLR: 2.96 (-2.94,2.94) <-1.75,0.25>
      Total: 277308 W: 68839 L: 68880 D: 139589
      Ptnml(0-2): 167, 31580, 75212, 31517, 178

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

Bench: 1069503

Co-Authored-By: Muzhen Gaming <61100393+XInTheDark@users.noreply.github.com>
Co-Authored-By: Shahin M. Shahin <41402573+peregrineshahin@users.noreply.github.com>
Co-Authored-By: fffelix-huang <72808219+fffelix-huang@users.noreply.github.com>
2023-12-19 18:22:10 +01:00
..
incbin Change mode of incbin.h 2023-03-14 08:23:50 +01:00
nnue Cleanup comments and some code reorg. 2023-10-24 17:43:05 +02:00
syzygy remove blank line between function and it's description 2023-10-23 20:39:48 +02:00
benchmark.cpp remove blank line between function and it's description 2023-10-23 20:39:48 +02:00
benchmark.h add clang-format 2023-10-22 16:06:27 +02:00
bitboard.cpp remove blank line between function and it's description 2023-10-23 20:39:48 +02:00
bitboard.h Small formatting improvements 2023-10-24 17:42:13 +02:00
evaluate.cpp Rewarding Quiet Moves that Enable Razoring 2023-10-27 17:32:19 +02:00
evaluate.h add clang-format 2023-10-22 16:06:27 +02:00
main.cpp add clang-format 2023-10-22 16:06:27 +02:00
Makefile Add loongarch64 support 2023-12-14 18:41:53 +01:00
misc.cpp Reformat some comments 2023-11-20 19:10:38 +01:00
misc.h remove blank line between function and it's description 2023-10-23 20:39:48 +02:00
movegen.cpp Simplify promotion move generation 2023-12-02 11:38:18 +01:00
movegen.h add clang-format 2023-10-22 16:06:27 +02:00
movepick.cpp Remove recaptures stage in qsearch 2023-12-02 11:45:38 +01:00
movepick.h Remove recaptures stage in qsearch 2023-12-02 11:45:38 +01:00
position.cpp Reformat some comments 2023-11-20 19:10:38 +01:00
position.h Introduce pawn structure based history 2023-10-27 17:24:25 +02:00
search.cpp Adjust stand pat in qsearch on pv nodes 2023-12-19 18:22:10 +01:00
search.h remove blank line between function and it's description 2023-10-23 20:39:48 +02:00
thread.cpp Introduce pawn structure based history 2023-10-27 17:24:25 +02:00
thread.h remove outdated comment 2023-10-27 18:35:52 +02:00
thread_win32_osx.h add clang-format 2023-10-22 16:06:27 +02:00
timeman.cpp Remove SlowMover Option 2023-12-14 18:44:46 +01:00
timeman.h remove blank line between function and it's description 2023-10-23 20:39:48 +02:00
tt.cpp remove blank line between function and it's description 2023-10-23 20:39:48 +02:00
tt.h remove blank line between function and it's description 2023-10-23 20:39:48 +02:00
tune.cpp add clang-format 2023-10-22 16:06:27 +02:00
tune.h add clang-format 2023-10-22 16:06:27 +02:00
types.h Fix TB score output in UCI without using TB 2023-12-14 18:35:38 +01:00
uci.cpp Fix TB score output in UCI without using TB 2023-12-14 18:35:38 +01:00
uci.h Reformat some comments 2023-11-20 19:10:38 +01:00
ucioption.cpp Remove UCI_AnalyseMode Option 2023-12-14 18:50:51 +01:00