JDK-8265750 : Fatal error in safepoint.cpp after backport of 8258414
  • Type: Bug
  • Component: hotspot
  • Sub-Component: jfr
  • Affected Version: 11.0.12
  • Priority: P2
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2021-04-22
  • Updated: 2021-05-05
  • Resolved: 2021-04-28
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 11
11.0.12 b01Fixed
Related Reports
Relates :  
Relates :  
Description
We see a fatal error in jfr\startupargs\TestOldObjectQueueSize on Win x64 which I assume is caused by 8258414. 

At the moment we only have tests for release builds due to the broken debug builds, so I do not know if this would manifest in different asserts elsewhere.

#
# A fatal error has been detected by the Java Runtime Environment:
#
#  Internal Error (./src/hotspot/share/runtime/safepoint.cpp:894), pid=11412, tid=12932
#  fatal error: Deadlock in safepoint code.  Should have called back to the VM before blocking.
#
# JRE version: OpenJDK Runtime Environment (11.0.12) (build 11.0.12-internal+0-adhoc.openjdk.jdk11u-dev)
# Java VM: OpenJDK 64-Bit Server VM (11.0.12-internal+0-adhoc.openjdk.jdk11u-dev, mixed mode, tiered, compressed oops, g1 gc, windows-amd64)
# Core dump will be written. Default location: C:\jvmtests\output_openjdk11_dev_optU_ntamd64\jtreg_jdk_jdk_work\JTwork\jdk\jfr\startupargs\TestOldObjectQueueSize\hs_err_pid11412.mdmp
#
# If you would like to submit a bug report, please visit:
#   https://bugreport.java.com/bugreport/crash.jsp
#

Stack: [0x00000018ad600000,0x00000018ad700000]
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
V  [jvm.dll+0x5f9f9a]  os::platform_print_native_stack+0xca  (os_windows_x86.cpp:369)
V  [jvm.dll+0x73344e]  VMError::report+0xbce  (vmerror.cpp:709)
V  [jvm.dll+0x734b1f]  VMError::report_and_die+0x7df  (vmerror.cpp:1510)
V  [jvm.dll+0x735197]  VMError::report_and_die+0x47  (vmerror.cpp:1296)
V  [jvm.dll+0x247c64]  report_fatal+0x64  (debug.cpp:268)
V  [jvm.dll+0x65e30b]  SafepointSynchronize::block+0x14b  (safepoint.cpp:893)
V  [jvm.dll+0x101d44]  SafepointMechanism::block_if_requested+0x34  (safepointmechanism.inline.hpp:73)
V  [jvm.dll+0x6f0d9a]  JavaThread::check_safepoint_and_suspend_for_native_trans+0xca  (thread.cpp:2508)
V  [jvm.dll+0x5e3175]  ObjectSampleCheckpoint::on_rotation+0xa5  (objectsamplecheckpoint.cpp:301)
V  [jvm.dll+0x397694]  JfrRecorderService::pre_safepoint_write+0x64  (jfrrecorderservice.cpp:428)
V  [jvm.dll+0x3978a4]  JfrRecorderService::rotate+0x194  (jfrrecorderservice.cpp:325)
V  [jvm.dll+0x398324]  recorderthread_entry+0xd4  (jfrrecorderthreadloop.cpp:76)
V  [jvm.dll+0x6f7649]  JavaThread::run+0x139  (thread.cpp:1840)
V  [jvm.dll+0x6f06b4]  Thread::call_run+0x84  (thread.cpp:391)
V  [jvm.dll+0x5f8e36]  thread_native_entry+0xd6  (os_windows.cpp:460)
C  [ucrtbase.dll+0x1fb80]
C  [KERNEL32.DLL+0x84d4]
C  [ntdll.dll+0x51821]
Comments
URL: https://hg.openjdk.java.net/jdk-updates/jdk11u/rev/afa3d3646bda User: goetz Date: 2021-05-05 12:03:09 +0000
05-05-2021

URL: https://hg.openjdk.java.net/jdk-updates/jdk11u-dev/rev/afa3d3646bda User: jbachorik Date: 2021-04-28 15:48:09 +0000
28-04-2021

Review approval: https://mail.openjdk.java.net/pipermail/jdk-updates-dev/2021-April/005977.html
27-04-2021

The plan is to revert JDK-8258414 and JDK-8265718 in OpenJDK 11.0.12. Adding a link to JDK-8265718.
26-04-2021

Thanks, Thomas!
23-04-2021

Its JDK 11 specific.
23-04-2021

[~stuefe] Is this a JDK 11-only problem or do you see this in JDK 17 too?
23-04-2021