J. Verdrengh said:
Java program startup is slow. As a java program starts, it unzips the java
libraries and compiles parts of itself, so an interactive program can be
sluggish for the first couple seconds of use.
This approaches being a reasonable explanation for the speed myth. But while
it might explain user's impressions, it does not explain why many
programmers (who can easily understand the idea of an interpreted program
being compiled) share the belief.
(c)
http://www.idiom.com/~zilla/Computer/javaCbenchmark.html
Slow startup is rather serious. Programmers understand that java does a
lot more behind the scenes than other languages. And when jars are
used, there's the decompression issue on startup. These although
understood, are not tolerated timewise using a C++ alternative exists!!
It may well be that java is nicer for some to program in. But Using
the app is another matter.
That theoretical test at the link didn't check bulky applications.
Practice shows they kludge along.
That article provides a very weak explanation at the end, that java
isn't really so slow it's all down down to psychology!!
Had they asked people that have tried java applications for specific
reasons why they gave up on them. Then you'll start to see concrete
reasons. Not human psychology.
And these reasons only apply to java apps. Or, apply to java apps
moreso than to C++ apps.
It's possible that now java runs faster - though not as fast as C++.
But because java with swing was so slow in the past, it has that
stigma, that bad reputation, so people see java apps and download the
other one! I haven't tried many java apps recently because of past
experience of java programs. Though actually, a recent java app I
tried was a complete nuisance - GUI wise. Azureus
The app did things that a regular Windows GUI would never do. Because
sometimes the java GUI components aren't quite right. People tend not
to find the right standard components The find a component with issues
or bugs.
I recall programming a GUI in java where you coulc click and drag the
contents of one box into another. It took me a long time to look for
the right component, but I never found exactly the right one, and I
remember having to do some ridiculous workarounds. FWIW it was a team
project - i.e. not just me. A Standard windows component like in VB
wouldn't have had the problem I ran into in the click and drag.
So, that's just yet another reason why java programs haven't taken
off. The GUI components have issues.
Plus i'm quite sure that java programs use more memory. the bigger the
program, the more memory it takes up.
I remember lecturers unable to do their presentation because running 2
big java apps at the same time was too much for their computer.
Everybody in the hall knew it was java. THat wouldn't have happened had
the prgorams been C++.