Mail Archives: djgpp/1998/03/05/20:37:15
Bum-Seok Hyun wrote:
> Hi!!!
>
> I'm not sure that I can write this newsgroup on my problem,
> but I guess somebody can help me.
>
> I'm using DJGPP as C++ compiler on my pc.
> My research area is CFD and I have done much work
> using Fortran 77.
>
> I can't say I hate Fortran, but I feel like moving to
> more flexible language.
>
> So I made a test for comparing computing time.
> The result is
> c code : 21 sec
> c++ code : 57 sec
> Fortran77 code : 115 sec
>
> The test code is quite simple, consisted of 3 nested "for" loops.
>
> I don't understand this situation.
>
> I've read manuals and they told me
> computing time should be at least close between C and C++
>
> Does this mean that C++(or DJGPP) is not suitable
> for numerical computation?
>
> Thanks in advance
>
> Bum-Seok Hyun
This whole thread is only a demonstration of the performance penalties
that can be suffered as a result of poor coding praciticies. Don't
reinvent the wheel a billion times just because the rules say you can.
Ralph Gesler
- Raw text -