From: Jeff Law <law@redhat.com>
To: Andrew Haley <aph@redhat.com>
Cc: Xin Tong <xerox.time.tech@gmail.com>, gcc-help@gcc.gnu.org
Subject: Re: gcc compile for code size
Date: Sun, 11 Nov 2012 21:09:00 -0000 [thread overview]
Message-ID: <50A013EB.3020402@redhat.com> (raw)
In-Reply-To: <50A01210.7020607@redhat.com>
On 11/11/2012 02:01 PM, Andrew Haley wrote:
> On 11/11/2012 07:59 PM, Xin Tong wrote:
>>> No. GCC does all optimizations *except* those known to increase
>>> program size. This usually works pretty well, but isn't perfect.
>>>
>> so as to how the instructions are selected. compiling for code size
>> does not have an effect ?
>
> Please don't top-post on this list.
>
> Any target could, in principle, select instructions based on size
> and -OS, but I don't know any that do.
Many ports look at at -Os and change their instruction selections,
alignment requests, etc.
grep for "optimize_size" in the machine descriptions...
jeff
next prev parent reply other threads:[~2012-11-11 21:09 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-11 19:47 Xin Tong
2012-11-11 19:54 ` Andrew Haley
2012-11-11 19:59 ` Xin Tong
2012-11-11 21:01 ` Andrew Haley
2012-11-11 21:09 ` Jeff Law [this message]
2012-11-11 21:32 ` Andrew Haley
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=50A013EB.3020402@redhat.com \
--to=law@redhat.com \
--cc=aph@redhat.com \
--cc=gcc-help@gcc.gnu.org \
--cc=xerox.time.tech@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).