This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
RE: -Os in conjunction with -fno-inline
- From: Ryan Mansfield <RMansfield at qnx dot com>
- To: "'ilejn at yandex dot ru'" <ilejn at yandex dot ru>, gcc-help at gcc dot gnu dot org
- Date: Fri, 30 Sep 2005 01:41:11 -0400
- Subject: RE: -Os in conjunction with -fno-inline
The idea of inlining is to remove function prologues and epilogues. When you
set -fno-inline, the functions do not get inlined and the prologues and
epilogues account for the slight increase in size.
Inlining can result in some code bloat when procedure cloning is done.
Regards,
Ryan Mansfield
-----Original Message-----
From: gcc-help-owner@gcc.gnu.org [mailto:gcc-help-owner@gcc.gnu.org] On
Behalf Of Ilja Golshtein
Sent: Friday, September 30, 2005 1:26 AM
To: gcc-help@gcc.gnu.org
Subject: -Os in conjunction with -fno-inline
Hello!
I've came across with a strange thing.
After adding "-fno-inline" to g++ command line just after "-Os" size of
binary was slightly increased.
Two question. Why any difference exists? Why size increased not reduced? The
code optimized indeed.
I use gcc 3.2.2 from RH 9.0 distribution.
No optimization related options besides mentioned above.
Thanks.
--
Best regards
Ilja Golshtein