4 ms·
Dalvik performance has nowhere to go but up. If there's anything good about Java is that its terseness allows for loads of optimizations.
by Daishiman 17y ago
Dalvik performance has nowhere to go but up. If there's anything good about Java is that its terseness allows for loads of optimizations.
- jrockway 17y agoLanguage syntax has nothing to do with optimization. Java is easy to optimize because the machine types of values in the program can be determined at compile-time. (Of course, with runtime information, you can pick even better machine types, which is what JIT is.) The reason why languages like Perl and Python run so slowly is not because of the syntax, but because of the semantics. When one value can be a number on one line and a string on the next, it is difficult to convert that sequence to fast machine instructions.
- Xichekolas 17y ago> ... Java is that its terseness ... Compared to what? Java has a reputation for many things, but terseness of syntax is not one of them. I'm not trying to be derisive to the language, I just thought that was an odd assertion to make.
- mahmud 17y agoElaborate syntax over an impoverished evaluation model and semantics. Java is inspired by p-code; you could implement a p-code interpreted with one switch statement in two pages. A handful of primitive types + an straightforward single inheritence class based object system. The GC is run of the mill. Control semantics are none existent; try/catch is even more straightforward than C's longjmps. The whole thing is small enough to be compiled for an early 90s set-top box running a 16-bit micro, and there is nothing wrong with that. In fact, it's beautiful.