This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: (RFA): Enable first scheduling pass for SH4


Vladimir N. Makarov Wrote 
> "Sanjiv Kumar Gupta, Noida" wrote:
> 
> > > On Wed, Sep 03, 2003 at 01:56:26PM +0530, Sanjiv Kumar Gupta,
> > > Noida wrote:
> > > > The overall idea is to keep count of SImode and SFmode regs
> > > required by
> > > > already scheduled insns.
> > >
> > > I don't think this should at all be done via magic hooks in
> > > the sh backend.
> >
> > The heuristics are pretty target specific. Do you think,
> > I should change the generic scheduler for this?
> >
> 
> I think Richard is right.  You could make it more general (register
> pressure calculation and reordering ready queue) because it could be
> profitable for other ports (like arm or sparc)  too.  Then the most of
> code could be in the scheduler itself.  And may be one hook 
> to switch on
> (off) the heuristic for ports which could have benefit from this
> heuristic.  If there is no harm from this for all ports, the 
> hook could
> be removed.
 
It is good idea to make this patch target independent. However,
significant effort is required to fine-tune heuristics for all 
targets. I would like to do it, but it is out of scope of my 
current project; and a more severe constraint is that 
I don't have resources to test it on multiple targets. 
 
> Another question, I see results only with and without the 1st insn
> scheduling.  They are impressive.  But having results with and without
> register pressure heuristics is more appropriate (may be they will be
> more impressive). 

I understand your point.
For SH4, the comparison (with and without heuristics) will look 
very impressive (something like 30-40% improvement). 
The current comparison  is to show that first 
scheduling pass can increase performance. The fact that very 
bad code is generated without any heuristics, is known, and had
led to its "turning off" for the SH.
Anyway, I will try to make the report with and without 
heuristics too. 
 

> It is also interesting to look at the SPEC (95 or
> 2000) results too.  I saw many times when small benchmarks (with few
> loops) got the performance improvement but SPEC benchmarks (like gcc)
> got the degradation.  If it is not possible that is ok (unfortunately
> many people have no access to SPEC).

I don't have access to SPEC benchmarks. So I had to test with "free" 
benchmarks.

Regards,
  Sanjiv.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]