JDK-8321422 : Test gc/g1/pinnedobjs/TestPinnedObjectTypes.java times out after completion
  • Type: Bug
  • Component: hotspot
  • Sub-Component: gc
  • Affected Version: 22
  • Priority: P2
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2023-12-06
  • Updated: 2023-12-18
  • Resolved: 2023-12-12
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 22 JDK 23
22Fixed 23 b02Fixed
Description
The test times out after completion:


----------System.err:(3/35)----------

JavaTest Message: Test complete.

result: Error. Agent error: java.lang.Exception: Agent 18 timed out with a timeout of 480 seconds; check console log for any additional details 


Comments
A pull request was submitted for review. URL: https://git.openjdk.org/jdk22/pull/9 Date: 2023-12-12 10:42:32 +0000
12-12-2023

Changeset: 7d903964 Author: Thomas Schatzl <tschatzl@openjdk.org> Date: 2023-12-12 10:35:40 +0000 URL: https://git.openjdk.org/jdk/commit/7d903964fb1b8840664d4f0f9a4fa1a53111a856
12-12-2023

A pull request was submitted for review. URL: https://git.openjdk.org/jdk/pull/17013 Date: 2023-12-07 09:11:56 +0000
07-12-2023

That's the bug.
07-12-2023

Is there a reason these tests don't seem to be disabling coredumps?
07-12-2023

Original description: Test: gc/g1/pinnedobjs/TestPinnedObjectTypes.java # # A fatal error has been detected by the Java Runtime Environment: # # Internal Error (/System/Volumes/Data/mesos/work_dir/slaves/0db9c48f-6638-40d0-9a4b-bd9cc7533eb8-S29343/frameworks/1735e8a2-a1db-478c-8104-60c8b0af87dd-0196/executors/6c9387f4-f87a-4c8c-b263-39db871f3342/runs/4c4bbf2c-9526-498d-bd8e-6e76a31b7135/workspace/open/src/hotspot/share/gc/g1/g1CollectedHeap.inline.hpp:268), pid=98337, tid=5891 # assert(obj->is_typeArray()) failed: must be typeArray # # JRE version: Java(TM) SE Runtime Environment (22.0+27) (fastdebug build 22-ea+27-2215) # Java VM: Java HotSpot(TM) 64-Bit Server VM (fastdebug 22-ea+27-2215, mixed mode, sharing, tiered, compressed oops, compressed class ptrs, g1 gc, bsd-aarch64) # Core dump will be written. Default location: core.98337 # # If you would like to submit a bug report, please visit: # https://bugreport.java.com/bugreport/crash.jsp # --------------- S U M M A R Y ------------ Command Line: -XX:+UseG1GC -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -Xbootclasspath/a:. -Xmx32M -Xmn16M -Xlog:gc gc.g1.pinnedobjs.TestObjectPin ObjArray Host: "Macmini9,1" arm64, 8 cores, 16G, Darwin 21.3.0, macOS 12.2 (21D49) Time: Tue Dec 5 23:35:30 2023 GMT elapsed time: 0.114696 seconds (0d 0h 0m 0s) --------------- T H R E A D --------------- Current thread (0x000000014081e810): JavaThread "main" [_thread_in_vm, id=5891, stack(0x000000016dce4000,0x000000016dee7000) (2060K)] Stack: [0x000000016dce4000,0x000000016dee7000], sp=0x000000016dee6660, free space=2057k Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code) V [libjvm.dylib+0x1124f1c] VMError::report_and_die(int, char const*, char const*, char*, Thread*, unsigned char*, void*, void*, char const*, int, unsigned long)+0x564 (g1CollectedHeap.inline.hpp:268) V [libjvm.dylib+0x112573c] VMError::report_and_die(Thread*, unsigned int, unsigned char*, void*, void*)+0x0 V [libjvm.dylib+0x55ae64] print_error_for_unit_test(char const*, char const*, char*)+0x0 V [libjvm.dylib+0x6a72a4] G1CollectedHeap::pin_object(JavaThread*, oop)+0x1dc V [libjvm.dylib+0x11952c0] WB_PinObject+0x270 j jdk.test.whitebox.WhiteBox.pinObject(Ljava/lang/Object;)V+0 j gc.g1.pinnedobjs.TestObjectPin.main([Ljava/lang/String;)V+143 v ~StubRoutines::call_stub 0x00000001151a8190 V [libjvm.dylib+0x87ec6c] JavaCalls::call_helper(JavaValue*, methodHandle const&, JavaCallArguments*, JavaThread*)+0x420 V [libjvm.dylib+0x962bd4] jni_invoke_static(JNIEnv_*, JavaValue*, _jobject*, JNICallType, _jmethodID*, JNI_ArgumentPusher*, JavaThread*)+0x14c V [libjvm.dylib+0x96959c] jni_CallStaticVoidMethod+0x16c C [libjli.dylib+0xa290] invokeStaticMainWithArgs+0x84 C [libjli.dylib+0xaacc] JavaMain+0x588 C [libjli.dylib+0xd4d0] ThreadJavaMain+0xc C [libsystem_pthread.dylib+0x7240] _pthread_start+0x94 Java frames: (J=compiled Java code, j=interpreted, Vv=VM code) j jdk.test.whitebox.WhiteBox.pinObject(Ljava/lang/Object;)V+0 j gc.g1.pinnedobjs.TestObjectPin.main([Ljava/lang/String;)V+143 v ~StubRoutines::call_stub 0x00000001151a8190
06-12-2023

From the log: ----------System.err:(3/35)---------- JavaTest Message: Test complete. result: Error. Agent error: java.lang.Exception: Agent 18 timed out with a timeout of 480 seconds; check console log for any additional details
06-12-2023

I am not sure the test failure is because of the crashes - the test spawns VMs that ought to crash. The failure reason seems to be the timeout of the driver (given that there are three core files but only two hs_err files, i.e. two hs_err and core files for the intentional crashes and one additional core file for the timeout).
06-12-2023