From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1164f8,2f3b7c37a50d04e6 X-Google-Attributes: gid1164f8,public X-Google-Thread: 109fba,2f3b7c37a50d04e6 X-Google-Attributes: gid109fba,public X-Google-ArrivalTime: 1993-12-02 01:30:09 PST Xref: gmd.de comp.lang.c++:39552 comp.sys.dec:12172 Path: gmd.de!newsserver.jvnc.net!yale.edu!nigel.msen.com!sdd.hp.com!elroy.jpl.nasa.gov!swrinde!cs.utexas.edu!uunet!pipex!sunic!news.lth.se!dag From: dag@control.lth.se (Dag Bruck) Newsgroups: comp.lang.c++,comp.sys.dec Subject: Re: Should we re-host to C++?? Date: 2 Dec 1993 07:23:32 GMT Organization: Department of Automatic Control, Lund, Sweden Message-ID: <2dk55k$207@nic.lth.se> References: <2dk0vo$gf6@aludra.usc.edu> NNTP-Posting-Host: control.lth.se Keywords: fortran,c++,dec In manson@aludra.usc.edu (Dirk Manson) writes: > * Data crunching vs data management is split 30/70 in lines of code > * Data crunching vs data management is split 80/20 in CPU usage Under these assumptions, > * Building our main system in C++, using Fortran for CPU hogs seems like a good idea. You will rewrite the parts where you can expect the biggest reduction in code size (the data management), and leave the rest if you run out of time. My gut feeling is that a C++ program will probably run faster that your FORTRAN program. My claim has nothing to do with compiler quality etc.; it is just that a well-designed C++ program is much easier to improve than a badly designed FORTRAN program. Data abstraction in C++ makes practically feasible to change a data structure without changing all the code that uses that data structure. For example, consider what it would take to change from a conventional matrix type to a sparse matrix type in FORTRAN: for starters, you would have to change every function call that operates on you matrix type. In C++ you just add new functions and operators, and let overloading take care of the program conversion. Many of the advatages of C++ has nothing to do with OOP. -- Dag