Subject: CCL:C++ vs Fortran performance

From: Jochen <[email-masked]>
Date: Wed, 29 Sep 1999 10:31:54 +0200

Well, I try to give a very cut-down summary:

FORTRAN 77 _compilers_ can be better because F77 optimization is NP while
C/C++ optimization is not.
(There are also aliasing issues, ... but these are way less important.)

C's and esp. C++'s data encapsulation, templates, ... provide better
possibilities to use inherent knowledge on the problem by using more
problem-specific algorithms (it's easier in C++, but basically could done
in FORTAN as well, of course - just not as nice).
Most important (from my experience) is to get better localisation/patterns
of memory access. (Again this can be done in F77 as well, but is usually
very ugly.)

So - in principle FORTRAN is faster, but in C++ it is easier to code
fast programs (faster than usual FORTRAN code).

Do you agree ?
-- Jochen
        Heinrich-Heine-Universität, Institut für Physikalische Chemie I
        Universitätsstr. 1, Geb. 26.43.02.29, 40225 Düsseldorf, Germany
phone 02118113681 fax 02118115195  --  www-public.rz.uni-duesseldorf.de/~jochen
[email-masked] -- [email-masked] -- [email-masked]

---

From: [email-masked]
Date: Thu, 30 Sep 1999 08:48:48 +0530 (IST)

Hi,
  could you explain a litle (or refer me to doc's that would) about f77
optimizing NP and C++ not.

TIA
Rajarshi Guha
<[email-masked]>