delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1999/08/22/19:45:58

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT sourceware DOT cygnus DOT com>
List-Archive: <http://sourceware.cygnus.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sourceware DOT cygnus DOT com>
List-Help: <mailto:cygwin-help AT sourceware DOT cygnus DOT com>,
<http://sourceware.cygnus.com/ml/#faqs>
Sender: cygwin-owner AT sourceware DOT cygnus DOT com
Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com
Message-ID: <37C08B8F.21835B74@dgs.monash.edu.au>
Date: Mon, 23 Aug 1999 09:45:20 +1000
From: Brendan Simon <brendan AT dgs DOT monash DOT edu DOT au>
Reply-To: brendan AT dgs DOT monash DOT edu DOT au
Organization: CTAM Pty Ltd
X-Mailer: Mozilla 4.61 [en] (X11; I; Linux 2.0.36 i586)
X-Accept-Language: en
MIME-Version: 1.0
CC: cygwin AT sourceware DOT cygnus DOT com
Subject: Re: How efficient is the g++ compipler in cygwin?
References: <37BF5F4E DOT 9E1862F1 AT engmail DOT uwaterloo DOT ca> <37C01A9F DOT 136ABAB AT di DOT fct DOT unl DOT pt>

Nuno Bandeira wrote:

>   Hi Leo,
>
> Leo Jingyu LEE wrote:
> > I have compiled the same program using both VC++ 6.0 (release version)
> > and g++ in cygwin, and found that the g++ version takes about three
> > times as much time as the VC++ version to run.  The program is basically
> > computionally intensive with some file reading/writing.  Any commments
> > on this?
>
>   I have the same problem but it looks to me that it is a more general
> efficiency problem. How fast is your cygwin on other operations, like listing
> a folder with a lot of files (ls -l /windows, for example) ? For me its also
> a lot slower than running dir c:\windows in command.com.
>   And lets not mention executing bash scripts...
>   Anyway, if I have to choose, I'll still go for cygwin.

The GNU Compiler Collection is as efficient on Win32 platforms as any other
platforms (eg. Unix) in terms of the code it generates.  You must give it
appropriate optimization command line switches for the best performance.

It is important to note that Cygwin and Mingw both use newlib as the C library
which is well known for its sluggish math routines when compared to glibc.

I think you will find the cygwin environment the reason for your performance
problems.  It is quite slow at invoking other executables which gcc does a lot
of.  I'm not sure if file creation is slow either.  You can try the --pipe
option.  This might improve the compilation speed but not the executable speed.
You can compiling for the Mingw environment (it uses the naitve microsoft
libraries and not the cygwin libraries) by using the --no-cygwin switch.  Mingw
is considerably faster that cygwin but it lacks the posix compatibility that
cygwin gives you.

Brendan Simon.



--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019