Skip to content

Does SEE any good in FSF? #977

@HGMuller

Description

@HGMuller

In search.cpp there are several comments that say some of the SEE-based prunigs gain 20, resp. 25 Elo points. But the see_ge routine they call to do their thing appears to only consider the orthodox piece types P, N, B, R, Q, plus the royal piece. All fairy pieces attacking the square are ignored. I would expect this to do more harm than good in variants where unorthodox pieces are present. Some code seems to have been added for removing a Janggi Cannon from the bitboard of attackers if the intended victim is also such a Cannon, but this seems pretty pointless, as being an unorthodox piece it would be ignored anyway.

What seems to be needed to have see_ge make any sense is to replace the hard-coded if cascade over attackers P, N, B, R, Q, K (basically an unrolled loop over piece types in ascending order) by a real loop over actually participating piece types. To avoid sorting, a table in the variant description could be used to specify the order in which the piecesmust be used in the exchange.

There are some other routines (e.g. slider_blockers) that go through some effort to prepare information used in see_ge, (e.g. which pieces are pinned, and where the pinners are.) so if we decide that SEE is not worth it, these could be simplified. It also seems that even though see_ge uses some approximate method for not using pieces that are pinned in the exchange, it seems to ignore pieces of the opposit color in the same situation, which would discover a check when used to capture. (Both types of pieces are indicated by slider_blockers.) While such a check would immediately terminate the exchange, because the opponent has to first evade the check, rather than recapture.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions