View Single Post
Posts: 2 | Thanked: 1 time | Joined on Oct 2009
#190
Originally Posted by Enyibinakata View Post
Dalvik != JavaVM, its a bastardised version of it and is highly optimised. Android also allows for native development thanks to the newly released 1.5 native dev kit NDK.
Slightly old info, circa ~1.5, but from an android dev at a google presentation earlier this year, dalvik has some optimizations, but also some serious drawbacks compared to c. For example, the GC takes 100-300ms to run, which means you have to take dramatic steps not to alloc/dealloc memory while maintaining framerate (meaning java collections really can't be used).

The NDK is only callable through JNI (and JNI calls are 30% slower than local calls), and doesn't have access to the main API, so you're still working through java to an extent.

Choosing java as your primary programming language has advantages, but you'll never match truly native c for speed, and given the limited battery/clocks on phones, it makes it an odd choice. I guess allowing generally less-skilled masses to write apps outweighs the performance implications, but it's why I'm torn between the Droid and something faster,
 

The Following User Says Thank You to tannin For This Useful Post: