Date: Tue, 30 Mar 1999 15:22:17 +0800 (JST) From: Richi Plana To: pgcc AT delorie DOT com cc: Andrew DOT Tridgell AT anu DOT edu DOT au, Jon DOT Baxter AT anu DOT edu DOT au Subject: PGCC and KnightCap Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Reply-To: pgcc AT delorie DOT com Hi, There seems to be a problem with PGCC when used to compile the chess-playing program KnightCap. When compiled with PGCC, KnightCap just loops forever at line 267 of movement.c, with or without compiler optimization flags. It's probably not a bug, but I really wouldn't know. $ pgcc -v Reading specs from /usr/lib/gcc-lib/i686-pc-linux-gnu/pgcc-2.91.60/specs gcc version pgcc-2.91.60 19981201 (egcs-1.1.1 release) KnightCap version: KnightCap-3.6.tar.gz $(SRC)/movement.c: Square p1, p2; int s1, s2; int dir, i; uint64 mask; ... for (i=0;i<8;i++) { dir = NORTH_WEST; p1 = A1 + i*EAST; p2 = A1 + i*NORTH; mask = 0; 267: for (s1=p1; s1>=p2; s1+=dir) mask |= ((uint64)1<=p2;s1+=dir) for (s2=p1;s2>=p2;s2+=dir) if (s1 != s2) { same_line_mask[s1][s2] = mask; } } L L Richi Plana 8^) ,-,-. ,-,-. ,-,-. ,-,-. ,- LL LL Systems Administrator / / \ \ / / \ \ / / \ \ / / \ \ / / LLLLL Mosaic Communications, Inc. \ \ / / \ \ / / \ \ / / \ \ / / LLLLL mailto:richip AT mozcom DOT com `-'-' `-'-' `-'-' `-'-' ------------------------------------------------------------------------ P G P Key available at http://www2.mozcom.com/~richip/richip.asc Tired of Spam? Join this CAUCE! http://www.cauce.org/