1
0
Fork 0
mirror of https://github.com/sockspls/badfish synced 2025-04-30 08:43:09 +00:00
BadFish/src
protonspring cb4bda0f49 Simplify the backward pawns code
The two lines of code in the patch seem to be just as good as master.

1. We now only look at the current square to see if it is currently backward,
whereas master looks there AND further ahead in the current file (master would
declare a pawn "backward" even though it could still safely advance a little).
This simplification allows us to avoid the use of the difficult logic with
`backmost_sq(Us, neighbours | stoppers)`.

2. The condition `relative_rank(Us,s) < RANK_5` is simplified away.

Passed STC:
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 68132 W: 14025 L: 13992 D: 40115
http://tests.stockfishchess.org/tests/view/5aedc97a0ebc5902a4099fd6

Passed LTC:
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 23789 W: 3643 L: 3527 D: 16619
http://tests.stockfishchess.org/tests/view/5aee4f970ebc5902a409a03a

Ideas for further work:

• The new code flags some pawns on the 5th rank as backward, which was not the
case in the old master. So maybe we should test a version with that included?

• Further tweaks of the backward condition with [0..5] bounds?

Closes https://github.com/official-stockfish/Stockfish/pull/1583

Bench: 5122789
2018-05-06 09:44:14 +02:00
..
syzygy Tablebases root ranking 2018-04-18 18:46:24 +02:00
benchmark.cpp New Year 2018 2018-01-01 13:18:10 +01:00
bitbase.cpp Mark all compile-time constants as constexpr. 2018-03-18 23:48:16 +01:00
bitboard.cpp Some small changes 2018-04-01 02:32:55 +02:00
bitboard.h Correct a bug introduced by Stéphane in the previous patch. 2018-05-02 13:38:00 +02:00
endgame.cpp Simplify KBPKB endgame with opposite bishops 2018-04-01 02:19:42 +02:00
endgame.h New Year 2018 2018-01-01 13:18:10 +01:00
evaluate.cpp Penalty for bad bishop with blocked central files 2018-05-01 07:12:27 +02:00
evaluate.h Use per-thread dynamic contempt 2018-03-30 10:48:57 +02:00
main.cpp Further documentation and coding style on TB code 2018-04-12 09:37:18 +02:00
Makefile Fix 'make strip' for mingw. 2018-04-29 06:53:51 +02:00
material.cpp Always scale using pawn contribution 2018-04-29 07:26:25 +02:00
material.h New Year 2018 2018-01-01 13:18:10 +01:00
misc.cpp Fix an MSVC 2017 error and warnings. 2018-03-16 22:37:03 +01:00
misc.h Switch time management to 64 bits 2018-03-27 16:25:41 +02:00
movegen.cpp Fix a few minor code style inconsistencies 2018-03-21 01:35:05 +01:00
movegen.h New Year 2018 2018-01-01 13:18:10 +01:00
movepick.cpp Remove template W param 2018-04-23 08:46:32 +02:00
movepick.h Update various comments 2018-04-29 06:48:18 +02:00
pawns.cpp Simplify the backward pawns code 2018-05-06 09:44:14 +02:00
pawns.h Simplify the ShelterStrength[] array 2018-04-23 09:49:05 +02:00
position.cpp Tablebases root ranking 2018-04-18 18:46:24 +02:00
position.h Tablebases root ranking 2018-04-18 18:46:24 +02:00
psqt.cpp Mark all compile-time constants as constexpr. 2018-03-18 23:48:16 +01:00
search.cpp Simplifiy IID condition 2018-04-29 06:59:17 +02:00
search.h Tablebases root ranking 2018-04-18 18:46:24 +02:00
thread.cpp Update various comments 2018-04-29 06:48:18 +02:00
thread.h Tablebases root ranking 2018-04-18 18:46:24 +02:00
thread_win32.h New Year 2018 2018-01-01 13:18:10 +01:00
timeman.cpp Switch time management to 64 bits 2018-03-27 16:25:41 +02:00
timeman.h Document Elo impact of various parts of search 2018-04-01 03:21:45 +02:00
tt.cpp New Year 2018 2018-01-01 13:18:10 +01:00
tt.h Mark all compile-time constants as constexpr. 2018-03-18 23:48:16 +01:00
types.h Always scale using pawn contribution 2018-04-29 07:26:25 +02:00
uci.cpp Fix a few minor code style inconsistencies 2018-03-21 01:35:05 +01:00
uci.h Allow UCI parameters to be double 2018-04-23 08:08:27 +02:00
ucioption.cpp Allow UCI parameters to be double 2018-04-23 08:08:27 +02:00