View Single Post
Posts: 1,341 | Thanked: 708 times | Joined on Feb 2010
#126
Originally Posted by attila77 View Post
Again, these are the little 'a-ha !' type of rhetorical battles. You say that, I say yeah, but C++ can do stack allocations which eat Java's heap allocation for breakfast, what about casting... And so forth. Each platform has a set of "I do this better than the other one !" and that's why it's so difficult (=impossible) to do a proper comparison.
Java VM can use stack allocations also when it sees they can be used. It even can use register allocations there where C++-compiler couldn't (because, yes, pointers in the basic block)
I believe Sun's Hotspot VM already had that feature.