This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Quality of GCC 3.1


Hi.

On: Mon, 17 Jun 2002 23:05:00 +0200,
    Wit Jakuczun <wj178839@wp.pl> wrote:
> I have few comments and questions on quality of code generated by g++ 
> >from GCC 3.1.
> 
> 1) Compiler seems to be much slower than GCC 2.95.2 (3 times on average).
> 	The code heavily uses STL and exceptions. 

For compiling a whole distribution, it is not that much slower - I can
try to produce some statistic for arround 400 packages if needed.

But considering the feature improvements (Better ANSI-C++ support and
new optimizations it is quite reasonable that it got slower ...

> 2) Code generated is much slower (3 times on average) especially if streams
> 	are used.

For our case (also exceptions and templates) the code is smaller.

gcc-2.95.3:
root@jackson:/ > du -csb usr/lib/gsmp/* usr/bin/gsmp
163840  usr/lib/gsmp/DeveloperFX.plugin.so
397312  usr/lib/gsmp/Dialogs-gtk.plugin.so
204800  usr/lib/gsmp/DynamicsFX.plugin.so
364544  usr/lib/gsmp/FrequencyFX.plugin.so
512000  usr/lib/gsmp/GUI-gtk.plugin.so
45056   usr/lib/gsmp/Toolkit-gtk.plugin.so
53248   usr/lib/gsmp/VolumeFX.plugin.so
184320  usr/lib/gsmp/gsmp-main.plugin.so
49152   usr/lib/gsmp/libIIRFilters.so
147456  usr/lib/gsmp/libToolkitBasics-gtk.so
32768   usr/bin/gsmp
2154496 total

gcc-3.1:
root@jackson:/rock-linux/rock-1.7/build/default-1.7.0-DEV-ia32-pentium-generic-expert/root > du -csb usr/lib/gsmp/* usr/bin/gsmp
126976  usr/lib/gsmp/DeveloperFX.plugin.so
434176  usr/lib/gsmp/Dialogs-gtk.plugin.so
155648  usr/lib/gsmp/DynamicsFX.plugin.so
282624  usr/lib/gsmp/FrequencyFX.plugin.so
544768  usr/lib/gsmp/GUI-gtk.plugin.so
36864   usr/lib/gsmp/Toolkit-gtk.plugin.so
28672   usr/lib/gsmp/VolumeFX.plugin.so
118784  usr/lib/gsmp/gsmp-main.plugin.so
40960   usr/lib/gsmp/libIIRFilters.so
180224  usr/lib/gsmp/libToolkitBasics-gtk.so
16384   usr/bin/gsmp
1966080 total

Also we still debug some runtime segmentatin fault problems (which
might be related to our code - and so not a fault of gcc-3.1). So I
have no speed values for this project.

But for my other test cases gcc-3.1 produces faster code.

> Questions:
> a)	What is the reason of such big decrease in performance especially if
> 	exceptions and/or streams are used?
> b)	Is it a problem of setting correct options for GCC 3.1?
> c)	Where can I find a good comparison of C++ compilers?
> 
> Options I used to make GCC3.1 (using GCC 2.92.2):
> --enable-threads --enable-nls --enable-cstdio=stdio
> 
> 
> With regards
> 	Wit Jakuczun

k33p h4ck1n6
  René

--  
René Rebe (Registered Linux user: #248718 <http://counter.li.org>)
e-mail:   rene.rebe@gmx.net, rene@rocklinux.org
web:      www.rocklinux.org, drocklinux.dyndns.org/rene/

Anyone sending unwanted advertising e-mail to this address will be
charged $25 for network traffic and computing time. By extracting my
address from this message or its header, you agree to these terms.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]