mirror of
https://github.com/HChaZZY/Stockfish.git
synced 2025-12-20 00:56:39 +08:00
Revert thread_local stuff
Unfortunatly accessing thread local variable is much slower than object data (see previous patch log msg), so we have to revert to old code to avoid speed regression. No functional change. Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
@@ -56,7 +56,7 @@ namespace {
|
||||
|
||||
void uci_loop(const string& args) {
|
||||
|
||||
Position pos(StartFEN, false); // The root position
|
||||
Position pos(StartFEN, false, Threads.main_thread()); // The root position
|
||||
string cmd, token;
|
||||
|
||||
while (token != "quit")
|
||||
@@ -167,7 +167,7 @@ namespace {
|
||||
else
|
||||
return;
|
||||
|
||||
pos.from_fen(fen, Options["UCI_Chess960"]);
|
||||
pos.from_fen(fen, Options["UCI_Chess960"], Threads.main_thread());
|
||||
|
||||
// Parse move list (if any)
|
||||
while (is >> token && (m = move_from_uci(pos, token)) != MOVE_NONE)
|
||||
|
||||
Reference in New Issue
Block a user