Re: Intermediate Representation

ok@goanna.cs.rmit.OZ.AU (Richard A. O'Keefe)
Mon, 20 Aug 90 02:00:02 GMT

          From comp.compilers

Related articles
[15 earlier articles]
Re: Intermediate Representation preston@titan.rice.edu (1990-08-13)
Re: Intermediate Representation jouvelot@brokaw.lcs.mit.edu (1990-08-13)
Re: Intermediate Representation marti@antares.inf.ethz.ch (1990-08-13)
Re: Intermediate Representation muller@procope.pa.dec.com (Eric Muller) (1990-08-14)
Re: Intermediate Representation pd@complex.Eng.Sun.COM (1990-08-15)
Re: Intermediate Representation staff@cadlab.sublink.org (1990-08-18)
Re: Intermediate Representation ok@goanna.cs.rmit.OZ.AU (1990-08-20)
intermediate representation han@cs.rochester.edu (1991-02-20)
Re: intermediate representation lavinus@csgrad.cs.vt.edu (1991-02-22)
Re: intermediate representation mike@vlsivie.tuwien.ac.at (1991-02-23)
Re: intermediate representation rfg@ncd.com (1991-02-26)
Re: intermediate representation megatest!djones@decwrl.dec.com (1991-02-27)
Re: intermediate representation tarvydas@turing.toronto.edu (1991-03-04)
| List of all articles for this month |
Newsgroups: comp.compilers
From: ok@goanna.cs.rmit.OZ.AU (Richard A. O'Keefe)
Keywords: optimize, C, Fortran
Organization: Comp Sci, RMIT, Melbourne, Australia
References: <1990Aug07.153407.8877@esegue.segue.boston.ma.us> <250@cadlab.sublink.ORG>
Date: Mon, 20 Aug 90 02:00:02 GMT

In article <250@cadlab.sublink.ORG>, staff@cadlab.sublink.org (Alex Martelli) writes:
> marti@antares.inf.ethz.ch writes:
> ...and don't forget Fortran... (see my msg of today in comp.lang.fortran-
> f2c + Sun's cc produce code which runs almost twice as fast as Sun's
> f77, for a strictly numerical code -2d complex fft- on a Sparcstation 1!).


On reading this I immediately went and converted a small numerical code
from Fortran to C and ran it on an Encore MultiMax (NS 32532 processors)
running UMAX V 2.2M. The f77 and cc compilers on that machine do not appear
to be ATT or Berkeley derived; the f77 compiler in particular is described
as "an advanced, optimizing compiler". The code didn't exploit any of the
micro-tasking or parallel features of Encore Fortran or Encore C, and no
special declarations ('register' or the like) were used. Both used double
precision. Result: the C code ran twice as fast (4 seconds / 8 seconds).


The Fortran code used 2D arrays. The C code used 1D with strength reduction
(a standard optimising technique) done by hand, and indexing replaced by
pointer increments (also a standard technique, and the NS32532 doesn't use
auto-??crement addressing) by hand. f2c starts to sound interesting...


So it wasn't just Sun. (I say "wasn't" because as the original poster
pointed out, Sun have some new compilers.)
--


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.