From: luke@navo.hpc.mil (Luke Lonergan)
Subject: Re: MFlops Comparison using g77 (bad news) - bench.tgz (0/1)
Date: 1997/09/23 [thread overview]
Message-ID: <6078oc$5dv@bgtnsc02.worldnet.att.net> (raw)
In-Reply-To: 6060pv$kn6@news.cis.okstate.edu
On 22 Sep 1997 14:53:51 GMT, jwest@jwest.ecen.okstate.edu (Jim West)
wrote:
>I'm wondering if an optimizing compiler sould pick this up even without the
>explicit definition of nx_r. Can anyone explain why it wouldn't?
Well, it might all be unnecessary if we could gain the wisdom of
Robert's implementation :-)
The one thing I was trying to do was get as close to the FORTRAN
version's efficiency on the non-Alpha platforms. I succeeded on the
Pentium Pro and Pentium machines. One reason why is that the FORTRAN
code benefits greatly from hardcoding of dimensions. That is, if you
explicitly put the 1002,1002 numbers in the FORTRAN kernel, you get a
great (~20%) performance increase.
I think I am doing the same thing when I localize the reference to the
nx dimension in the C kernel by putting it into stack (and through
optimization into register). I did this after looking at the assembler
code in the two versions of the FORTRAN kernel, with and without the
hardcoded dimensions and found a lot of address resolution in one
where the other simply had a $### telling it how far to advance the
reference. I can't think of a way to explicitly code this same
approach in FORTRAN, though I am pretty sure that a lot of other
compilers do the same thing I did in the C kernel.
Luke
next prev parent reply other threads:[~1997-09-23 4:00 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <5vqs28$3el@news-rocq.inria.fr>
1997-09-22 4:00 ` MFlops Comparison using g77 (bad news) - bench.tgz (0/1) Luke Lonergan
1997-09-22 4:00 ` Jim West
1997-09-23 4:00 ` Greg Lindahl
1997-09-23 4:00 ` Volker Barthelmann
1997-09-26 4:00 ` H.W. Stockman
1997-09-26 4:00 ` Greg Lindahl
1997-09-28 4:00 ` H.W. Stockman
1997-09-28 4:00 ` Greg Lindahl
1997-09-27 4:00 ` Toon Moene
1997-09-23 4:00 ` Luke Lonergan [this message]
1997-09-22 4:00 ` Greg Lindahl
1997-09-22 4:00 ` Greg Lindahl
1997-09-16 4:00 MFlops Comparison using g77 (bad news) Luke Lonergan
1997-09-16 4:00 ` Toon Moene
1997-09-16 4:00 ` MFlops Comparison using g77 (bad news) - bench.tgz (0/1) Luke Lonergan
1997-09-18 4:00 ` Thomas Leitner
1997-09-18 4:00 ` Andrew G. Morgan
1997-09-18 4:00 ` H.W. Stockman
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox