Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / Virtual Machine / August 2004

Tip: Looking for answers? Try searching our database.

AOT, JIT & VM

Thread view: 
Fabinou - 04 Aug 2004 18:03 GMT
Hi,

I've some difficulties to understand how does the JIT compilers work.
Let's say that a JIT compiler is used, is it running with a virtual
machine or not? How the garbage collection is done?

Same question for AOT compilers, how does the GC work since there is
no virtual machine ? (thread in parallel of the program?)

Thanks
Chris Smith - 04 Aug 2004 18:38 GMT
> I've some difficulties to understand how does the JIT compilers work.
> Let's say that a JIT compiler is used, is it running with a virtual
> machine or not? How the garbage collection is done?

Yes, the application is running inside of a virtual machine.  The
virtual machine is responsible for the JIT and garbage collection
functions of the application (among other lesser things, of course).

> Same question for AOT compilers, how does the GC work since there is
> no virtual machine ? (thread in parallel of the program?)

I presume by AOT you mean "ahead of time", i.e. what's commonly known as
a native compiler?

The native compiler will generate code that causes garbage collection to
happen.  The exact details of the garbage collector (whether it's a
parallel thread or not, etc.) will depend on the native compiler, and
possibly on which options you give it when compiling.

Signature

www.designacourse.com
The Easiest Way to Train Anyone... Anywhere.

Chris Smith - Lead Software Developer/Technical Trainer
MindIQ Corporation

zoopy - 04 Aug 2004 19:04 GMT
> Hi,
>
[quoted text clipped - 6 lines]
>
> Thanks

Modern JVM implementations of Sun (and probably of other vendors as well) are based on HotSpot
technology, which includes a bytecode interpreter, a bytecode-to-native compiler (HotSpot compiler),
memory management and garbage collection functionality.

You'll find a more detailed explanation of all of this at
<http://java.sun.com/docs/books/performance/1st_edition/html/JPAppHotspot.fm.html>

Regards,
Z.
Roedy Green - 10 Aug 2004 00:47 GMT
>I've some difficulties to understand how does the JIT compilers work.
>Let's say that a JIT compiler is used, is it running with a virtual
>machine or not? How the garbage collection is done?

There is a run time that converts JVM byte codes to native. Other
modules handle gc in the same sort of a way in a pure interpreter,
though the move is to generational collectors rather than simple
mark/sweep.  see http://mindprod.com/jgloss/garbagecollection.html

>Same question for AOT compilers, how does the GC work since there is
>no virtual machine ? (thread in parallel of the program?)

There is nothing that stop there from being dozens of other threads in
an AOT, any more than you could not have dozens of threads in a C++
program.

Signature

Canadian Mind Products, Roedy Green.
Coaching, problem solving, economical contract programming.
See http://mindprod.com/jgloss/jgloss.html for The Java Glossary.



Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.