Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 264653 (PR39657) - gcc 4.3.2-r3 will compile some files very slowly
Summary: gcc 4.3.2-r3 will compile some files very slowly
Status: RESOLVED FIXED
Alias: PR39657
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] GCC Porting (show other bugs)
Hardware: AMD64 Linux
: High normal (vote)
Assignee: Gentoo Toolchain Maintainers
URL: http://gcc.gnu.org/PR39657
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-04-02 16:10 UTC by Flavio Cappelli
Modified: 2010-09-06 22:21 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
test file (parse_.c,555.30 KB, text/plain)
2009-04-02 16:13 UTC, Flavio Cappelli
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Flavio Cappelli 2009-04-02 16:10:44 UTC
See the file parse_.c:

time gcc -O2 -g -Wall -Wno-parentheses -o parse.o -c parse_.c

results on Athlon64 (64bit system)
==================================

 with gcc-4.1.2

     real    0m7.805s
     user    0m7.603s
     sys     0m0.191s

with gcc-4.3.2-r3

     real    5m16.777s
     user    5m14.586s
     sys     0m1.545s

results on Core 2 Duo (64bit system)
====================================

with gcc-4.1.2

     real    0m4.142s
     user    0m4.022s
     sys     0m0.118s

with gcc-4.3.2-r3

     real    2m47.787s
     user    2m47.346s
     sys     0m0.378s

gcc -v (4.3.2, march=core2 on Core2Duo, march=athlon64 on Athlon64)
===================================================================
Using built-in specs.
Target: x86_64-pc-linux-gnu
Configured with: /var/tmp/portage/sys-devel/gcc-4.3.2-r3/work/gcc-4.3.2/configure --prefix=/usr --bindir=/usr/x86_64-pc-linux-gnu/gcc-bin/4.3.2 --includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.3.2/include --datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.3.2 --mandir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.3.2/man --infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.3.2/info --with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.3.2/include/g++-v4 --host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --disable-altivec --disable-fixed-point --enable-nls --without-included-gettext --with-system-zlib --disable-checking --disable-werror --enable-secureplt --enable-multilib --disable-libmudflap --disable-libssp --enable-libgomp --enable-java-awt=gtk --enable-languages=c,c++,java,treelang,fortran --enable-shared --enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu --with-bugurl=http://bugs.gentoo.org/ --with-pkgversion='Gentoo 4.3.2-r3 p1.6, pie-10.1.5'
Thread model: posix
gcc version 4.3.2 (Gentoo 4.3.2-r3 p1.6, pie-10.1.5)

gcc -v (4.1.2, march=nocona on Core2Duo, march=athlon64 on Athlon64)
====================================================================
Using built-in specs.
Target: x86_64-pc-linux-gnu
Configured with: /var/tmp/portage/sys-devel/gcc-4.1.2/work/gcc-4.1.2/configure --prefix=/usr --bindir=/usr/x86_64-pc-linux-gnu/gcc-bin/4.1.2 --includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.1.2/include --datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.1.2 --mandir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.1.2/man --infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.1.2/info --with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.1.2/include/g++-v4 --host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --disable-altivec --enable-nls --without-included-gettext --with-system-zlib --disable-checking --disable-werror --enable-secureplt --enable-multilib --disable-libmudflap --disable-libssp --enable-java-awt=gtk --enable-languages=c,c++,java,treelang,fortran --enable-shared --enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu
Thread model: posix
gcc version 4.1.2 (Gentoo 4.1.2 p1.3)

USED CFLAGS/CXXFLAGS/LDFLAGS
============================
CFLAGS="-march=(see above) -O2 -pipe"
LDFLAGS="-Wl,-O1 -Wl,--sort-common -Wl,--as-needed"
CXXFLAGS="${CFLAGS}"



Reproducible: Always

Steps to Reproduce:
1.emerge gcc-4.3.2-r3
2.gcc-config x86_64-pc-linux-gnu-4.3.2
3.source /etc/profile
4.time gcc -O2 -g -Wall -Wno-parentheses -o parse.o -c parse_.c
5.repeate the test using gcc-4.1.2

Actual Results:  
gcc-4.3.2 compile very slowly some files compared to older compiler, so it seems affected by some bugs.

Expected Results:  
Please stabilize a new gcc version only when it rocks!
Comment 1 Flavio Cappelli 2009-04-02 16:13:03 UTC
Created attachment 187099 [details]
test file
Comment 2 SpanKY gentoo-dev 2009-04-02 17:14:20 UTC
consider it an incentive to write smaller code ;)
Comment 3 SpanKY gentoo-dev 2009-04-06 00:51:06 UTC
seems to be unique to gcc-4.3 ... 4.1, 4.2, and 4.4 all take less than 30 seconds

i'm not terribly hopeful that this will be resolved
Comment 4 Mark Loeser (RETIRED) gentoo-dev 2010-09-06 22:21:28 UTC
GCC 4.4 seems to work just fine.