|
BenBot 1.7.5
A chess engine
|
#include <libbenbot/data-structures/SearchStack.hpp>
Public Member Functions | |
| auto | at (const size_t plyFromRoot) const noexcept -> const SearchStackEntry * |
| auto | at (const size_t plyFromRoot) noexcept -> SearchStackEntry * |
Static Public Attributes | |
| static constexpr auto | SENTINELS { 4uz } |
Related Symbols | |
(Note that these are not member symbols.) | |
| auto | is_improving (const SearchStackEntry *const entry) noexcept -> bool |
This structure stores information about each node on the current search path, indexed by ply from the root of the search (the root is ply 0).
There are SENTINELS entries before the root's entry, which always hold a null move and no static eval, so a node can always look at least that many plies back without checking how far it is from the root.
Each node's entry is reset by its parent right before the node is searched, so an entry never holds anything left over from an unrelated node that was searched earlier at the same ply.
Definition at line 70 of file SearchStack.hpp.
|
inlinenodiscardnoexcept |
Returns the entry for the node at the given ply from the root.
Definition at line 86 of file SearchStack.hpp.
|
inlinenodiscardnoexcept |
Returns the entry for the node at the given ply from the root. The entries before it, down to SENTINELS plies before the root, can be reached with std::prev().
Definition at line 78 of file SearchStack.hpp.
|
staticconstexpr |
The number of sentinel entries before the root's entry.
Definition at line 72 of file SearchStack.hpp.