Revert "removed hashSize global | bench 1857933"

This reverts commit 3aad0d90ee.
This commit is contained in:
rektdie committed 2025-04-12 00:35:30 +02:00
1 parent 3aad0d90ee
commit 0242eec87d
3 files changed
+8 -7

No files matched your search

+2 -2
View File
@@ -1,7 +1,7 @@
#include "tt.h"
SEARCH::SearchResults TTable::ReadEntry(U64 &hashKey, int depth, int alpha, int beta) {
TTEntry *current = &table[hashKey % table.size()];
TTEntry *current = &table[hashKey % hashSize];
if (current->hashKey == hashKey) {
if (current->depth >= depth) {
@@ -20,7 +20,7 @@ SEARCH::SearchResults TTable::ReadEntry(U64 &hashKey, int depth, int alpha, int
}
void TTable::WriteEntry(U64 &hashKey, int depth, int score, int nodeType, Move bestMove) {
TTEntry *current = &table[hashKey % table.size()];
TTEntry *current = &table[hashKey % hashSize];
current->hashKey = hashKey;
current->nodeType = nodeType;