ZCT 3.2442 by Zach Wegner - JA Windows builds available

Discussions about Winboard/Xboard. News about engines or programs to use with these GUIs (e.g. tournament managers or adapters) belong in this sub forum.

Moderator: Andres Valverde

ZCT 3.2442 by Zach Wegner - JA Windows builds available

Postby Jim Ablett » 29 Apr 2008, 11:36

Image
ZCT 3.2442 by Zach Wegner
http://sourceforge.net/projects/zct/

Windows x64 & win32 Intel compiler 10 p.g.o
& Gcc-cygwin SMP builds.


I had some problems compiling the smp version
in native Windows, so I compiled it with Cygwin. A bit
slower than the Intel builds and only 32 bit. I'm sure
this will be sorted out soon.

Available from my homepage.

Jim.
___________________________
http://jimablett.net63.net/
Jim Ablett
 
Posts: 721
Joined: 27 Sep 2004, 10:39
Location: Essex, England

Re: ZCT 3.2442 by Zach Wegner - JA Windows builds available

Postby Olivier Deville » 29 Apr 2008, 15:37

Hello Jim !

There seems to be an issue with pondering.

Winboard debug in your mailbox.

Olivier
User avatar
Olivier Deville
 
Posts: 1176
Joined: 26 Sep 2004, 19:54
Location: Aurec, France

Re: ZCT 3.2442 by Zach Wegner - JA Windows builds available

Postby Jim Ablett » 29 Apr 2008, 15:52

Olivier Deville wrote:Hello Jim !

There seems to be an issue with pondering.

Winboard debug in your mailbox.

Olivier


Hi Olivier,

I'm also getting a 'white resigned for black' error every now and again.
I can probably fix that one.
I suppose we must expect bugs as this isn't an official release, just the
beta CVS src code and the best way to get them fixed is to report them
as you are doing now. :)

Jim.
___________________________
http://jimablett.net63.net/
Jim Ablett
 
Posts: 721
Joined: 27 Sep 2004, 10:39
Location: Essex, England

Re: ZCT 3.2442 by Zach Wegner - JA Windows builds available

Postby Jim Ablett » 29 Apr 2008, 16:15

I found the problem in 'input.c' there is no windows equivalent to check for input >

Code: Select all
/**
input_available():
This function checks during a search if there is input waiting that we need to process.
Created 102206; last modified 102206
**/
BOOL input_available(void)
{
#ifdef ZCT_POSIX
   int fd;
   fd_set f_s;
   struct timeval tv;

   if (source)
      return FALSE;
   fd = fileno(input_stream);
   FD_ZERO(&f_s);
   FD_SET(fd, &f_s);
   tv.tv_sec = 0;
   tv.tv_usec = 0;
   select(1, &f_s, 0, 0, &tv);
   return FD_ISSET(fd, &f_s);
#elif defined(ZCT_WINDOWS)
   if (source)
      return FALSE;
   return 0;
#endif
}


Adding the windows equivalent code from olithink should fix it >

Code: Select all
/**
input_available():
This function checks during a search if there is input waiting that we need to process.
Created 102206; last modified 102206
**/
BOOL input_available(void)
{
#ifdef ZCT_POSIX
   int fd;
   fd_set f_s;
   struct timeval tv;

   if (source)
      return FALSE;
   fd = fileno(input_stream);
   FD_ZERO(&f_s);
   FD_SET(fd, &f_s);
   tv.tv_sec = 0;
   tv.tv_usec = 0;
   select(1, &f_s, 0, 0, &tv);
   return FD_ISSET(fd, &f_s);

#elif defined(ZCT_WINDOWS)
   if (source)
      return FALSE;
//   return 0;

/*
  From Beowulf, from Olithink
*/
   
   
    /* If we're running under XBoard then we can't use _kbhit() as the input
     * commands are sent to us directly over the internal pipe */

#if defined(FILE_CNT)
    if (stdin->_cnt > 0)
        return stdin->_cnt;
#endif
    if (!init) {
        init = 1;
        inh = GetStdHandle(STD_INPUT_HANDLE);
        pipe = !GetConsoleMode(inh, &dw);
        if (!pipe) {
            SetConsoleMode(inh, dw & ~(ENABLE_MOUSE_INPUT | ENABLE_WINDOW_INPUT));
            FlushConsoleInputBuffer(inh);
        }
    }
    if (pipe) {
        if (!PeekNamedPipe(inh, NULL, 0, NULL, &dw, NULL))
            return 1;
        return dw;
    } else {
        GetNumberOfConsoleInputEvents(inh, &dw);
        return dw <= 1 ? 0 : dw;
   

}


#endif
}


Jim.
___________________________
http://jimablett.net63.net/
Jim Ablett
 
Posts: 721
Joined: 27 Sep 2004, 10:39
Location: Essex, England

Re: ZCT 3.2442 by Zach Wegner - JA Windows builds available

Postby Jim Ablett » 29 Apr 2008, 20:28

