Skip to content

Commit 23c032a

Browse files
authored
Merge pull request #130 from kobanium/ver-9.0
Ver 9.0
2 parents dcd71fc + 09caa90 commit 23c032a

File tree

1 file changed

+7
-11
lines changed

1 file changed

+7
-11
lines changed

src/UctSearch.cpp

+7-11
Original file line numberDiff line numberDiff line change
@@ -988,9 +988,9 @@ InterruptionCheck( void )
988988
static bool
989989
ExtendTime( const int moves )
990990
{
991-
int max = 0, second = 0;
992991
const int child_num = uct_node[current_root].child_num;
993-
child_node_t *uct_child = uct_node[current_root].child;
992+
const child_node_t *uct_child = uct_node[current_root].child;
993+
int max = 0, second = 0;
994994

995995
if (moves < pure_board_size * 3 - 17 || !extend_time) {
996996
return false;
@@ -1024,15 +1024,11 @@ ExtendTime( const int moves )
10241024
static void
10251025
ParallelUctSearch( thread_arg_t *arg )
10261026
{
1027-
thread_arg_t *targ = (thread_arg_t *)arg;
1028-
game_info_t *game;
1029-
int color = targ->color;
1030-
bool interruption = false;
1031-
bool enough_size = true;
1032-
int winner = 0;
1033-
int interval = CRITICALITY_INTERVAL;
1034-
1035-
game = AllocateGame();
1027+
const thread_arg_t *targ = (thread_arg_t *)arg;
1028+
const int color = targ->color;
1029+
bool interruption = false, enough_size = true;
1030+
int winner = 0, interval = CRITICALITY_INTERVAL;
1031+
game_info_t *game = AllocateGame();
10361032

10371033
// スレッドIDが0のスレッドだけ別の処理をする
10381034
// 探索回数が閾値を超える, または探索が打ち切られたらループを抜ける

0 commit comments

Comments
 (0)