How is the VM(in java code) built to native code

I am wordering how is the java code of VM is built into native code.(the byte code of jnode's VM can't run on the chip)
I have read some of the source code of JNode-Builder. I think it is this project which compile the byte code of jnode's VM to native code for the boot-loader to use.
But i am not sure how this is done in this project.
Can anyone make a discription on how the build process of the jnode OS is done internally.(what is done when we use the build.xml and what has been down by each step of the build)

a general overview

JNode-Builder is about building the boot image :
- all classes that are needed at boot time are compiled to native code
- other classes will be compiled as needed, when the bytecode->native compiler will be ready

The bytecode->native compiler is located in JNode-Core (that contains also openjdk & GNU Classpath classes).

About build.xml files, you have to know ant to better understand how it works.
Basically, the idea is that each sub-project (JNode-Core, JNode-FS, JNode-Net ...) is responsible of managing the following tasks :
- compiling java sources to bytecode
- making a jar for each of its plugins (everything is a plugin in JNode)
- cleaning the generated .class files
- ...
in JNode-All, build.xml is calling a task (compiling, making jars, ...) for all sub-projects

I hope that will help you.


my blog (in english and french)

Are X86Level1ACompiler&X86Level1BCompiler the compler?

Are X86Level1ACompiler&X86Level1BCompiler the compler?
In my opinion:
We first complie the source code of JNode vm on the host OS, and run the compiler of Jnode-vm on the host os to build the byte-code of the jnode-vm(including the compiler itself) into native-code of target platform.

Is that right?

l1a and l1b are basically

l1a and l1b are basically the same. l1b once started as a simple copy of l1b, it contains a bit more debug informations and it contains a bugfix that didn't make it to l1a yet due to the lack of a testcase. See here.

And you're right about the bootstrap. On the host everything gets compiled java->bytecode and all classes needed during bootup (including the jit itself) get compiled bytecode->nativecode.