gnugo-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [gnugo-devel] Persistent cache strangeness.


From: Daniel Bump
Subject: Re: [gnugo-devel] Persistent cache strangeness.
Date: Wed, 17 Oct 2001 12:02:37 -0700

> I followed the -t -t traces to find the first place the two
> cases diverged, and it seemed to be in the persistent cache.
> It could, of course, could just be a coincidence that this
> solves the problem.

It seems that my explanation was wrong. If it were correct
the following patch would fix it, since it causes make_dragons
and so forth go get run on the second genmove call. Yet the
problem remains.

Dan

diff -u -r1.13 genmove.c
--- engine/genmove.c    2001/10/16 19:53:01     1.13
+++ engine/genmove.c    2001/10/17 19:01:46
@@ -43,6 +43,13 @@
 static int slowest_movenum = 0;
 static double total_time = 0.;
 
+/* Position numbers for which various examinations were last made. */
+static int worms_examined = -1;
+static int initial_influence_examined = -1;
+static int dragons_examined_without_owl = -1;
+static int dragons_examined = -1;
+static int initial_influence2_examined = -1;
+
 void sgfShowConsideredMoves(void);
 
 
@@ -58,6 +65,11 @@
   /* Initialize things for hashing of positions. */
   reading_cache_clear();
   hashdata_recalc(&hashdata, board, board_ko_pos);
+  worms_examined = -1;
+  initial_influence_examined = -1;
+  dragons_examined_without_owl = -1;
+  dragons_examined = -1;
+  initial_influence2_examined = -1;
 
   /* Prepare our table of move reasons. */
   clear_move_reasons();
@@ -83,13 +95,6 @@
 examine_position(int color, int how_much)
 {
   int save_verbose;
-
-  /* Position numbers for which various examinations were last made. */
-  static int worms_examined = -1;
-  static int initial_influence_examined = -1;
-  static int dragons_examined_without_owl = -1;
-  static int dragons_examined = -1;
-  static int initial_influence2_examined = -1;
 
   purge_persistent_reading_cache();
   





reply via email to

[Prev in Thread] Current Thread [Next in Thread]