Re: [Bug-XBoard] Xboard doesn't compile with --disable-zippy

2010-08-04 Thread h.g. muller

At 21:36 3-8-2010 -0400, Adrian Petrescu wrote:
If I run configure with the --disable-zippy flag (which successfully shows 
zippy:  no in the configuration summary), trying to make fails with the 
following errors:


In file included from xboard.c:1347:
args.h:597: error: 'AppData' has no member named 'zippyLines'
It looks like an easy enough thing to fix, probably just have to #ifdef 
out some things from args.h?


Adrian is spot on. The problem is actually that there was an #ifdef ZIPPY 
in args.h, but it should have been an #if ZIPPY to have any effect.
I found the same error in 4 other places in the code (backend.c, xboard.c, 
winboard.c 2x), and changed it all.
All these errors were inherited from 4.4.x, where I fixed them too. (args.h 
was part of winboard.c then.)
XBoard compiles now with the --disable-zippy flag. Haven't tried WinBoard, 
I would not even know how to disable zippy there.
I guess no one has been compiling without zippy for a very long time. I 
found #ifdef ZIPPYs in winboard.c of 4.2.7...


Fixes are uploaded to the hgm.nubati.net repository.

___
Bug-XBoard mailing list
Bug-XBoard@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-xboard


Re: [Bug-XBoard] Re: Extremely slow startup

2010-08-04 Thread Adrian Petrescu
Hello :)

Thanks for the response. I did a bunch of testing and I've pinpointed the
problem: it seems the call to XSync is extremely slow. On line 4568 of
xboard.c if I do:

printf(About to call XSync\n);
XSync(xDisplay, False);
printf(Done calling XSync\n);

Then the About to call XSync gets printed right before the long, painful
hang, and Done calling XSync gets called right when it recovers. The two
prints are about 10 seconds apart. So I think this is definitely the issue.

Unfortunately I'm not very familiar with low-level X programming to be able
to diagnose this right away -- it's way before my time :) I'll take more of
a look if nobody here knows what might be the cause off the top of their
heads.

Cheers,
Adrian

On Wed, Aug 4, 2010 at 5:53 AM, h.g. muller h.g.mul...@hccnet.nl wrote:

 At 22:33 3-8-2010 -0400, Adrian Petrescu wrote:

 Here is a strange symptom that may illuminate the issue or make it more
 puzzling. You decide which.


 This will indeed be a tough cookie...

 For me, startup of XBoard under Ubuntu is fast, so I cannot test it myself.

 It sounds like XBoard is making a system request that your system has big
 trouble in satisfying.
 What are you seeing durng these 10 seconds? Is the XBoard main window
 already up, and
 is the Chess board properly displayed? Are any of the auxiliary windows
 already up?
 The most passive mode to bring XBoard up in is -ncp (with -ics you might
 still hang because
 of connection problems with the ICS), so perhaps you should always test on
 that.

 Could you start XBoard with the -debug option? This should make a file
 xboard.debug,
 and if we are lucky, we can establish from that where it hangs. I think it
 does print some
 progress reports during the startup process, from main() in xboard.c. If
 not, we should
 add some fprintf(stderr, ...); there to figure out where it hangs. There
 are no time stamps
 with debug messages from XBoard itself, though. So to see where it hangs,
 it might be
 necessary to kill it during those 10 sec.

___
Bug-XBoard mailing list
Bug-XBoard@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-xboard