[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

direct compilation to java bytecodes (Re: packers and tainters)



Anton van Straaten wrote:

>Another answer to your original question, in Java's case, would be that you
>could runtime-compile the code in question, and dynamically load the
>resulting bytecode, all using built-in capabilities of Java.  Application
>servers do this kind of thing all the time.  So there are multiple ways to
>achieve a practical 'eval' capability in Java.
>

Sounds like Per Bothner of the GCJ/Kawa/JEmacs fame is going to touch on 
this very topic in his talk at JavaOne in San Fran this year:
http://servlet.java.sun.com/javaone/sf2003/conf/sessions/display-2907.en.jsp

To lift a quote:

    Most of these implementations use interpreters, but for good
    performance one wants to compile into bytecodes. Some
    implementations (such as JavaServer Pages technology) compile to
    Java source code and to bytecodes, but responsiveness is much
    better if you can compile directly to bytecode. Then, we can use a
    ClassLoader for a fast implementation of "eval", without accessing
    the file-system. Direct compilation also makes it easier to
    generate debugging information, including exception stack traces.