There is a Java Virtual Machine completely implemented in Java called JPF. In other words, when you run a Java program within this machine, it's a JVM-within-a-JVM execution. Obviously, this uses a lot of resources and I was thinking of ways how that could be reduced.
An idea I have is to compile JPF with GCJ to native code, thereby resulting in only one JVM that is used when running a Java program within JPF.
Do you see any inherent limitations to this idea, i.e. reasons why it wouldn't work? I'm not a JVM expert so it's hard for me to see any obvious obstacles.