3 ms·
"Fortran is faster than C++" Whats your usecase? It seems it is faster for some, but a lot slower in others: https://benchmarksgame.alioth.debian.org/u64q/co
by quickben 9y ago
"Fortran is faster than C++"
Whats your usecase?
It seems it is faster for some, but a lot slower in others:
https://benchmarksgame.alioth.debian.org/u64q/compare.php?lang=ifc&lang2=gpp https://benchmarksgame.alioth.debian.org/u64q/compare.php?la...
- coliveira 9y agoWhen people say that FORTRAN is faster than C++ it is obviously for numerical code, since general systems code is very hard to do in FORTRAN. Many people will complain that C++ can be faster than FORTRAN, however the problem is that you need to know a lot of C++ or have access to the right libraries to write competitive numeric code. In FORTRAN you can do that out of the box.
- eesmith 9y agoMoreover, the article mentions this point, references the benchmarks game, and says "However, the two benchmarks where Fortran wins (n-body simulation and calculation of spectra) are the most physics-y".
- igouy 9y ago>> where Fortran wins << spectral-norm 1.99s Fortran Intel 1.99s C++ g++ URL provided @quickben
- eesmith 9y agoAnd the full text in the article is: "However, the two benchmarks where Fortran wins (n-body simulation and calculation of spectra) are the most physics-y. The results vary somewhat depending on whether one compares a single core or quad core machine with Fortran lagging a bit more behind C++ on the quad core." Though I don't see how the single core version is measured. As far as I can tell, the spectra calculations are always using 4 CPUs while the n-body is always using 1 CPU.