jvm-codecache

JVM JIT deoptimization after idle

梦想的初衷 提交于 2019-12-24 06:01:52
问题 I use Java primarily for writing pet projects, which are idle most of the time. And after being idle for hours/days response time increases to seconds (up to 10s), then slowly decreases back to 200-300ms. As far as I understand, this happens because of JIT deoptimization (optimized code becomes marked as a zombie, removed and later compiled again). Is there any way to forbid JVM to deoptimize code unless code cache is full? Java 9's AOT looks like the best solution for this case, but I still

JVM Compile Time vs Code Cache

自闭症网瘾萝莉.ら 提交于 2019-12-21 19:28:06
问题 I've been benchmarking my app and analyzing it with JMC. I've noticed that under load, it performs quite a bit of JIT compiling. If I send a large amount of transactions per second, the compile time spikes. The compile time always grows proportionally with any heavy load test against the app. I've also observed that the Code Cache slowly rises as well. So I decided to raise the Code Cache reserve to 500MB to test. Bad move! Now it's spending even more time performing JIT. Then I explicitly

JVM Compile Time vs Code Cache

Deadly 提交于 2019-12-04 09:46:58
I've been benchmarking my app and analyzing it with JMC. I've noticed that under load, it performs quite a bit of JIT compiling. If I send a large amount of transactions per second, the compile time spikes. The compile time always grows proportionally with any heavy load test against the app. I've also observed that the Code Cache slowly rises as well. So I decided to raise the Code Cache reserve to 500MB to test. Bad move! Now it's spending even more time performing JIT. Then I explicitly disabled code cache flushing via -XX:-UseCodeCacheFlushing . However, I noticed that the peak Code Cache