Troubleshooting
Problem
The following document will help identify the failing class or method due to a HotSpot compiler failure on Solaris and HP-UX.
Symptom
Stack overflow, looping, crash, incorrect output, High CPU
Cause
A HotSpot failure can occur during compilation or when the compiled code is run.
Resolving The Problem
The HotSpot compiler is designed to compile methods that are accessed frequently. This helps speed up Java™ Virtual Machine (JVM) operations and is a vital part of the JVM.
Table Of Contents
![](/support/pages/system/files/support/swg/swgtech.nsf/0/85256dd00053143485256ca2005619a0/Content/0.228.gif)
![](/support/pages/system/files/support/swg/swgtech.nsf/0/85256dd00053143485256ca2005619a0/Content/0.490.gif)
Identifying the failing method |
- Enable PrintCompilation by adding -XX:+PrintCompilation to the Generic JVM arguments. Restart the JVM for the change to take effect.
- For releases of WebSphere Application Server V7.0, V8.0, v8.5.X, V9.0:
In the Administrative Console, Select Servers > expand Server Types > WebSphere application servers > server_name> expand Java and Process Management, select Process Definition > Java Virtual Machine > Generic JVM arguments.
- PrintCompilation writes the classes and methods that are being HotSpot compiled to the native_stdout.log . The last compiled method prior to the failure is the one you need to skip.
Example of PrintCompilation output in the native_stdout.log:
com.ibm.sslite.e::a (691 bytes) com.ibm.sslite.h::c (428 bytes) An unexpected exception has been detected in native code outside the . Unexpected Signal : 11 occurred at PC=0xff330924 Function name=memcpy Library=/usr/platform/SUNW,Ultra-80/lib/libc_psr.so.1 |
Exclude the method |
To skip the compiling of specific method calls:
- 1. Create a new file named .hotspot_compiler in the profile's root directory
By default this is in the directory <WAS_HOME>/profiles/<PROFILE_NAME>/
NOTES:
* The file .hotspot_compiler can be renamed to any valid filename.
* If you cannot place this file in the profile's root, specify a different location that is readable by the user id who owns the JVM processes.
2. Specify this JVM argument, replacing <FILE_PATH> with the complete path plus filename of the .hotspot_compiler file.
-XX:CompileCommandFile=<FILE_PATH>
3. Edit the file and add one line for each method to exclude compilation. The syntax is listed below:
exclude full/class/name method
Note: Only use slashes to separate parts of the package name.
Example:
exclude java/lang/String toString
### Excluding compile: java/lang/String::toString
Frequently asked questions (FAQs) |
- Is there an argument that can be used in lieu of creating a .hotspot_compiler file?
Yes there is. You can add the same exclusions as in the file to this JVM argument. You can substitute spaces with commas: - Does the IBM SDK utilize the HotSpot compiler?
No. The IBM SDK, which is available bundled with WebSphere Application Server on AIX, Linux, and Microsoft Windows uses a similar compiler called Just-In-Time compiling (JIT).
Syntax: -XX:CompileCommand=exclude,full/class/name,method Example: -XX:CompileCommand=exclude,java/lang/String,toString Add additional JVM arguments for each method exclusion. |
- Adjusting the Compiling Threshold
Using the JVM argument -XX:CompileThreshold=<value> can adjust how frequently the HotSpot compiler will execute on individual methods. Set the value to the number of method calls made until compiling takes place.
-XX:CompileThreshold=10000 The defaults are 10000 for server mode and 1500 for client mode |
Related Information
[{"Product":{"code":"SSEQTP","label":"WebSphere Application Server"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"Java SDK","Platform":[{"code":"PF010","label":"HP-UX"},{"code":"PF027","label":"Solaris"}],"Version":"9.0;8.5.5;8.5;8.0;7.0","Edition":"Edition Independent","Line of Business":{"code":"LOB45","label":"Automation"}},{"Product":{"code":"SSNVBF","label":"Runtimes for Java Technology"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Component":"Java SDK","Platform":[{"code":"","label":""}],"Version":"","Edition":"","Line of Business":{"code":"LOB36","label":"IBM Automation"}}]
Was this topic helpful?
Document Information
Modified date:
15 June 2018
UID
swg21081179