How to disable intrinsics usage for the JIT compiler?

一个人想着一个人 提交于 2019-12-01 02:28:45

问题


I am doing some performance tests on the JVM, and I would like to measure the impact of intrinsics usage.

I would like to disable the JIT use of intrinsics for some methods without going into the interpreted mode. Is there a way to do that ? Thank you


回答1:


Use

java -XX:+UnlockDiagnosticVMOptions -XX:DisableIntrinsic=_<method_name>[,...]

For example

java -XX:+UnlockDiagnosticVMOptions -XX:DisableIntrinsic=_equals,_hashCode

As @apangin noticed, you may use -XX:+PrintIntrinsics first to see which methods are actually intrinsified in your test and disable them.



来源:https://stackoverflow.com/questions/30370959/how-to-disable-intrinsics-usage-for-the-jit-compiler

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!