开发者

Compile Java without optimization?

开发者 https://www.devze.com 2023-02-02 16:08 出处:网络
I\'m 开发者_Python百科working on some of the problems in Programming Pearls and I\'d like to get a sense for the runtime of various programs in Java. However the optimizing compiler is making this dif

I'm 开发者_Python百科working on some of the problems in Programming Pearls and I'd like to get a sense for the runtime of various programs in Java. However the optimizing compiler is making this difficult. Is there a way to run javac on a Mac without having the compiler make any optimizations?


@Andrew Thompson is correct, the JIT is the main source of optimizations with java.

To run java without the JIT:

 java -Xint ...
0

精彩评论

暂无评论...
验证码 换一张
取 消