3 ms·
1.5 is huge, except it is completely wrong. JVM startup time is within fraction of the second.
by eveningcoffee 10y ago
1.5 is huge, except it is completely wrong. JVM startup time is within fraction of the second.
- akvadrako 10y agoYou are right, I was just going with what the grandparent said. But I think with normal amounts of class scanning and other overhead, 1.5 seconds becomes the practical normal. Certainly the JVM startup always feels slow, in my experience.
- eveningcoffee 10y agoWell, if you create a lot of additional objects on startup then it will take some time. JVM startup is still fast. http://blog.ndk.io/jvm-slow-startup.html http://blog.ndk.io/jvm-slow-startup.html
- akvadrako 10y agoThat links says 1.2 seconds for a hello world! 1.2 microseconds is what I would expect to be called fast.
- mickronome 10y ago1.2 seconds was hello world in clojure, the Java hello world presented the numbers below, so it's mostly clojure that is slow: $ time java Hello Hello world 0.04user 0.01system 0:00.12elapsed 43%CPU (0avgtext+0avgdata 15436maxresident)k 29672inputs+64outputs (82major+3920minor While 120ms elapsed is not stellar, it's rarely a problem with how the JVM ecosystem looks.
- dkersten 10y agoThat's clojure, not java. JVM startup is much faster.
- eveningcoffee 10y agoPlease be kind to reread it. Startup time of a simple Java application and therefore also whole JVM is 0.4s (in the linked article). 1.2s is for the implementation in Closure that includes its additional quite heavy runtime.
- akvadrako 10y agoI read it fine, but Clojure is an application of the JVM. The fact that a popular interpreted language of the JVM takes 1.2 seconds for hello world is a problem of the JVM itself, or at least it's ecosystem. An interpreted language in C wouldn't take nearly that long.
- pjmlp 10y agoThe way an interpreter is implemented and the language it runs on don't have anything to do with each other. A Clojure interpreter written in C, if written the same way as for Java, it would run just as slow, given the way it is building Clojure every time the application starts.