How do I run a class compiled with jaotc?
问题 I compiled a simple class using the Java 9 Ahead-Of-Time Compiler jaotc using the following command: javac Test.java jaotc Test.class This produces a file named unnammed.so . How do I run the compiled program? Do I need to write a bootstrap program to link with the .so file? 回答1: After executing an AOT compilation, you need to specify generated AOT library during application execution: java -XX:AOTLibrary=./Test.so Test You should also compile java.base to gain real improvement, performance