public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: fanqifei <fanqifei@gmail.com>
To: Jim Wilson <wilson@codesourcery.com>
Cc: gcc@gcc.gnu.org
Subject: Re: constant hoisting out of loops
Date: Thu, 18 Mar 2010 17:10:00 -0000	[thread overview]
Message-ID: <f94afa701003181006r761ca89r547e0ad4338f78c@mail.gmail.com> (raw)
In-Reply-To: <1268850652.2587.9.camel@localhost>

On Thu, Mar 18, 2010 at 2:30 AM, Jim Wilson <wilson@codesourcery.com> wrote:
> On Wed, 2010-03-17 at 11:27 +0800, fanqifei wrote:
>> You are correct. The reload pass emitted the clr.w insn.
>> However, I can see loop opt passes after reload:
>> problem1.c.174r.loop2_invariant1
>
> Not unless you have a modified toolchain.  We don't run loop opt after
> register allocation.  See the list of optimization passes in the FSF GCC
> passes.c file.  loop2 occurs before ira/postreload.  If you do have a
> modified toolchain, then I doubt that the current loop passes would work
> right, since they were designed to handle pseudo-regs not hard-regs.
>
> Jim
>
>
>
That passes were added by me more than two months ago. I thought these
passes could perform the optimization of hoisting constant out of
loop.
I just removed them.  Thanks very much for your help!
Now I am working on the movsi expander.

-- 
-Qifei Fan
http://freshtime.org

  reply	other threads:[~2010-03-18 17:06 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-03-11  6:48 fanqifei
2010-03-14 21:39 ` Jim Wilson
2010-03-17 12:55   ` fanqifei
2010-03-17 19:16     ` Jim Wilson
2010-03-18 17:10       ` fanqifei [this message]
     [not found]         ` <f94afa701003190704l6a8a97bfs66817322dc1eb8f7@mail.gmail.com>
2010-03-19 14:51           ` Fwd: " fanqifei
2010-03-19 22:30             ` Jim Wilson
2010-03-20 16:40               ` fanqifei
2010-03-20 19:40                 ` Jim Wilson
2010-03-20 19:44                   ` fanqifei
2010-03-21 10:42                     ` Jim Wilson
2010-03-21 22:46                       ` fanqifei

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=f94afa701003181006r761ca89r547e0ad4338f78c@mail.gmail.com \
    --to=fanqifei@gmail.com \
    --cc=gcc@gcc.gnu.org \
    --cc=wilson@codesourcery.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).