head 1.4; access; symbols pkgsrc-2014Q2:1.3.0.10 pkgsrc-2014Q2-base:1.3 pkgsrc-2014Q1:1.3.0.8 pkgsrc-2014Q1-base:1.3 pkgsrc-2013Q4:1.3.0.6 pkgsrc-2013Q4-base:1.3 pkgsrc-2013Q3:1.3.0.4 pkgsrc-2013Q3-base:1.3 pkgsrc-2013Q2:1.3.0.2 pkgsrc-2013Q2-base:1.3 pkgsrc-2013Q1:1.2.0.12 pkgsrc-2013Q1-base:1.2 pkgsrc-2012Q4:1.2.0.10 pkgsrc-2012Q4-base:1.2 pkgsrc-2012Q3:1.2.0.8 pkgsrc-2012Q3-base:1.2 pkgsrc-2012Q2:1.2.0.6 pkgsrc-2012Q2-base:1.2 pkgsrc-2012Q1:1.2.0.4 pkgsrc-2012Q1-base:1.2 pkgsrc-2011Q4:1.2.0.2 pkgsrc-2011Q4-base:1.2 pkgsrc-2011Q3:1.1.0.66 pkgsrc-2011Q3-base:1.1 pkgsrc-2011Q2:1.1.0.64 pkgsrc-2011Q2-base:1.1 pkgsrc-2011Q1:1.1.0.62 pkgsrc-2011Q1-base:1.1 pkgsrc-2010Q4:1.1.0.60 pkgsrc-2010Q4-base:1.1 pkgsrc-2010Q3:1.1.0.58 pkgsrc-2010Q3-base:1.1 pkgsrc-2010Q2:1.1.0.56 pkgsrc-2010Q2-base:1.1 pkgsrc-2010Q1:1.1.0.54 pkgsrc-2010Q1-base:1.1 pkgsrc-2009Q4:1.1.0.52 pkgsrc-2009Q4-base:1.1 pkgsrc-2009Q3:1.1.0.50 pkgsrc-2009Q3-base:1.1 pkgsrc-2009Q2:1.1.0.48 pkgsrc-2009Q2-base:1.1 pkgsrc-2009Q1:1.1.0.46 pkgsrc-2009Q1-base:1.1 pkgsrc-2008Q4:1.1.0.44 pkgsrc-2008Q4-base:1.1 pkgsrc-2008Q3:1.1.0.42 pkgsrc-2008Q3-base:1.1 cube-native-xorg:1.1.0.40 cube-native-xorg-base:1.1 pkgsrc-2008Q2:1.1.0.38 pkgsrc-2008Q2-base:1.1 cwrapper:1.1.0.36 pkgsrc-2008Q1:1.1.0.34 pkgsrc-2008Q1-base:1.1 pkgsrc-2007Q4:1.1.0.32 pkgsrc-2007Q4-base:1.1 pkgsrc-2007Q3:1.1.0.30 pkgsrc-2007Q3-base:1.1 pkgsrc-2007Q2:1.1.0.28 pkgsrc-2007Q2-base:1.1 pkgsrc-2007Q1:1.1.0.26 pkgsrc-2007Q1-base:1.1 pkgsrc-2006Q4:1.1.0.24 pkgsrc-2006Q4-base:1.1 pkgsrc-2006Q3:1.1.0.22 pkgsrc-2006Q3-base:1.1 pkgsrc-2006Q2:1.1.0.20 pkgsrc-2006Q2-base:1.1 pkgsrc-2006Q1:1.1.0.18 pkgsrc-2006Q1-base:1.1 pkgsrc-2005Q4:1.1.0.16 pkgsrc-2005Q4-base:1.1 pkgsrc-2005Q3:1.1.0.14 pkgsrc-2005Q3-base:1.1 pkgsrc-2005Q2:1.1.0.12 pkgsrc-2005Q2-base:1.1 pkgsrc-2005Q1:1.1.0.10 pkgsrc-2005Q1-base:1.1 pkgsrc-2004Q4:1.1.0.8 pkgsrc-2004Q4-base:1.1 pkgsrc-2004Q3:1.1.0.6 pkgsrc-2004Q3-base:1.1 pkgsrc-2004Q2:1.1.0.4 pkgsrc-2004Q2-base:1.1 pkgsrc-2004Q1:1.1.0.2 pkgsrc-2004Q1-base:1.1; locks; strict; comment @# @; 1.4 date 2014.09.11.16.59.16; author jperkin; state dead; branches; next 1.3; commitid b7OUQ9vL3mT5TWPx; 1.3 date 2013.04.30.22.20.58; author joerg; state Exp; branches; next 1.2; 1.2 date 2011.11.25.21.52.33; author joerg; state Exp; branches; next 1.1; 1.1 date 2004.02.14.04.31.56; author kristerw; state Exp; branches; next ; desc @@ 1.4 log @Update games/exchess to v7.31beta, this package's first update in 14 years. The primary motivator for the upgrade is to improve the book generation time, which is now several times faster (builds were failing with CPU ulimit of 1 hour on 3GHz Xeon E5's with the previous version). This new version even supports multiple cores, though that isn't enabled at this time. There appear to have been many other updates, but there is no ChangeLog and there aren't even any intermediate versions for download (hence using the current beta version). Upstream unfortunately makes it as difficult as possible to see the history of this package. @ text @$NetBSD: patch-ai,v 1.3 2013/04/30 22:20:58 joerg Exp $ --- exmove.cpp.orig 2000-04-01 07:46:42.000000000 +0000 +++ exmove.cpp @@@@ -8,7 +8,7 @@@@ #include "const.h" #include "funct.h" #include "hash.h" -#include "iostream.h" +#include /* Hash code variables */ extern hash_rec *hash_table; // pointer to hash_table @@@@ -37,7 +37,7 @@@@ inline int simple_check(position *p, int // If the move is legal, the function returns a 1, otherwise 0. // Note that the move is made, regardless - so proper precautions // need to be taken, if the move might need to be undone -int exec_move(position *p, move emove, int ply) +int exec_move(position *p, my_move emove, int ply) { register int pi; // if this is a castle, check that it is legal then @@@@ -52,8 +52,8 @@@@ int exec_move(position *p, move emove, i { return 0; } p->sq[5] = p->sq[7]; p->sq[7] = empty; - or(p->hcode, hval[WROOK][5]); - or(p->hcode, hval[WROOK][7]); + hash_or(p->hcode, hval[WROOK][5]); + hash_or(p->hcode, hval[WROOK][7]); p->has_castled[1] = 1; /* update piece list */ for(pi=1;pi<=p->plist[p->wtm][ROOK][0];pi++) @@@@ -69,8 +69,8 @@@@ int exec_move(position *p, move emove, i { return 0; } p->sq[3] = p->sq[0]; p->sq[0] = empty; - or(p->hcode, hval[WROOK][3]); - or(p->hcode, hval[WROOK][0]); + hash_or(p->hcode, hval[WROOK][3]); + hash_or(p->hcode, hval[WROOK][0]); p->has_castled[1] = 1; /* update piece list */ for(pi=1;pi<=p->plist[p->wtm][ROOK][0];pi++) @@@@ -86,8 +86,8 @@@@ int exec_move(position *p, move emove, i { return 0; } p->sq[61] = p->sq[63]; p->sq[63] = empty; - or(p->hcode, hval[BROOK][61]); - or(p->hcode, hval[BROOK][63]); + hash_or(p->hcode, hval[BROOK][61]); + hash_or(p->hcode, hval[BROOK][63]); p->has_castled[0] = 1; /* update piece list */ for(pi=1;pi<=p->plist[p->wtm][ROOK][0];pi++) @@@@ -103,8 +103,8 @@@@ int exec_move(position *p, move emove, i { return 0; } p->sq[59] = p->sq[56]; p->sq[56] = empty; - or(p->hcode, hval[BROOK][59]); - or(p->hcode, hval[BROOK][56]); + hash_or(p->hcode, hval[BROOK][59]); + hash_or(p->hcode, hval[BROOK][56]); p->has_castled[0] = 1; /* update piece list */ for(pi=1;pi<=p->plist[p->wtm][ROOK][0];pi++) @@@@ -125,7 +125,7 @@@@ int exec_move(position *p, move emove, i if(p->sq[emove.b.to].type) { // Remove hashcode for the target square - or(p->hcode, hval[ID(p->sq[emove.b.to])][emove.b.to]); + hash_or(p->hcode, hval[ID(p->sq[emove.b.to])][emove.b.to]); // Remove piece from piece list for(pi=1;pi<=p->plist[p->wtm^1][p->sq[emove.b.to].type][0];pi++) if(p->plist[p->wtm^1][p->sq[emove.b.to].type][pi] == emove.b.to) { @@@@ -143,8 +143,8 @@@@ int exec_move(position *p, move emove, i // Move the new piece to the target square p->sq[emove.b.to] = p->sq[emove.b.from]; // Update the hash code to reflect the move - or(p->hcode, hval[ID(p->sq[emove.b.from])][emove.b.from]); - or(p->hcode, hval[ID(p->sq[emove.b.from])][emove.b.to]); + hash_or(p->hcode, hval[ID(p->sq[emove.b.from])][emove.b.from]); + hash_or(p->hcode, hval[ID(p->sq[emove.b.from])][emove.b.to]); // Original square is now empty p->sq[emove.b.from] = empty; @@@@ -152,7 +152,7 @@@@ int exec_move(position *p, move emove, i if(emove.b.type&EP) { if(p->wtm) { p->sq[emove.b.to-8] = empty; - or(p->hcode, hval[BPAWN][emove.b.to-8]); + hash_or(p->hcode, hval[BPAWN][emove.b.to-8]); // Update piece lists for(pi=1;pi<=p->plist[p->wtm^1][PAWN][0];pi++) if(p->plist[BLACK][PAWN][pi] == emove.b.to-8) { @@@@ -163,7 +163,7 @@@@ int exec_move(position *p, move emove, i } } else { p->sq[emove.b.to+8] = empty; - or(p->hcode, hval[WPAWN][emove.b.to+8]); + hash_or(p->hcode, hval[WPAWN][emove.b.to+8]); // Update piece lists for(pi=1;pi<=p->plist[p->wtm^1][PAWN][0];pi++) if(p->plist[WHITE][PAWN][pi] == emove.b.to+8) { @@@@ -189,7 +189,7 @@@@ int exec_move(position *p, move emove, i // if the move is a promotion, promote it if(emove.b.type&PROMOTE) { // Remove the pawn from the hash code - or(p->hcode, hval[ID(p->sq[emove.b.to])][emove.b.to]); + hash_or(p->hcode, hval[ID(p->sq[emove.b.to])][emove.b.to]); // Change the piece type to the promoted piece p->sq[emove.b.to].type = emove.b.promote; // Add the new piece to the piece lists @@@@ -206,7 +206,7 @@@@ int exec_move(position *p, move emove, i // adjust material score p->material += value[emove.b.promote] - value[PAWN]; // add piece to hash code - or(p->hcode, hval[ID(p->sq[emove.b.to])][emove.b.to]); + hash_or(p->hcode, hval[ID(p->sq[emove.b.to])][emove.b.to]); // adjust total piece count p->pieces[p->wtm]++; } @@@@ -214,11 +214,11 @@@@ int exec_move(position *p, move emove, i // update position characteristics p->wtm = p->wtm^1; p->material = -p->material; - or(p->hcode, btm); or(p->hcode, wtm); + hash_or(p->hcode, btm); hash_or(p->hcode, wtm); // undo hash code for en-passant and castling status - or(p->hcode, ep_code[p->ep]); - or(p->hcode, castle_code[p->castle]); + hash_or(p->hcode, ep_code[p->ep]); + hash_or(p->hcode, castle_code[p->castle]); // if move is a pawn push 2 spaces, set en passant flag if((emove.b.type&PAWN_PUSH2) && @@@@ -235,8 +235,8 @@@@ int exec_move(position *p, move emove, i p->last = emove; // update hash code for en-passant and castling status - or(p->hcode, ep_code[p->ep]); - or(p->hcode, castle_code[p->castle]); + hash_or(p->hcode, ep_code[p->ep]); + hash_or(p->hcode, castle_code[p->castle]); // check whether other side is placed in check int ptype = p->sq[emove.b.to].type; @@@@ -270,7 +270,7 @@@@ int exec_move(position *p, move emove, i // Function to make the move in the q-search // - much simpler -int qexec_move(position *p, move emove, int ply) +int qexec_move(position *p, my_move emove, int ply) { register int pi; @ 1.3 log @Avoid conflict with C++11's std::move. @ text @d1 1 a1 1 $NetBSD: patch-ai,v 1.2 2011/11/25 21:52:33 joerg Exp $ @ 1.2 log @Fix build with modern GCC @ text @d1 1 a1 1 $NetBSD: patch-ai,v 1.1 2004/02/14 04:31:56 kristerw Exp $ d14 9 d149 9 @ 1.1 log @Make the package build when using gcc-3.3. @ text @d1 1 a1 1 $NetBSD$ d3 12 a14 3 --- exmove.cpp.orig Sat Feb 14 04:16:56 2004 +++ exmove.cpp Sat Feb 14 04:19:15 2004 @@@@ -52,8 +52,8 @@@@ d25 1 a25 1 @@@@ -69,8 +69,8 @@@@ d36 1 a36 1 @@@@ -86,8 +86,8 @@@@ d47 1 a47 1 @@@@ -103,8 +103,8 @@@@ d58 1 a58 1 @@@@ -125,7 +125,7 @@@@ d67 1 a67 1 @@@@ -143,8 +143,8 @@@@ d78 1 a78 1 @@@@ -152,7 +152,7 @@@@ d87 1 a87 1 @@@@ -163,7 +163,7 @@@@ d96 1 a96 1 @@@@ -189,7 +189,7 @@@@ d105 1 a105 1 @@@@ -206,7 +206,7 @@@@ d114 1 a114 1 @@@@ -214,11 +214,11 @@@@ d129 1 a129 1 @@@@ -235,8 +235,8 @@@@ @