Re: [NTLK] Off-Topic Linux (PDA) Question

From: Sean Luke (sean_at_cs.gmu.edu)
Date: Thu Nov 01 2001 - 23:04:54 EST


The biological entity known as Laurent Daudelin stated:

> on 10/31/01 5:30 PM, David Orriss Jr at dave_at_davenet.net wrote:
>
>> At 11:05 AM 10/31/2001 -0500, you wrote:
>>> Huh? If you have a JVM CPU that can processes raw bytecode, sure,
>>> that'd be
>>> fine, but AFAIK, the JRE still has to translate those bytecode into
>>> machine
>>> code for a specific CPU.
>>
>> Only hotspot does that. The JRE itself does not.
>
> Correct me if I'm wrong, but any Java expression needs to be translated
> in a few machine code instructions, no matter how you look at it.

"JRE" is a Sun Marketroid Term for the plain ol' Java virtual machine
("VM" or "JVM"): there's very little difference. On most machines, this
virtual machine *is* hotspot. So saying that hotspot does something,
but not the JRE, is kind of like saying that Newton Intelligence does
something but not the Newton OS. :-)

To answer Laurent's question: Java byte code is either interpreted on an
instruction-by-instruction basis or compiled directly into machine
code. In some sense you could say both "translate" the Java expression
into machine code, but I'd really reserve this term to describe only
compilers. To "translate" code, you need something that it's
"translated into". Interpreters don't convert the code into something
else -- they just do what the Java told them to do. Maybe I'm being
nitpicky tho.

BTW, hotspot is both an interpreter *and* a compiler. It starts off
interpreting the code, then when it notices some of the code is being
called over and over and over again, it sends that off to get compiled
so it's faster. Nifty.

Sean

--
This is the Newtontalk mailinglist - http://www.newtontalk.net
To unsubscribe or manage: visit the above link or
	mailto:newtontalk-request_at_newtontalk.net?Subject=unsubscribe



This archive was generated by hypermail 2.1.2 : Sat Dec 01 2001 - 20:01:59 EST