This is from the wikipedia article on Java vs C++ performance. Also check references 7 and 8.
I read through it - and I must admit - I was surprised. I had a few thoughts I felt like sharing after reading -
While it may be true that C++ is harder to optimize - I don’t see that as a valid point in a speed comparison. The proper use of optimizers and debuggers go a long way to dispelling those issues.
For C++ on a Windows/Linux platform, you should really go with Intel’s compiler. In my experience, it produces the fastest code. Comparing to free/legacy compilers just aint right.
I understand in theory the benefits Java could take advantage of in coming versions - but properly written C++ code can as well.
For anyone who has programmed both - especially for a Windows/Mac environment, or as a Web Service - the reality of the situation is that C++ outperforms Java, has less issues, and requires less overhead to maintain.