-
Notifications
You must be signed in to change notification settings - Fork 729
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Loom] Excessive JIT memory usage in Skynet test #16424
Comments
This may also be one of the reason for the significant perf regression against RI (5-6x) with JIT enabled. When testing with |
At the moment, Skynet consistently crashes with the latest JDK 19 on x86-64 Linux with either the "Invalid JIT Return Address" problem or a crash in the VM or GC. It is probably worth waiting for those issues to be resolved before spending time investigating this. |
I am able to run this on a 96-thread Cascade Lake now. Studying the verbose log memory statistics of a few runs doesn't show anything close to 15GB memory consumption (some profiles at higher opt are in the 250-300MB range). What technique did you use to measure the memory consumption? In the meantime I'll look at more process-based statistics as well as what the javacore tells me late in a run. |
I was monitor the memory usage via |
There does appear to be an excessive allocation problem. 99.2% of all JVM allocations running Skynet are coming from openj9/runtime/codert_vm/jswalk.c Line 1500 in 65bd145
Given the rate of growth I doubt this memory is ever freed. Still figuring out why and what can be done about it. |
|
Temporary `J9VMThread`s are created to present `J9VMContinuation` thread data to the stackwalker. Explicitly disable the JIT artifact cache on the temporary thread otherwise the stack walker will allocate a new 4K buffer for each temporary `J9VMThread` whose memory must be managed. These threads exist to perform a single stack walk and the benefits of managing and using a JIT artifact cache appear to be limited. Fixes: eclipse-openj9#16424 Signed-off-by: Daryl Maier <maier@ca.ibm.com>
When triaging #15939, I noticed that there seem to be excessive allocation from JIT
I was using
-Xmx512M
option, test resulted in using:VM:
1.4GB total memory
~512MB heap memory
~500MB thread memory
~300MB class memory
JIT
~15GB total memory
~250MB code cache
Maybe similar to #16148
To reproduce:
Testcase: https://github.com/ibmruntimes/openj9-openjdk-jdk19/blob/openj9/test/jdk/java/lang/Thread/virtual/stress/Skynet.java
compile with
javac --enable-preview -source 19 Skynet.java
run with
java --enable-preview --Xnocompressedrefs -Xmx512M Skynet
FYI @0xdaryl @tajila
The text was updated successfully, but these errors were encountered: