DevX interviewed Bjarne Stroustrup about C++0x, the new C++ standard that is due in 2009. Bjarne Stroustrup has classified the new features into three categories Concurrency, Libraries and Language. The changes introduced in the Concurrency makes C++ more standardized and easy to use on multi-core processors. It is good to see that some of the commonly used libraries are becoming standard (eg: unordered_maps and regex).
Permalink for comment 327498
To read all comments associated with this story, please click here.
Fortran isn't touched when it comes to precision when doing Numerical Analysis.
Nothing to do with precision. Fortran use the same format than C those days on common machines (IEEE floating point); if you implement the same algorithm, you can in theory have exactly the same results (although differences with compilers mean this will never happen in practice). There is a lot of expertise in fortran numerical code, though, which is why you still have so much code implemented in fortran and used today (blas, lapack, optimization, etc...).
Fortran beats down C (and C++, they are the same here) because it does not have pointers, or more exactly does not have the aliasing problem (different pointers pointing at the same memory address), which makes optimization by compilers so difficult. That's why Fortran is still much faster than C or C++ on most benchmarks.
It has also an array concept: that's why most C++ is a really poor language IMO for numerical code, because everybody has a different, incompatible class for vectors, so the speed you gain from being in C++ is lost converting formats between libraries. This and the fact that the language is way too complicated IMO. I personally believe that C++ is a niche language: it is still the only "industry" language you can use when you need ten of thousand objects touching each other (heavy GUI, games), but I would never use C++ if I had a valid other choice.
Member since:
2005-11-11
Nothing to do with precision. Fortran use the same format than C those days on common machines (IEEE floating point); if you implement the same algorithm, you can in theory have exactly the same results (although differences with compilers mean this will never happen in practice). There is a lot of expertise in fortran numerical code, though, which is why you still have so much code implemented in fortran and used today (blas, lapack, optimization, etc...).
Fortran beats down C (and C++, they are the same here) because it does not have pointers, or more exactly does not have the aliasing problem (different pointers pointing at the same memory address), which makes optimization by compilers so difficult. That's why Fortran is still much faster than C or C++ on most benchmarks.
It has also an array concept: that's why most C++ is a really poor language IMO for numerical code, because everybody has a different, incompatible class for vectors, so the speed you gain from being in C++ is lost converting formats between libraries. This and the fact that the language is way too complicated IMO. I personally believe that C++ is a niche language: it is still the only "industry" language you can use when you need ten of thousand objects touching each other (heavy GUI, games), but I would never use C++ if I had a valid other choice.