How do i disable the intrinsic function usage of the JIT compiler?
•
Java
I'm doing some performance tests on the JVM and I want to measure the impact of the use of intrinsic functions
I want to disable the JIT of some methods and use intrinsic functions without entering interpretation mode Is there any way to do this? thank you
Solution
use
java -XX:+UnlockDiagnosticVMOptions -XX:DisableIntrinsic=_<method_name>[,...]
for example
java -XX:+UnlockDiagnosticVMOptions -XX:DisableIntrinsic=_equals,_hashCode
As @ apangin noticed, you can first use - XX: printinsights to see which methods are actually intrinsic in the test and disable them
The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
二维码