- TTEntry();
- TTEntry(Key k, Value v, ValueType t, Depth d, Move m, int generation);
- Key key() const { return key_; }
- Depth depth() const { return Depth(depth_); }
+ void save(uint32_t k, Value v, ValueType t, Depth d, Move m, int g, Value statV, Value kd) {
+
+ key32 = k;
+ data = (m & 0x1FFFF) | (t << 21) | (g << 23);
+ value16 = int16_t(v);
+ depth16 = int16_t(d);
+ staticValue = int16_t(statV);
+ staticValueMargin = int16_t(kd);
+ }
+ void set_generation(int g) { data = move() | (type() << 21) | (g << 23); }
+
+ uint32_t key() const { return key32; }
+ Depth depth() const { return Depth(depth16); }