thread: refactor: quit() 更名为 clearHistoryScore()
This commit is contained in:
parent
946aed645e
commit
188c03c734
|
@ -72,7 +72,7 @@ Thread::~Thread()
|
||||||
assert(!searching);
|
assert(!searching);
|
||||||
|
|
||||||
exit = true;
|
exit = true;
|
||||||
quit();
|
clearHistoryScore();
|
||||||
start_searching();
|
start_searching();
|
||||||
stdThread.join();
|
stdThread.join();
|
||||||
}
|
}
|
||||||
|
@ -97,7 +97,7 @@ void Thread::clear()
|
||||||
|
|
||||||
void Thread::start_searching()
|
void Thread::start_searching()
|
||||||
{
|
{
|
||||||
quit();
|
clearHistoryScore();
|
||||||
|
|
||||||
std::lock_guard<std::mutex> lk(mutex);
|
std::lock_guard<std::mutex> lk(mutex);
|
||||||
searching = true;
|
searching = true;
|
||||||
|
@ -195,7 +195,7 @@ void Thread::act()
|
||||||
return;
|
return;
|
||||||
|
|
||||||
std::lock_guard<std::mutex> lk(mutex);
|
std::lock_guard<std::mutex> lk(mutex);
|
||||||
quit();
|
clearHistoryScore();
|
||||||
}
|
}
|
||||||
|
|
||||||
void Thread::setAi(Position *p)
|
void Thread::setAi(Position *p)
|
||||||
|
|
|
@ -100,10 +100,8 @@ public:
|
||||||
|
|
||||||
void analyze(Color c);
|
void analyze(Color c);
|
||||||
|
|
||||||
void quit()
|
void clearHistoryScore()
|
||||||
{
|
{
|
||||||
loggerDebug("Timeout\n");
|
|
||||||
//requiredQuit = true; // TODO
|
|
||||||
#ifdef HOSTORY_HEURISTIC
|
#ifdef HOSTORY_HEURISTIC
|
||||||
movePicker->clearHistoryScore();
|
movePicker->clearHistoryScore();
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue