public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Vladimir Makarov <vmakarov@redhat.com>
To: Ian Lance Taylor <iant@google.com>
Cc: "Amker.Cheng" <amker.cheng@gmail.com>, gcc@gcc.gnu.org
Subject: Re: what does the calling for min_insn_conflict_delay mean
Date: Tue, 22 Sep 2009 15:50:00 -0000	[thread overview]
Message-ID: <4AB8F259.6050807@redhat.com> (raw)
In-Reply-To: <m3ocp4gd1u.fsf@google.com>

Ian Lance Taylor wrote:
> "Amker.Cheng" <amker.cheng@gmail.com> writes:
>
>   
>>    In function new_ready, it calls to min_insn_conflict_delay with
>> "min_insn_conflict_delay (curr_state, next, next)".
>> But the function's comments say that it returns minimal delay of issue of
>> the 2nd insn after issuing the 1st in given state.
>> Why the last two parameter for the call are both "next"?
>> seems conflict with the comments.
>>     
>
>   
Amker, thanks for finding this issue.
> This change dates back to the first DFA scheduler patch.  It does seem a
> little odd, particularly as the call in new_ready is the only use of
> min_insn_conflict_delay.  CC'ing vmakarov in case he remembers anything
> about this old code.
>   
I've not remembered this.  I guess  it was a result of long period of 
transition from the old pipeline hazard recognizier to the DFA one which 
required to rewrite all old pipeline descriptions.

Also after starring at this code for some time,  I don't like this 
code.  Now I'd use min_issue_delay (curr_state, next) which is delay of  
issuing  next in the current function unit reservation state instead of  
min_insn_conflict_delay (curr_state, next, next) which is a delay of 
issuing the first insn (next) after issuing the second insn (next) on a 
free processor (when all function units are free).  Probably it was a 
typo.  Although I think that such change (in many other conditions to 
move insn speculatively to the ready list) will not give a visible 
improvement for most processors, I'll try it.

It looks to me that probably I had also some plans for usage of 
min_insn_conflict_delay, but I forgot them because it was long ago.

  reply	other threads:[~2009-09-22 15:50 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-20 13:53 Amker.Cheng
2009-09-21 22:15 ` Ian Lance Taylor
2009-09-22 15:50   ` Vladimir Makarov [this message]
2009-09-23  9:34     ` Amker.Cheng

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=4AB8F259.6050807@redhat.com \
    --to=vmakarov@redhat.com \
    --cc=amker.cheng@gmail.com \
    --cc=gcc@gcc.gnu.org \
    --cc=iant@google.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).