mirror of
https://github.com/sockspls/badfish
synced 2025-04-29 16:23:09 +00:00
Array FutilityMarginsMatrix stores Values
No functional change. Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
parent
6096ca7a95
commit
5b5b496a6d
1 changed files with 3 additions and 3 deletions
|
@ -226,10 +226,10 @@ namespace {
|
|||
const Value FutilityMarginQS = Value(0x80);
|
||||
|
||||
// Futility lookup tables (initialized at startup) and their getter functions
|
||||
int32_t FutilityMarginsMatrix[16][64]; // [depth][moveNumber]
|
||||
Value FutilityMarginsMatrix[16][64]; // [depth][moveNumber]
|
||||
int FutilityMoveCountArray[32]; // [depth]
|
||||
|
||||
inline Value futility_margin(Depth d, int mn) { return Value(d < 7 * ONE_PLY ? FutilityMarginsMatrix[Max(d, 1)][Min(mn, 63)] : 2 * VALUE_INFINITE); }
|
||||
inline Value futility_margin(Depth d, int mn) { return d < 7 * ONE_PLY ? FutilityMarginsMatrix[Max(d, 1)][Min(mn, 63)] : 2 * VALUE_INFINITE; }
|
||||
inline int futility_move_count(Depth d) { return d < 16 * ONE_PLY ? FutilityMoveCountArray[d] : 512; }
|
||||
|
||||
// Step 14. Reduced search
|
||||
|
@ -368,7 +368,7 @@ void init_search() {
|
|||
|
||||
// Init futility margins array
|
||||
for (d = 1; d < 16; d++) for (mc = 0; mc < 64; mc++)
|
||||
FutilityMarginsMatrix[d][mc] = 112 * int(log(double(d * d) / 2) / log(2.0) + 1.001) - 8 * mc + 45;
|
||||
FutilityMarginsMatrix[d][mc] = Value(112 * int(log(double(d * d) / 2) / log(2.0) + 1.001) - 8 * mc + 45);
|
||||
|
||||
// Init futility move count array
|
||||
for (d = 0; d < 32; d++)
|
||||
|
|
Loading…
Add table
Reference in a new issue