Assorted trivial cleanups 5/2019

No functional change.

bench: 4178282
This commit is contained in:
Marco Costalba
2019-05-02 19:36:25 +02:00
parent 2ead74d1e2
commit d39bc2efa1
12 changed files with 73 additions and 82 deletions

View File

@@ -43,15 +43,16 @@ void TTEntry::save(Key k, Value v, bool pv, Bound b, Depth d, Move m, Value ev)
// Overwrite less valuable entries
if ( (k >> 48) != key16
|| d / ONE_PLY + 10 > depth8
||(d - DEPTH_OFFSET) / ONE_PLY > depth8 - 4
|| b == BOUND_EXACT)
{
assert((d - DEPTH_OFFSET) / ONE_PLY >= 0);
key16 = (uint16_t)(k >> 48);
value16 = (int16_t)v;
eval16 = (int16_t)ev;
genBound8 = (uint8_t)(TT.generation8 | uint8_t(pv) << 2 | b);
assert((d - DEPTH_NONE) / ONE_PLY >= 0);
depth8 = (uint8_t)((d - DEPTH_NONE) / ONE_PLY);
depth8 = (uint8_t)((d - DEPTH_OFFSET) / ONE_PLY);
}
}