Re: Interpretted JAVA Vs. Compiled VC++: Java Wins!

new topic     » goto parent     » topic index » view thread      » older message » newer message

On Sun, 7 Jan 2001, Jack Cat wrote:

> Man oh man!
> Crap!
> I wasted all my time coding in Eu!
> Heh? Not realy, but for RDS to claim Euphoria is the
> fastest interpeter around, is just ABSURD!
> I never coded in JAVA before, and I don't know JAVA,
> but while searching the net for some C libraries, I
> encountered a JAVA site stating that JAVA,
> interpreted, is nearly as fast as compiled, optimised,
> C! Using Visual C++!

Well, I'm not sure it's quite that fast, but Java can be very fast.

> Java is an easy to use interpreted language with
> garbage collection and run-time error checking.
> It's multi-platform, open-source, and even has native
> compilers! Plus several JAVA To C translators!
>
> Man, I'm positive Euphoria code, translated to C, will
> NOT beat interpretted JAVA. Positive. And don't get me
> started about what kind of performance you get once
> you COMPILE Java.

Well, of course you could translate a simple Euphoria program to C and
optimize it heavily, and then it would probably beat interpreted Java...
of course, many Java interpreters these days do compile the Java bytecode
through JIT.

> The fastest JAVA interpreter around, to my knowledge,
> is Jikes from IBM, and is free, plus Open Source!

To my knowledge, Jikes is a C port of the javac Java source to bytecodes
compiler (which itself is in Java, making it very slow sometimes since it
has to load the Java interpreter). I have Jikes, and it bytecode-compiles
Java really fast. I also use IBM's JDK for the interpreter since Sun's
interpreter for Linux kept freezing.

> Create DLLs, web sites, 3D Engines, and even operating
> systems in JAVA! And it's extremely fast! Actually,
> how does 60 times faster than Eu sound?

Well, I think creating DLLs in Java is a little far-fetched, and for 3D
engines you probably want C... not only is Java a little slower, but the
graphics routines can be really slow - you could, of course, call an
external library... but it seems a little pointless to me. Web sites, of
course, can be a great use for Java. For operating systems, you'd need
some lower-level code below that, of course.

For many purposes, Java can be much, much faster than Euphoria (translate
sieve.ex to Java, for example)... but the Java equivalent of sequences is
sad compared to Euphoria's. For one thing, for the same flexability that
Euphoria allows, you'd have to use the built-in Number classes (or your
own derivation thereof). Note that these are objects, not primitive types,
so they are much, much slower than ints, floats etc.

> I know it's hard to believe
<snip>
Not at all. Java is a good language, and it can be quite fast sometimes.

> But now let's get down to business shall we?
> I remember Robert once saying you couldn't find a
> faster interpretter than Euphoria. Why is JAVA out
> there then? Why is it free, portable, open-source,
> safe, extensive, developer supported, garbage
> collected, sequence bearing, and easy to use?

When Java first came out, it was SLOW. Euphoria, I bet, can easily beat
the older versions of Java. However, without taking the flexability of
sequences into consideration, Euphora pales in comparison to the
speed of today's Java interpreters since the Java interpreters do Just In
Time compilation.

> I'm beginning to think Java realy did drop in
> popularity because of bad critique from crappy
> developers that hate Sun Microsystems.
>
> You know what?
> I'll do all yall the favor of translating all Euphoria
> benchmarks to Interpreted JAVA, and let's see, once
> and for all, who's the fastest baby on the block.
>

I've translated sieve.ex, and Java beats Euphoria down on this one. I
think you'll find, however, that Java's advantage is not nearly so great,
if it has any at all, on sequence.ex and other benchmarks that manipulate
sequences a lot.

Jeff Fielding

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu