* [Bug c++/21314] C++ performance regression with -Os
2005-05-01 8:30 [Bug c++/21314] New: C++ performance regression with -Os deemkay at gmail dot com
@ 2005-05-01 8:32 ` deemkay at gmail dot com
2005-05-01 13:34 ` pinskia at gcc dot gnu dot org
` (10 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: deemkay at gmail dot com @ 2005-05-01 8:32 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From deemkay at gmail dot com 2005-05-01 08:31 -------
Created an attachment (id=8780)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=8780&action=view)
cpptest.ii
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21314
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug c++/21314] C++ performance regression with -Os
2005-05-01 8:30 [Bug c++/21314] New: C++ performance regression with -Os deemkay at gmail dot com
2005-05-01 8:32 ` [Bug c++/21314] " deemkay at gmail dot com
@ 2005-05-01 13:34 ` pinskia at gcc dot gnu dot org
2005-05-01 13:35 ` pinskia at gcc dot gnu dot org
` (9 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-05-01 13:34 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2005-05-01 13:34 -------
-Os is compile for size if the size is smaller than there is no bug. We don't care about runtime speed
really at -Os.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21314
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug c++/21314] C++ performance regression with -Os
2005-05-01 8:30 [Bug c++/21314] New: C++ performance regression with -Os deemkay at gmail dot com
2005-05-01 8:32 ` [Bug c++/21314] " deemkay at gmail dot com
2005-05-01 13:34 ` pinskia at gcc dot gnu dot org
@ 2005-05-01 13:35 ` pinskia at gcc dot gnu dot org
2005-05-01 13:35 ` pinskia at gcc dot gnu dot org
` (8 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-05-01 13:35 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2005-05-01 13:35 -------
Oh, also I cannot reproduce the slow down that you are getting.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21314
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug c++/21314] C++ performance regression with -Os
2005-05-01 8:30 [Bug c++/21314] New: C++ performance regression with -Os deemkay at gmail dot com
` (2 preceding siblings ...)
2005-05-01 13:35 ` pinskia at gcc dot gnu dot org
@ 2005-05-01 13:35 ` pinskia at gcc dot gnu dot org
2005-05-01 13:36 ` [Bug target/21314] " pinskia at gcc dot gnu dot org
` (7 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-05-01 13:35 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2005-05-01 13:35 -------
Also this is a modified compiler from Gentoo, can you try an unmodified one.
--
What |Removed |Added
----------------------------------------------------------------------------
Version|4.0.0 |4.0.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21314
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/21314] C++ performance regression with -Os
2005-05-01 8:30 [Bug c++/21314] New: C++ performance regression with -Os deemkay at gmail dot com
` (3 preceding siblings ...)
2005-05-01 13:35 ` pinskia at gcc dot gnu dot org
@ 2005-05-01 13:36 ` pinskia at gcc dot gnu dot org
2005-05-01 14:26 ` giovannibajo at libero dot it
` (6 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-05-01 13:36 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
Component|c++ |target
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21314
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/21314] C++ performance regression with -Os
2005-05-01 8:30 [Bug c++/21314] New: C++ performance regression with -Os deemkay at gmail dot com
` (4 preceding siblings ...)
2005-05-01 13:36 ` [Bug target/21314] " pinskia at gcc dot gnu dot org
@ 2005-05-01 14:26 ` giovannibajo at libero dot it
2005-05-01 18:09 ` deemkay at gmail dot com
` (5 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: giovannibajo at libero dot it @ 2005-05-01 14:26 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From giovannibajo at libero dot it 2005-05-01 14:26 -------
Yes, mostly we don't care, but it's a two-fold regression so it should be
justified by a significant decrease in size, otherwise it's just a bad
regression. I almost think it's because of Honza's inline patches.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21314
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/21314] C++ performance regression with -Os
2005-05-01 8:30 [Bug c++/21314] New: C++ performance regression with -Os deemkay at gmail dot com
` (5 preceding siblings ...)
2005-05-01 14:26 ` giovannibajo at libero dot it
@ 2005-05-01 18:09 ` deemkay at gmail dot com
2005-05-02 1:17 ` [Bug target/21314] C++ size and " deemkay at gmail dot com
` (4 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: deemkay at gmail dot com @ 2005-05-01 18:09 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From deemkay at gmail dot com 2005-05-01 18:08 -------
hmm. code size is actually bigger with -Os.
-rwxr-xr-x 1 dirtyepic users 15689 May 1 12:02 pr21314-O0
-rwxr-xr-x 1 dirtyepic users 8333 May 1 12:02 pr21314-O1
-rwxr-xr-x 1 dirtyepic users 8405 May 1 11:35 pr21314-O2
-rwxr-xr-x 1 dirtyepic users 8157 May 1 12:03 pr21314-O3
-rwxr-xr-x 1 dirtyepic users 12989 May 1 11:35 pr21314-Os
( $ g++ -Ox -Wall -march=pentium3 cpptest.cpp -o pr21314-Ox )
the only modification should be the branding.. but if you can't reproduce i
must have overlooked something. i'll do a manual build and see if it goes away.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21314
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/21314] C++ size and performance regression with -Os
2005-05-01 8:30 [Bug c++/21314] New: C++ performance regression with -Os deemkay at gmail dot com
` (6 preceding siblings ...)
2005-05-01 18:09 ` deemkay at gmail dot com
@ 2005-05-02 1:17 ` deemkay at gmail dot com
2005-05-02 1:17 ` [Bug target/21314] C++ " deemkay at gmail dot com
` (3 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: deemkay at gmail dot com @ 2005-05-02 1:17 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
Summary|C++ performance regression |C++ size and performance
|with -Os |regression with -Os
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21314
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/21314] C++ performance regression with -Os
2005-05-01 8:30 [Bug c++/21314] New: C++ performance regression with -Os deemkay at gmail dot com
` (7 preceding siblings ...)
2005-05-02 1:17 ` [Bug target/21314] C++ size and " deemkay at gmail dot com
@ 2005-05-02 1:17 ` deemkay at gmail dot com
2005-05-03 13:42 ` [Bug target/21314] C++ size and " ivan at yosifov dot net
` (2 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: deemkay at gmail dot com @ 2005-05-02 1:17 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From deemkay at gmail dot com 2005-05-02 01:17 -------
dirtyepic ~/work $ ~/gcc-4.0-20050430/bin/g++ -O0 -Wall -march=pentium3
cpptest.cpp -o new-pr21314-O0
dirtyepic ~/work $ ~/gcc-4.0-20050430/bin/g++ -O1 -Wall -march=pentium3
cpptest.cpp -o new-pr21314-O1
dirtyepic ~/work $ ~/gcc-4.0-20050430/bin/g++ -O2 -Wall -march=pentium3
cpptest.cpp -o new-pr21314-O2
dirtyepic ~/work $ ~/gcc-4.0-20050430/bin/g++ -O3 -Wall -march=pentium3
cpptest.cpp -o new-pr21314-O3
dirtyepic ~/work $ ~/gcc-4.0-20050430/bin/g++ -Os -Wall -march=pentium3
cpptest.cpp -o new-pr21314-Os
-rwxr-xr-x 1 dirtyepic users 15609 May 1 18:59 new-pr21314-O0
-rwxr-xr-x 1 dirtyepic users 8245 May 1 18:59 new-pr21314-O1
-rwxr-xr-x 1 dirtyepic users 8317 May 1 18:59 new-pr21314-O2
-rwxr-xr-x 1 dirtyepic users 8069 May 1 18:59 new-pr21314-O3
-rwxr-xr-x 1 dirtyepic users 12901 May 1 18:59 new-pr21314-Os
dirtyepic ~/work $ ./new-pr21314-O0
0
time: 20.420000
dirtyepic ~/work $ ./new-pr21314-O1
0
time: 7.490000
dirtyepic ~/work $ ./new-pr21314-O2
0
time: 6.950000
dirtyepic ~/work $ ./new-pr21314-O3
0
time: 7.030000
dirtyepic ~/work $ ./new-pr21314-Os
0
time: 16.680000
the performance regression i can understand is not a priority. but the size
regression is surprising.
dirtyepic ~/work $ ~/gcc-4.0-20050430/bin/g++ -v
Using built-in specs.
Target: i686-pc-linux-gnu
Configured with: ../gcc-4.0-20050430/configure
--enable-version-specific-runtime-libs
--prefix=/home/dirtyepic/gcc-4.0-20050430/ --host=i686-pc-linux-gnu
--build=i686-pc-linux-gnu --disable-altivec --disable-nls --with-system-zlib
--disable-checking --disable-werror --disable-libunwind-exceptions
--disable-multilib --disable-libgcj --enable-languages=c,c++ --enable-shared
--enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu
Thread model: posix
gcc version 4.0.1 20050430 (prerelease)
let me know if there's any other data that would help.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21314
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/21314] C++ size and performance regression with -Os
2005-05-01 8:30 [Bug c++/21314] New: C++ performance regression with -Os deemkay at gmail dot com
` (8 preceding siblings ...)
2005-05-02 1:17 ` [Bug target/21314] C++ " deemkay at gmail dot com
@ 2005-05-03 13:42 ` ivan at yosifov dot net
2005-05-12 8:10 ` dann at godzilla dot ics dot uci dot edu
2005-05-21 7:33 ` deemkay at gmail dot com
11 siblings, 0 replies; 13+ messages in thread
From: ivan at yosifov dot net @ 2005-05-03 13:42 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |ivan at yosifov dot net
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21314
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/21314] C++ size and performance regression with -Os
2005-05-01 8:30 [Bug c++/21314] New: C++ performance regression with -Os deemkay at gmail dot com
` (9 preceding siblings ...)
2005-05-03 13:42 ` [Bug target/21314] C++ size and " ivan at yosifov dot net
@ 2005-05-12 8:10 ` dann at godzilla dot ics dot uci dot edu
2005-05-21 7:33 ` deemkay at gmail dot com
11 siblings, 0 replies; 13+ messages in thread
From: dann at godzilla dot ics dot uci dot edu @ 2005-05-12 8:10 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From dann at godzilla dot ics dot uci dot edu 2005-05-12 08:09 -------
(In reply to comment #6)
> hmm. code size is actually bigger with -Os.
>
> -rwxr-xr-x 1 dirtyepic users 15689 May 1 12:02 pr21314-O0
> -rwxr-xr-x 1 dirtyepic users 8333 May 1 12:02 pr21314-O1
> -rwxr-xr-x 1 dirtyepic users 8405 May 1 11:35 pr21314-O2
> -rwxr-xr-x 1 dirtyepic users 8157 May 1 12:03 pr21314-O3
> -rwxr-xr-x 1 dirtyepic users 12989 May 1 11:35 pr21314-Os
Don't look at the sizes shown by 'ls -l' look at the text size (as shown by
size -f)
You can also use 'nm' to see the size of the main function (all the interesting
code is in there, right?)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21314
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug target/21314] C++ size and performance regression with -Os
2005-05-01 8:30 [Bug c++/21314] New: C++ performance regression with -Os deemkay at gmail dot com
` (10 preceding siblings ...)
2005-05-12 8:10 ` dann at godzilla dot ics dot uci dot edu
@ 2005-05-21 7:33 ` deemkay at gmail dot com
11 siblings, 0 replies; 13+ messages in thread
From: deemkay at gmail dot com @ 2005-05-21 7:33 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From deemkay at gmail dot com 2005-05-21 07:33 -------
i think this might be a dupe of #21529, and the original person who provided the
code has also opened a PR (although for a different reason), so i'd like to
close this. thanks anyways.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |INVALID
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21314
^ permalink raw reply [flat|nested] 13+ messages in thread