> >True, but if you saved the entire state of the JVM memory on disk (an 
> >JVM 'hibernation'?) then you could just start from where you left, 
> >instruction pointer included.
> 
> Just one _teensy_ snag. Open files and sockets. And all state external 
> to the JVM.

No, that's not the snag. This is not a new idea, as pointed out Emacs and other
stuff has used it for years.  The actual technique is you pre-load the 
application
but don't start it running (see also the Zombie calls in JikesRVM). Since it 
hasn't
been started, there is no external state, no open files, etc.

As is now obvious, the snag for doing it in Java is: how do you know what 
classes
to load and precompile?  There is no right answer, but the simple answer is to 
inspect
the byte code for all classes that are instantiated. This works for the cases 
without
dynamic loading, so HelloWorldJDBC.java won't run. Unless you also support 
dynamic
loading in your VM.

Reply via email to