[Xastir] Cygwin

Henk de Groot henk.de.groot at hetnet.nl
Sun Apr 4 05:34:18 EDT 2004


At 11:38 3-4-2004 -0800, Curt Mills wrote:
>On one Win2k machine I tried Cygwin/Xastir on, it had 128MB physical
>RAM.  With the normal things that were running on the machine,
>including virus scanning and such, it had very little left.  The
>final link step of the Xastir compile would try over and over to
>complete, but would run out of RAM.  That step kept trying for a day
>and never completed.

I just compiled Xastir on my laptop, it's a Compaq Presario 12LX302 with a 
600 MHz Celron processor. It has 192 MB physical memory of which 8 MB is 
used for video memory. It runs Windows ME and I did not make any explicit 
attempt to free memory. Freeing more memory would not make much of a 
difference since the performance monitor shows a peak assigned memory use 
of 470 MB, so much more than available physical memory. I stopped the 
attempt and shut down Xwindows and tried again in a Bash shell to save some 
memory. I didn't sit and wait for completion but I saw the peak in assigned 
memory nearing 470 MB after about 20 minites when I went to bed. I started 
make with "time" and this morning it showed that "make" completed this last 
step in 125 minutes, so I guess it used up even more memory near the end.

It is much more problematic to link Xastir in Cygwin compared to Linux. 
This very same laptop has an partition with SuSE Linux 7.3 (and 2.4.21 
kernel) and I never had any problem at all to compile and link Xastir (or 
the Linux kernel). Under Linux I have almost everything compiled in, 
including AX.25, geotiff and festival.

Just for comparison I booted the Linux partition and compiled the same 
Xaster version. After completion I throwed away the executable and started 
"time make" to measure the final link step. It doesn't take nowhere near 
the same memory as on Cygwin, I only have a 188 MB swap drive. It took 
1.660 seconds realtime to link xastir, when I run "time make" after linking 
I see that 0.836 seconds of that are used for just checking. Watching "top" 
I saw the "memory used" figure hardly increase and the swap space was never 
used, but it is hard to see within 1.660 seconds...

I guess the difference can be attributed to the way the underlaying OS 
works. I guess GCC works like many other compilers with smaller components 
that are connected to eachother with pipes. Unix systems run the connected 
programs concurrently and a pipe only contains about 2 Kb of data at any 
time. Windows systems mimic pipes but instead of running concurrently one 
program fills the pipe completely before the next program can start to 
empty it. If Cygwin didn't find a way arround this, this may well cause the 
excessive use of memory during compile. Maybe it is possible to break 
linkage down into 3 smaller link steps instead of linking all at once to 
make is more bearable, by the looks of it 512 MB is the minimum ammount of 
memory to keep everything in core during linking.

Another cause may be static linking, I have not looked at the way Cygwin 
links, but I do not see any .so libraries. On the other hand, maybe Cygwin 
uses .dll's for this.

It is a pitty that compiling Xastir under Cygwin is such a pain. A 600 MHz 
Celeron machine with 184 MB physical memory is very capable of running 
Xastir, it looks like installing Linux is the best option for such machines.

Kind regards,

Henk.





More information about the Xastir mailing list