RFR[ 9u-dev] JDK-8138745: Implement ExitOnOutOfMemory and CrashOnOutOfMemory in HotSpot
Staffan Larsen
staffan.larsen at oracle.com
Wed Nov 25 12:57:21 UTC 2015
A couple of comments:
debug.cpp:
- When exiting due to ExitOnOutOfMemoryError I think we should print that we are exiting to tty.
- Perhaps the exit value should be made unique so that one can see the cause of the exit?
TestCrashOnOutOfMemoryError.java
- L33: nit: Don’t use * imports, list all the classes you import explicitly.
- L29: Since this test just launches a new JVM where the real testing is, it should be using the “@run driver” mode.
- L46: If -Xmx is set high enough, this allocation will succeed (or is my math wrong?). You should set an explicit -Xmx value on L50 when starting the JVM.
- L89: nit: indentation
- L97: nit: indentation
- L99-104: nit: indentation
TestExitOnOutOfMemoryError.java
- L33: nit: Don’t use * imports, list all the classes you import explicitly.
- L29: Since this test just launches a new JVM where the real testing is, it should be using the “@run driver” mode.
- L41: If -Xmx is set high enough, this allocation will succeed (or is my math wrong?). You should set an explicit -Xmx value on L46 when starting the JVM.
Thanks,
/Staffan
> On 25 nov. 2015, at 13:40, cheleswer sahu <cheleswer.sahu at oracle.com> wrote:
>
> Hi,
>
> Please review the code changes for "https://bugs.openjdk.java.net/browse/JDK-8138745" <https://bugs.openjdk.java.net/browse/JDK-8138745>.
> Web review link: <http://cr.openjdk.java.net/%7Ekevinw/8138745/webrev.00/>http://cr.openjdk.java.net/~kevinw/8138745/webrev.00/ <http://cr.openjdk.java.net/~kevinw/8138745/webrev.00/>
>
> Enhancement Brief:
> ExitOnOutOfMemoryError: When user enable this option, the JVM exits on the first occurrence of an out-of-memory error. It can be used if user prefer restarting an instance of the JVM rather than handling out of memory errors.
>
> CrashOnOutOfMemoryError: If this option is enabled, when an out-of-memory error occurs, the JVM crashes and produces text and binary crash files.
>
> For more details please refer http://ccc.us.oracle.com/8138745 <http://ccc.us.oracle.com/8138745>
>
>
> Regards,
> Cheleswer
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/serviceability-dev/attachments/20151125/cad3869b/attachment.html>
More information about the serviceability-dev
mailing list