--- old/src/share/vm/runtime/sharedRuntime.cpp 2018-03-07 01:26:37.728959784 -0800 +++ new/src/share/vm/runtime/sharedRuntime.cpp 2018-03-07 01:26:37.616949609 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2018, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -758,6 +758,8 @@ if (StackTraceInThrowable) { java_lang_Throwable::fill_in_stack_trace(exception); } + // Increment counter for hs_err file reporting + Atomic::inc(&Exceptions::_stack_overflow_errors); throw_and_post_jvmti_exception(thread, exception); JRT_END