Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: official-stockfish/Stockfish
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 3597f1942e
Choose a base ref
...
head repository: official-stockfish/Stockfish
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 83eac08e75
Choose a head ref
  • 18 commits
  • 57 files changed
  • 9 contributors

Commits on Feb 20, 2021

  1. Restore development version

    No functional change
    snicolet committed Feb 20, 2021
    Configuration menu
    Copy the full SHA
    a31007c View commit details
    Browse the repository at this point in the history
  2. Tune search parameters (with Unai Corzo)

    The values used in this patch are taken from a SPSA parameter tuning session
    originated by Unai Corzo (@unaiic), but the final difference of his tune was
    multiplied x2 by hand. Most of the credits should go to him :-)
    
    STC:
    https://tests.stockfishchess.org/tests/view/602f03d07f517a561bc49d40
    LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
    Total: 67664 W: 6252 L: 6035 D: 55377
    Ptnml(0-2): 256, 4799, 23527, 4972, 278
    
    LTC:
    https://tests.stockfishchess.org/tests/view/602f41697f517a561bc49d5a
    LLR: 2.96 (-2.94,2.94) {0.25,1.25}
    Total: 26256 W: 1034 L: 906 D: 24316
    Ptnml(0-2): 10, 804, 11377, 922, 15
    
    Closes #3363
    
    Bench: 3957653
    Vizvezdenec authored and snicolet committed Feb 20, 2021
    Configuration menu
    Copy the full SHA
    6294db7 View commit details
    Browse the repository at this point in the history
  3. Introduce ProbCut for check evasions

    The idea of this patch can be described as follows: if we are in check
    and the transposition table move is a capture that returns a value
    far above beta, we can assume that the opponent just blundered a piece
    by giving check, and we return the transposition table value. This is
    similar to the usual probCut logic for quiet moves, but with a different
    threshold.
    
    Passed STC
    LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
    Total: 33440 W: 3056 L: 2891 D: 27493
    Ptnml(0-2): 110, 2338, 11672, 2477, 123
    https://tests.stockfishchess.org/tests/view/602cd1087f517a561bc49bda
    
    Passed LTC
    LLR: 2.98 (-2.94,2.94) {0.25,1.25}
    Total: 10072 W: 401 L: 309 D: 9362
    Ptnml(0-2): 2, 288, 4365, 378, 3
    https://tests.stockfishchess.org/tests/view/602ceea57f517a561bc49bf0
    
    The committed version has an additional fix to never return unproven wins
    in the tablebase range or the mate range. This fix passed tests for non-
    regression at STC and LTC:
    
    STC:
    LLR: 2.93 (-2.94,2.94) {-1.25,0.25}
    Total: 26240 W: 2354 L: 2280 D: 21606
    Ptnml(0-2): 85, 1763, 9372, 1793, 107
    https://tests.stockfishchess.org/tests/view/602d86a87f517a561bc49c7a
    
    LTC:
    LLR: 2.95 (-2.94,2.94) {-0.75,0.25}
    Total: 35304 W: 1299 L: 1256 D: 32749
    Ptnml(0-2): 14, 1095, 15395, 1130, 18
    https://tests.stockfishchess.org/tests/view/602d98d17f517a561bc49c83
    
    Closes #3362
    
    Bench: 3830215
    Vizvezdenec authored and snicolet committed Feb 20, 2021
    Configuration menu
    Copy the full SHA
    7c30091 View commit details
    Browse the repository at this point in the history

Commits on Feb 26, 2021

  1. Introduce DistanceFromPV

    We introduce a metric for each internal node in search, called DistanceFromPV.
    This distance indicated how far the current node is from the principal variation.
    
    We then use this distance to search the nodes which are close to the PV a little
    deeper (up to 4 plies deeper than the PV): this improves the quality of the search
    at these nodes and bring better updates for the PV during search.
    
    STC:
    LLR: 2.96 (-2.94,2.94) {-0.25,1.25}
    Total: 54936 W: 5047 L: 4850 D: 45039
    Ptnml(0-2): 183, 3907, 19075, 4136, 167
    https://tests.stockfishchess.org/tests/view/6037b88e7f517a561bc4a392
    
    LTC:
    LLR: 2.95 (-2.94,2.94) {0.25,1.25}
    Total: 49608 W: 1880 L: 1703 D: 46025
    Ptnml(0-2): 22, 1514, 21555, 1691, 22
    https://tests.stockfishchess.org/tests/view/6038271b7f517a561bc4a3cb
    
    Closes #3369
    
    Bench: 5037279
    snicolet authored and vondele committed Feb 26, 2021
    Configuration menu
    Copy the full SHA
    0f3f5d8 View commit details
    Browse the repository at this point in the history

Commits on Mar 7, 2021

  1. Clean functions returning by const values

    The codebase contains multiple functions returning by const-value.
    This patch is a small cleanup making those function returns
    by value instead, removing the const specifier.
    
    closes #3328
    
    No functional change
    antoinechampion authored and vondele committed Mar 7, 2021
    Configuration menu
    Copy the full SHA
    9b1274a View commit details
    Browse the repository at this point in the history
  2. Add Stockfish namespace.

    fixes #3350 and is a small cleanup that might make it easier to use SF
    in separate projects, like a NNUE trainer or similar.
    
    closes #3370
    
    No functional change.
    ddobbelaere authored and vondele committed Mar 7, 2021
    Configuration menu
    Copy the full SHA
    7ffae17 View commit details
    Browse the repository at this point in the history
  3. Do not try to use large pages on 32 bit Windows.

    verified to work on windows XP.
    
    fixes  #3379
    
    closes #3380
    
    No functional change.
    noobpwnftw authored and vondele committed Mar 7, 2021
    Configuration menu
    Copy the full SHA
    d4b864f View commit details
    Browse the repository at this point in the history
  4. Deal with commented lines in UCI input

    commands starting with '#' as the first character will be ignored
    
    closes #3378
    
    No functional change
    mattginsberg authored and vondele committed Mar 7, 2021
    Configuration menu
    Copy the full SHA
    5346f1c View commit details
    Browse the repository at this point in the history
  5. Use Bitboard over Square in movegen

    It uses pos.checkers() on target when movegen is the type of EVASION.
    It simplify the code. And it's also expected a slightly speed up,
    because Bitboard is more direct when doing bitwise.
    
    Passed STC:
    LLR: 2.93 (-2.94,2.94) {-1.25,0.25}
    Total: 28176 W: 2506 L: 2437 D: 23233
    Ptnml(0-2): 80, 1904, 10063, 1949, 92
    https://tests.stockfishchess.org/tests/view/60421d18ddcba5f0627bb6a9
    
    Passed LTC:
    LLR: 2.93 (-2.94,2.94) {-0.75,0.25}
    Total: 9704 W: 402 L: 341 D: 8961
    Ptnml(0-2): 3, 279, 4230, 334, 6
    https://tests.stockfishchess.org/tests/view/60422823ddcba5f0627bb6ae
    
    closes #3383
    
    No functional change
    BM123499 authored and vondele committed Mar 7, 2021
    Configuration menu
    Copy the full SHA
    b742746 View commit details
    Browse the repository at this point in the history

Commits on Mar 10, 2021

  1. Change advanced pawn push threshold

    A pawn push is now considered to be "advanced" if the relative destination
    rank is > 6 (previously it was > 5). This affects the search heuristic.
    
    Also remove an assert concerning en passant moves in qsearch().
    
    STC:
    LLR: 2.97 (-2.94,2.94) {-0.25,1.25}
    Total: 46744 W: 4224 L: 4040 D: 38480
    Ptnml(0-2): 165, 3206, 16451, 3380, 170
    https://tests.stockfishchess.org/tests/view/604746082433018de7a3872e
    
    LTC:
    LLR: 2.94 (-2.94,2.94) {0.25,1.25}
    Total: 107840 W: 4198 L: 3892 D: 99750
    Ptnml(0-2): 58, 3472, 46557, 3772, 61
    https://tests.stockfishchess.org/tests/view/60475eae2433018de7a38737
    
    Closes #3389
    
    Bench: 4796780
    TopoIogist authored and snicolet committed Mar 10, 2021
    Configuration menu
    Copy the full SHA
    f3b296c View commit details
    Browse the repository at this point in the history

Commits on Mar 16, 2021

  1. Introduce least_significant_square_bb()

    Introducing least_significant_square_bb(). It is a function that returns a value equal
    to square_bb(lsb(bb)), but it uses fewer instruction. It should speed up more on older
    processors like armv7-a Clang.
    
    Passed STC:
    LLR: 2.93 (-2.94,2.94) {-0.25,1.25}
    Total: 213200 W: 19171 L: 18753 D: 175276
    Ptnml(0-2): 680, 14513, 75831, 14861, 715
    https://tests.stockfishchess.org/tests/view/604bc7632433018de7a38982
    
    Closes #3391
    
    No functional change
    BM123499 authored and snicolet committed Mar 16, 2021
    Configuration menu
    Copy the full SHA
    9393957 View commit details
    Browse the repository at this point in the history
  2. Simplify move generation (1/2)

    STC:
    LLR: 2.95 (-2.94,2.94) {-1.25,0.25}
    Total: 29792 W: 2611 L: 2545 D: 24636
    Ptnml(0-2): 94, 1982, 10659, 2086, 75
    https://tests.stockfishchess.org/tests/view/604fe5b62433018de7a38ba8
    
    LTC:
    LLR: 2.92 (-2.94,2.94) {-0.75,0.25}
    Total: 22040 W: 826 L: 777 D: 20437
    Ptnml(0-2): 8, 646, 9664, 693, 9
    https://tests.stockfishchess.org/tests/view/604fec892433018de7a38bac
    
    Closes #3399
    
    No functional change
    BM123499 authored and snicolet committed Mar 16, 2021
    Configuration menu
    Copy the full SHA
    4b50955 View commit details
    Browse the repository at this point in the history
  3. Simplify move generation (2/2)

    STC:
    LLR: 2.97 (-2.94,2.94) {-1.25,0.25}
    Total: 39352 W: 3551 L: 3493 D: 32308
    Ptnml(0-2): 143, 2695, 13928, 2781, 129
    https://tests.stockfishchess.org/tests/view/6050007a2433018de7a38bbb
    
    LTC:
    LLR: 2.96 (-2.94,2.94) {-0.75,0.25}
    Total: 44944 W: 1629 L: 1596 D: 41719
    Ptnml(0-2): 22, 1319, 19762, 1342, 27
    https://tests.stockfishchess.org/tests/view/60500e892433018de7a38bc4
    
    Closes #3399
    
    No functional change
    BM123499 authored and snicolet committed Mar 16, 2021
    Configuration menu
    Copy the full SHA
    830f597 View commit details
    Browse the repository at this point in the history