There's an update available on my homepage now.

It fixes the ponder bug and also a workaround fix for
the 'too early mate result' bug.

Jim.
___________________________
http://jimablett.net63.net/
Jim Ablett
 
Posts: 721
Joined: 27 Sep 2004, 10:39
Location: Essex, England

Re: ZCT 3.2442 by Zach Wegner - JA Windows builds available

Postby Jim Ablett » 29 Apr 2008, 20:35

I forgot to mention egbb support in activated, but it is non-configurable at the moment.
The EGBB folder must be placed in ZCT's engine folder.

Jim.
___________________________
http://jimablett.net63.net/
Jim Ablett
 
Posts: 721
Joined: 27 Sep 2004, 10:39
Location: Essex, England

Re: ZCT 3.2442 by Zach Wegner - JA Windows builds available

Postby Teemu Pudas » 29 Apr 2008, 21:33

Jim Ablett wrote:I had some problems compiling the smp version
in native Windows, so I compiled it with Cygwin.


No kidding. I've managed to fix some of it: now it doesn't crash, it just keeps spawning processes forever (fork() is failing to make CreateProcess() fail). :D
Teemu Pudas
 
Posts: 124
Joined: 16 Apr 2007, 14:03

Re: ZCT 3.2442 by Zach Wegner - JA Windows builds available

Postby Jim Ablett » 29 Apr 2008, 21:51

Teemu Pudas wrote:
Jim Ablett wrote:I had some problems compiling the smp version
in native Windows, so I compiled it with Cygwin.


No kidding. I've managed to fix some of it: now it doesn't crash, it just keeps spawning processes forever (fork() is failing to make CreateProcess() fail). :D


Hi Teemu,

in 'smp.c' - smp_cleanup(void)

Did you try this alternative to unix Sigkill ?

Code: Select all
/**
smp_cleanup():
Takes care of all process-related stuff at exit, i.e. kill children, destroy shared memory
Created 080606; last modified 082606
**/
void smp_cleanup(void)
{
   int x;

   if (board.id == 0)
   {
      for (x = 1; x < process_count; x++)
      {
         print("Killing process %i(pid=%i)...\n", x, smp_block[x].pid);
         ExitProcess(smp_block[x].pid);
      }


Jim.
___________________________
http://jimablett.net63.net/
Jim Ablett
 
Posts: 721
Joined: 27 Sep 2004, 10:39
Location: Essex, England

Re: ZCT 3.2442 by Zach Wegner - JA Windows builds available

Postby Teemu Pudas » 29 Apr 2008, 22:31

That won't work.
MSDN wrote:ExitProcess Function
Ends the calling process and all its threads.


Instead, I collect the process handles and kill them with TerminateProcess() (which fortunately does work. It'd have hosed my computer otherwise :)). Anyway, that's not the problem I was talking about: fork() is supposed to fail when called by a child, but it doesn't, resulting in exponential spawning.
Teemu Pudas
 
Posts: 124
Joined: 16 Apr 2007, 14:03

Re: ZCT 3.2442 by Zach Wegner - JA Windows builds available

Postby Jim Ablett » 30 Apr 2008, 09:01

I've decided to remove the ZCT windows build for now as
it's not ready for general release and it's causing
a few headaches for Zach.

Jim.
___________________________
http://jimablett.net63.net/
Jim Ablett
 
Posts: 721
Joined: 27 Sep 2004, 10:39
Location: Essex, England

Re: ZCT 3.2442 by Zach Wegner - JA Windows builds available

Postby Zach Wegner » 30 Apr 2008, 13:19

Hello Jim,

Right now, it's perfectly fine to put up compiles, I'd like it. I did an official release just so that the source is distributed along with everything; now anyone can do whatever they want. The best thing to happen now is for the source to go around, any bugs fixed, and compiled by all of the pros. Don't worry about what I said with the bugfixes, you can just keep them fixed and I'll clean it up later. I don't really have the time now, so as long as it works its fine.

Zach
User avatar
Zach Wegner
 
Posts: 182
Joined: 26 Sep 2004, 22:02
Location: Austin, Texas, USA

Re: ZCT 3.2442 by Zach Wegner - JA Windows builds available

Postby Jim Ablett » 30 Apr 2008, 18:18

Zach Wegner wrote:Hello Jim,

Right now, it's perfectly fine to put up compiles, I'd like it. I did an official release just so that the source is distributed along with everything; now anyone can do whatever they want. The best thing to happen now is for the source to go around, any bugs fixed, and compiled by all of the pros. Don't worry about what I said with the bugfixes, you can just keep them fixed and I'll clean it up later. I don't really have the time now, so as long as it works its fine.

Zach


Hi Zach,

Download back up now (with src).

Jim.
___________________________
http://jimablett.net63.net/
Jim Ablett
 
Posts: 721
Joined: 27 Sep 2004, 10:39
Location: Essex, England


Return to Winboard and related Topics

Who is online

Users browsing this forum: No registered users and 12 guests