Re: where is the LINK/LOAD module when using Java
From: John C. Bollinger (jobollin_at_indiana.edu)
Date: 02/27/05
- Next message: Roland Poellinger: "JMF: controlling webcam color settings from java"
- Previous message: Peter Höltschi: "Access classes in Tomcat"
- In reply to: TonY: "where is the LINK/LOAD module when using Java"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Sun, 27 Feb 2005 14:51:35 -0500
TonY wrote:
> Theoritically, the files get translated into object code by the
> compiler, the linker then group all the object modules into one
> module, the loader load it into the memory.
Whose theory is that? Yours? You describe a very common language
implementation pattern, but it is by no means universal and it has
nothing to do with theory. Consider interpreted languages. Or, as it
happens, Java (see below).
> however, when i compile java files, i find only .class (thus,more and
> less, object files), but no trace to the linked module and load
> module.
Well, yes, a .class file is the closest approximation to an object file
that is a standard output of a Java implementation. It is _not_ an
object file, however, as it does not contain instructions directly
interpretable by the platform CPU.
> will this be done automatically later by the interpreter and/or JIT?
Modern Java virtual machines are not well described as interpreters, in
part because they do perform JIT compilation.
Runtime class loading and linking is the specified behavior of a
compliant Java implementation, so to that extent, yes, the VM performs
these operations, but you will not typically find a persistent
representation of a "link module" or a "load module". You will also
find, if you read the Language and VM specs, that "linking" and
"loading" may not mean precisely the same thing in a Java context that
they do in, for example, a compiled C++ context.
> why such JAVA implementation?
It supports Java's goal of being cross-platform. It provides excellent
modularity. It makes the VM a central point of optimization so that
improving the VM can improve the performance of all programs that run on
it, immediately, without change to the programs themselves. Probably
other reasons as well.
> With C++, we can find link module, and
> load module
So? Your point is that C++ is different from Java? That's no news here.
-- John Bollinger jobollin@indiana.edu
- Next message: Roland Poellinger: "JMF: controlling webcam color settings from java"
- Previous message: Peter Höltschi: "Access classes in Tomcat"
- In reply to: TonY: "where is the LINK/LOAD module when using Java"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|