public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jan Hubicka <hubicka@ucw.cz>
To: Vladimir Makarov <vmakarov@redhat.com>
Cc: Ghassan Shobaki <gshobaki@ece.ucdavis.edu>,
	Jan Hubicka <jh@suse.cz>, Jan Hubicka <hubicka@ucw.cz>,
	gcc-help@gcc.gnu.org, gcc@gnu.org
Subject: Re: Superblock Scheduling Alg in GCC
Date: Tue, 10 Feb 2004 20:28:00 -0000	[thread overview]
Message-ID: <20040210202725.GJ1382@atrey.karlin.mff.cuni.cz> (raw)
In-Reply-To: <40293C78.4000303@redhat.com>

> Vladimir Makarov wrote:
> 
> >Ghassan Shobaki wrote:
> >
> >>Are there any documents describing the algorithm used in the 
> >>superblock instruction scheduler?
> >>
> >I don't know one.
> >
> >>Does it use any (or a combination of) of published techniques such as 
> >>critical path and speculative hedge and successive retirement ..etc? 
> >>Or it just has its own algorithm?
> >>
> >>
> >>
> >It uses own algorithm which was grown from original haifa-scheduler.   
> >Earlier it was one file which was divided.  Superblock scheduler uses 
> >code of sched-deps.c and haifa-sched.c and directs them through a few 
> >hooks.
> >
> >Generally speaking suberblock is believed to be a basic block to which 
> >list scheduling is applied.  The superblock scheduler just checks that 
> >the insn can be issued speculatively and prefer to issue more 
> >frequently executed insns when the priority is the same (and now when 
> >insn register weights are the same).  But calculation of insn 
> >priorities does not take basic block frequencies (or belonging to 
> >different basic blocks) into account.  So the algorithm is very simple.
> >
> >No more advanced approaches like heuristics based on critical path to 
> >the last exit of superblock, dependence height and speculative yeild 
> >(taking block excution probability into account when the insn priority 
> >is calculated), sucessive retirment (preference of non-speculative 
> >insn movement first), or speculative hedge aiming to achieve minimal 
> >delay to all exits are used.
> >
> >So there are a lot of things to improve the code.  But it will be not 
> >easy to add them because big part of code is used by the region based 
> >scheduler too.
> 
> Sorry, I forgot too add that what I wrote is about extended basic block 
> scheduler (file sched-ebb.c) which is used for Itanium as a default 
> after the register allocation.  If you are intersting in Jan Hubicka's 
> trace scheduler, I think that Jan's answer will be more competent.

I really didn't changed much in the algorithm.  All I was interested in
was to make it work with CFG and plugged in the tail duplication pass.
So your description is still valid.
The code has little logic to avoid moving instructions too much up and
adding some extra heuristics shall not be that dificult, but I didn't
read the papers on topic very curefully :)


Honza
> 
> Vlad
> 

  reply	other threads:[~2004-02-10 20:28 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-12-03  7:07 Superblock Instruction Scheduling " Ghassan Shobaki
2003-12-03 14:05 ` Vladimir N. Makarov
2003-12-04  0:13   ` Jan Hubicka
2003-12-04  1:30     ` Ghassan Shobaki
2003-12-04 10:49       ` Jan Hubicka
2003-12-04 17:40         ` Vladimir Makarov
2003-12-09 21:45     ` Ghassan Shobaki
2004-01-28  3:26     ` Superblock Instruction Scheduling in GCC 3.4 Ghassan Shobaki
2004-01-28 12:51       ` Jan Hubicka
2004-01-29 10:14         ` Ghassan Shobaki
2004-01-29 11:15           ` Jan Hubicka
2004-02-01 18:19             ` Ghassan Shobaki
2004-02-01 21:56               ` Jan Hubicka
2004-02-02  5:54                 ` Ghassan Shobaki
2004-02-10 18:58                 ` Superblock Scheduling Alg in GCC Ghassan Shobaki
2004-02-10 20:10                   ` Vladimir Makarov
2004-02-10 20:18                     ` Vladimir Makarov
2004-02-10 20:28                       ` Jan Hubicka [this message]
2004-04-14 17:40                         ` Ghassan Shobaki
2004-04-15  8:44                           ` Vladimir Makarov
2004-05-27 14:12                         ` Ghassan Shobaki

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=20040210202725.GJ1382@atrey.karlin.mff.cuni.cz \
    --to=hubicka@ucw.cz \
    --cc=gcc-help@gcc.gnu.org \
    --cc=gcc@gnu.org \
    --cc=gshobaki@ece.ucdavis.edu \
    --cc=jh@suse.cz \
    --cc=vmakarov@redhat.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).