xboard-devel
[Top][All Lists]
Advanced

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

[XBoard-devel] Bugfix: [Fwd: [Bug-XBoard] [bugs #6908] Node count stops


From: Daniel Mehrmann
Subject: [XBoard-devel] Bugfix: [Fwd: [Bug-XBoard] [bugs #6908] Node count stops after about 4.3 billionnodes]
Date: Sun, 15 Feb 2004 01:52:52 +0100
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7a) Gecko/20040124

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi,
this is my patch for Bug #6908.
Its not full tested, but i'm sure it works. I let my crafty running over
the night and we will see what happend ;))

- --- backend.h 2004-02-12 13:32:59.000000000 +0100
+++ backend.h.new       2004-02-15 00:08:52.265625000 +0100
@@ -174,8 +174,21 @@
~ #define ICS_ICC 1
~ #define ICS_FICS 2
~ #define ICS_CHESSNET 3 /* not really supported */
- -int ics_type;
- -
+int ics_type;
+
+/* unsigned int 64 for engine nodes work and display */
+#define u64Display  "%I64u"
+#ifdef WIN32
+       /* I don't know the name for this type of other compilers
+        * If it not work just added here
+        * Thats for MS Visual Studio
+        */
+       #define u64     unsigned __int64
+#else
+       /* GNU gcc */
+       #define u64     unsigned long long
+#endif
+

~ /* pgntags.c prototypes
~  */




- --- backend.c 2004-02-12 13:32:59.000000000 +0100
+++ backend.c.new       2004-02-15 01:24:33.578125000 +0100
@@ -131,7 +131,7 @@
~   int nr_moves;           /* Total nr of root moves */
~   int moves_left;         /* Moves remaining to be searched */
~   char move_name[MOVE_LEN];  /* Current move being searched, if
provided */
- -  unsigned long nodes;    /* # of nodes searched */
+  u64 nodes;                     /* # of nodes searched */
~   int time;               /* Search time (centiseconds) */
~   int score;              /* Score (centipawns) */
~   int got_only_move;      /* If last msg was "(only move)" */
@@ -4344,7 +4344,7 @@
~     if (appData.showThinking) {
~       int plylev, mvleft, mvtot, curscore, time;
~       char mvname[MOVE_LEN];
- -     unsigned long nodes;
+       u64 nodes;
~       char plyext;
~       int ignore = FALSE;
~       int prefixHint = FALSE;
@@ -4375,7 +4375,7 @@

~       if (!ignore) {
~           buf1[0] = NULLCHAR;
- -         if (sscanf(message, "%d%c %d %d %lu %[^\n]\n",
+           if (sscanf(message, "%d%c %d %d %I64u %[^\n]\n",
~                      &plylev, &plyext, &curscore, &time, &nodes, buf1) >= 5) {

~               if (plyext != ' ' && plyext != '\t') {
@@ -9251,7 +9251,7 @@
~     if (programStats.got_only_move) {
~       strcpy(buf, programStats.movelist);
~     } else {
- -     nps = (((double)programStats.nodes) /
+       nps = (((u64)programStats.nodes) /
~              (((double)programStats.time)/100.0));

~       cs = programStats.time % 100;
@@ -9263,32 +9263,32 @@

~       if (programStats.moves_left > 0 && appData.periodicUpdates) {
~         if (programStats.move_name[0] != NULLCHAR) {
- -         sprintf(buf, "depth=%d %d/%d(%s) %+.2f %s%s\nNodes: %lu NPS:
%d\nTime: %02d:%02d:%02d.%02d",
+           sprintf(buf, "depth=%d %d/%d(%s) %+.2f %s%s\nNodes: %I64u NPS:
%d\nTime: %02d:%02d:%02d.%02d",
~                   programStats.depth,
~                   programStats.nr_moves-programStats.moves_left,
~                   programStats.nr_moves, programStats.move_name,
~                   ((float)programStats.score)/100.0, programStats.movelist,
~                   only_one_move(programStats.movelist)?
~                   xtra[programStats.got_fail] : "",
- -                 programStats.nodes, (int)nps, h, m, s, cs);
+                   (u64)programStats.nodes, (int)nps, h, m, s, cs);
~         } else {
- -         sprintf(buf, "depth=%d %d/%d %+.2f %s%s\nNodes: %lu NPS: %d\nTime:
%02d:%02d:%02d.%02d",
+           sprintf(buf, "depth=%d %d/%d %+.2f %s%s\nNodes: %I64u NPS:
%d\nTime: %02d:%02d:%02d.%02d",
~                   programStats.depth,
~                   programStats.nr_moves-programStats.moves_left,
~                   programStats.nr_moves, ((float)programStats.score)/100.0,
~                   programStats.movelist,
~                   only_one_move(programStats.movelist)?
~                   xtra[programStats.got_fail] : "",
- -                 programStats.nodes, (int)nps, h, m, s, cs);
+                   (u64)programStats.nodes, (int)nps, h, m, s, cs);
~         }
~       } else {
- -         sprintf(buf, "depth=%d %+.2f %s%s\nNodes: %lu NPS: %d\nTime:
%02d:%02d:%02d.%02d",
+           sprintf(buf, "depth=%d %+.2f %s%s\nNodes: %I64u NPS: %d\nTime:
%02d:%02d:%02d.%02d",
~                   programStats.depth,
~                   ((float)programStats.score)/100.0,
~                   programStats.movelist,
~                   only_one_move(programStats.movelist)?
~                   xtra[programStats.got_fail] : "",
- -                 programStats.nodes, (int)nps, h, m, s, cs);
+                   (u64)programStats.nodes, (int)nps, h, m, s, cs);
~       }
~     }
~     DisplayAnalysisText(buf);



- -------- Original Message --------
Subject: [Bug-XBoard] [bugs #6908] Node count stops after about 4.3
billionnodes
Date: Mon, 01 Dec 2003 19:13:27 -0500
From: anonymous <address@hidden>
To: <address@hidden>

This mail is an automated notification from the bugs tracker
~ of the project: XBoard.




/**************************************************************************/
[bugs #6908] Full Item Snapshot:

URL: <http://savannah.gnu.org/bugs/?func=detailitem&item_id=6908>
Project: XBoard
Submitted by: 0
On: Mon 12/01/2003 at 19:13

Category:  None
Severity:  5 - Average
Item Group:  None
Resolution:  None
Assigned to:  None
Status:  Open


Summary:  Node count stops after about 4.3 billion nodes

Original Submission:  Xboard 4.2.7. Analysing position with Crafty 19.6.

Observing after a while that the Node count has stopped.

Not sure if depth and variation gets updated. The time runs.

NPS is dropping.



depth=21 1/24 +0.66 1. Kf3 Rc8 2. Rd7+ Rc7 3. Rd3 Kc8 4. Rd8+ Kb7 5. a3
Rc8 6. Rd7+ Rc7 7. Rd3 Kc8 8. Rd8+ Kb7 9. Ke4 Rc8 10. Rd7+ Rc7 11. Rd3
Kc8 12. Rd8+ Kb7 13. Bf4 Re7 14. f3 Kc7

Nodes: 4294967295 NPS: 913574

Time: 01:18:21.28











For detailed info, follow this link:
<http://savannah.gnu.org/bugs/?func=detailitem&item_id=6908>

_______________________________________________
~  Message sent via/by Savannah
~  http://savannah.gnu.org/



_______________________________________________
Bug-XBoard mailing list
address@hidden
http://mail.gnu.org/mailman/listinfo/bug-xboard





- --
Daniel Mehrmann
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (MingW32)

iD8DBQFALsLkPt1V5Pj1nvYRAmw1AJ9148O7yOK8VTaBf34dKIkdY0a9UgCeKmah
xm5rTI9IqaRgth0ChJOZpNk=
=YQSS
-----END PGP SIGNATURE-----

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature


reply via email to

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