Commits on Mar 17, 2021

  1. Remove advanced_pawn_push()

    Continuation of work by @topologist: we now do futility pruning and movecount
    pruning in qsearch() for pawn pushes up to the 7th rank. So the condition to
    avoid the pruning is if the move is a promotion or not. This allows to get rid
    of the advanced_pawn_push() function in position.h alltogether.
    
    Passed STC
    https://tests.stockfishchess.org/tests/view/6048c5842433018de7a387e6
    LLR: 2.93 (-2.94,2.94) {-1.25,0.25}
    Total: 34424 W: 3081 L: 3015 D: 28328
    Ptnml(0-2): 110, 2442, 12052, 2488, 120
    
    Passed LTC
    https://tests.stockfishchess.org/tests/view/6048f7d22433018de7a387f0
    LLR: 2.94 (-2.94,2.94) {-0.75,0.25}
    Total: 142024 W: 5170 L: 5202 D: 131652
    Ptnml(0-2): 50, 4678, 61613, 4596, 75
    
    Closes #3390
    
    Bench: 4339126
    Vizvezdenec authored and snicolet committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    d58e836 View commit details
    Browse the repository at this point in the history
  2. Change definition of between_bb()

    We remark that in current master, most of our use cases for between_bb() can be
    optimized if the second parameter of the function is added to the segment. So we
    change the definition of between_bb(s1, s2) such that it excludes s1 but includes s2.
    
    We also use a precomputed array for between_bb() for another small speed gain
    (see https://tests.stockfishchess.org/tests/view/604d09f72433018de7a389fb).
    
    Passed STC:
    LLR: 2.96 (-2.94,2.94) {-0.25,1.25}
    Total: 18736 W: 1746 L: 1607 D: 15383
    Ptnml(0-2): 61, 1226, 6644, 1387, 50
    https://tests.stockfishchess.org/tests/view/60428c84ddcba5f0627bb6e4
    
    Yellow LTC:
    LTC:
    LLR: -3.00 (-2.94,2.94) {0.25,1.25}
    Total: 39144 W: 1431 L: 1413 D: 36300
    Ptnml(0-2): 13, 1176, 17184, 1178, 21
    https://tests.stockfishchess.org/tests/view/605128702433018de7a38ca1
    
    Closes #3397
    
    ---------
    
    Verified for correctness by running perft on the following position:
    
    ./stockfish
    position fen 4rrk1/1p1nq3/p7/2p1P1pp/3P2bp/3Q1Bn1/PPPB4/1K2R1NR w - - 40 21
    go perft 6
    
    Nodes searched: 6136386434
    
    --------
    
    No functional change
    BM123499 authored and snicolet committed Mar 17, 2021
    Configuration menu
    Copy the full SHA
    5089061 View commit details
    Browse the repository at this point in the history

Commits on Mar 19, 2021

  1. Add a specific FRC correction from classical to NNUE

    our net currently is not trained on FRC games, and so doesn't know about the important pattern of a bishop that is cornered in FRC.
    This patch introduces a term we have in the classical evaluation for this case, and adds it to the NNUE eval.
    
    Since fishtest doesn't support FRC right now, the patch was tested locally at STC conditions,
    starting from the book of FRC starting positions.
    
    Score of master vs patch: 993 - 2226 - 6781  [0.438] 10000
    
    Which corresponds to approximately 40 Elo
    
    The patch passes non-regression testing for traditional chess (where it adds one branch).
    
    passed STC:
    https://tests.stockfishchess.org/tests/view/604fa2532433018de7a38b67
    LLR: 2.95 (-2.94,2.94) {-1.25,0.25}
    Total: 30560 W: 2701 L: 2636 D: 25223
    Ptnml(0-2): 88, 2056, 10921, 2133, 82
    
    passed STC also in an earlier version:
    https://tests.stockfishchess.org/tests/view/604f61282433018de7a38b4d
    
    closes #3398
    
    No functional change
    Vizvezdenec authored and vondele committed Mar 19, 2021
    Configuration menu
    Copy the full SHA
    ace9632 View commit details
    Browse the repository at this point in the history
  2. Use reference instead of pointer for pop_lsb() signature

    This patch changes the pop_lsb() signature from Square pop_lsb(Bitboard*) to
    Square pop_lsb(Bitboard&). This is more idomatic for C++ style signatures.
    
    Passed a non-regression STC test:
    LLR: 2.93 (-2.94,2.94) {-1.25,0.25}
    Total: 21280 W: 1928 L: 1847 D: 17505
    Ptnml(0-2): 71, 1427, 7558, 1518, 66
    https://tests.stockfishchess.org/tests/view/6053a1e22433018de7a38e2f
    
    We have verified that the generated binary is identical on gcc-10.
    
    Closes #3404
    
    No functional change.
    gvreuls authored and snicolet committed Mar 19, 2021
    Configuration menu
    Copy the full SHA
    ec42154 View commit details
    Browse the repository at this point in the history

Commits on Mar 24, 2021

  1. Small cleanups (march 2021)

    With help of @BM123499, @mstembera, @gvreuls, @noobpwnftw and @Fanael
    Thanks!
    
    Closes #3405
    
    No functional change
    snicolet committed Mar 24, 2021
    Configuration menu
    Copy the full SHA
    83eac08 View commit details
    Browse the repository at this point in the history
Loading