4 ms·
>[Go] is almost as fast as languages like C++ and Java. It seems like only a couple of years ago when Java's speed was the butt of many a joke. The JVM has com
by mcdonje 4y ago
>[Go] is almost as fast as languages like C++ and Java.
It seems like only a couple of years ago when Java's speed was the butt of many a joke. The JVM has come a long way. As someone who doesn't work in Java and doesn't have a horse in this race, I find their turnaround impressive.
- pjmlp 4y agoThe JVM has already been quite impressive for the last two decades for backend computing workloads. First of all, there are plenty of implementations to chose from, everyone is now talking about GraalVM, because the basic version is free beer, yet AOT has been a thing in commercial Java compilers for quite some time. Nowadays OpenJDK and OpenJ9 offer JIT caches with PGO feedback across executions, well, OpenJDK one started in J/Rockit, and OpenJ9 traces back to Metrome/Websphere Real Time/J9. My first large scale Java project was done in 2005, when our team at Nokia Networks started the transition of a C++ infrastruture used for base stations reporting into Java. Did Java win against C++ in microbenchmarks back in 2006, not at all, yet Java 5 JIT compiler in IBM J9 and Sun's JVM already provided enough performance juice that we could perform such endevour, while keeping the system responsive. Eventually some other issues plagued the project, however they were related with politics between the C++/CORBA folks and us bringing up the new platform.
- iainmerrick 4y agoHmm, I feel like that’s been the case for more than a couple of years. Java has been fast for well over 10 years, I’d say. But I think Java also still has the problem that it tends to use a ton of memory (unless you use it the fintech way, manually wrangling your data in arrays rather than using lots of objects). My subjective impression is that garbage collected languages have gone through a bit of a rise and fall over time -- “GC is bad because it’s slow!” “huh, GC is fast now” “Java is the way forward!” “GC uses a lot of memory” “Rust [or Swift] is the way forward!”
- corrral 4y ago> Hmm, I feel like that’s been the case for more than a couple of years. Java has been fast for well over 10 years, I’d say. It got the reputation in part because once upon a time Java programs were noticeably slow and heavy on resource use, no matter how many times Java fans posted micro-benchmarks of Java finding digits of Pi to "prove" Java was fast and we must all be imagining things. In actual fact, in the real world, it was slow. I think improving hardware has more to do with its feeling faster now, than anything else. Hardware got fast enough that it no longer feels (as) slow. Plus its competition, as far as GUI programs go, now prominently includes Electron. On the server, we deploy tens or hundreds of megabytes of container or VM and associated overhead to run a 2MB program. So also, everything else has gotten far more bloated and heavy, making Java look better by comparison.
- digisign 4y agoJava was slow at startup, speeding up as it is run. Those two were both improved, with 1000x faster hardware being the final leg of the stool.
- shepherdjerred 4y agoJava has been fast for a long time. Its reputation is slow to recover.
- IshKebab 4y agoI dunno I feel like the language was always seen as fast..ish. It was the startup time, memory use, and speed of actual applications that were slow. Is Eclipse fast yet?