-
Bug
-
Resolution: Fixed
-
P2
-
11, 15, 16
-
b08
-
Not verified
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-8257867 | 15u-cpu | Thomas Schatzl | P2 | Resolved | Fixed | master |
JDK-8251485 | 15.0.2 | Thomas Schatzl | P2 | Resolved | Fixed | b01 |
JDK-8251351 | 11.0.10-oracle | Manoj Gupta | P2 | Closed | Fixed | b01 |
JDK-8252850 | 11.0.10 | Thomas Schatzl | P2 | Resolved | Fixed | b01 |
Stack trace is typically like this:
V [libjvm.dylib+0x6ea177] G1ParScanThreadState::copy_to_survivor_space(G1HeapRegionAttr, oop, markWord)+0x67
V [libjvm.dylib+0x68585c] void G1ParScanThreadState::do_oop_evac<unsigned int>(unsigned int*)+0x1dc
V [libjvm.dylib+0x6e755b] G1ParScanThreadState::trim_queue_to_threshold(unsigned int)+0x15b
V [libjvm.dylib+0x6e9dca] G1ParScanThreadState::trim_queue()+0x1a
V [libjvm.dylib+0x680bbb] G1ParEvacuateFollowersClosure::do_void()+0x6b
V [libjvm.dylib+0x689ab4] G1EvacuateRegionsBaseTask::evacuate_live_objects(G1ParScanThreadState*, unsigned int, G1GCPhaseTimes::GCParPhases, G1GCPhaseTimes::GCParPhases)+0x94
V [libjvm.dylib+0x68984f] G1EvacuateRegionsBaseTask::work(unsigned int)+0x14f
V [libjvm.dylib+0x1105f80] GangWorker::run_task(WorkData)+0x60
V [libjvm.dylib+0x110603c] GangWorker::loop()+0x2c
Investigation showed that the broken oop has a invalid/broken Klass; it is always part of (first and only element of) an objArrayOop, and the test exercises code to generate and retrieve java thread stack frames
Attached patch adds an oop_iterate() call (in check_obj()) on all oops passed to user data structures when filling in stack frames; that crashes as follows, indicating some race with MonitorInfo::_owner.
V [libjvm.so+0x15a8ed8] check_obj(oop)+0x88
V [libjvm.so+0x15aa5db] LiveFrameStream::monitors_to_object_array(GrowableArray<MonitorInfo*>*, Thread*)+0xfb
V [libjvm.so+0x15aa916] LiveFrameStream::fill_live_stackframe(Handle, methodHandle const&, Thread*)+0xe6
V [libjvm.so+0x15aad5f] LiveFrameStream::fill_frame(int, objArrayHandle, methodHandle const&, Thread*)+0x12f
V [libjvm.so+0x15ab8a1] StackWalk::fill_in_frames(long, BaseFrameStream&, int, int, objArrayHandle, int&, Thread*)+0x361
V [libjvm.so+0x15ac575] StackWalk::fetchFirstBatch(BaseFrameStream&, Handle, long, int, int, int, objArrayHandle, Thread*)+0x2b5
V [libjvm.so+0x15aca20] StackWalk::walk(Handle, long, int, int, int, objArrayHandle, Thread*)+0x120
V [libjvm.so+0xe8d923] JVM_CallStackWalk+0x1d3
[The attached patch also adds some additional code to verify eden space (where the original crash always occurred) by calling oop_iterate() on all objects in it - it always crashes with above or quite similar stack trace *before* GC operation starts - i.e. the bad oop is created outside of gc. This verification code is needed because VerifyBeforeGC otherwise does not check Klasses.]
[~dlong] mentioned that this crash occurs in jdk 11/15/16; I only ever tried 15 and 16.
The crash also looks very much the recent crashes caused by integration of
Reproduction with that test and -XX:+UseJVMCICompiler is ~1/100 on jdk16 (also without the patch).
Kindly asking for investigation by the runtime team.
- backported by
-
JDK-8251485 MonitorInfo stores raw oops across safepoints
- Resolved
-
JDK-8252850 MonitorInfo stores raw oops across safepoints
- Resolved
-
JDK-8257867 MonitorInfo stores raw oops across safepoints
- Resolved
-
JDK-8251351 MonitorInfo stores raw oops across safepoints
- Closed
- blocks
-
JDK-8249676 [REDO] G1 incorrectly limiting young gen size when using the reserve can result in repeated full gcs
- Resolved
- duplicates
-
JDK-8248648 Dacapo24H.java failed "illegal bytecode sequence - method not verified"
- Closed
-
JDK-8248013 Crash occurs in java/lang/StackWalker/LocalsAndOperands.java
- Closed
-
JDK-8248432 StackWalker/LocalsAndOperands.java crashes with -Xcomp in loom repo
- Closed
- relates to
-
JDK-8140450 Implement JEP 259: Stack-Walking API
- Resolved
-
JDK-8251118 BiasedLocking::preserve_marks should not have a HandleMark
- Resolved
-
JDK-8248650 [BACKOUT] Backout JDK-8244603 because it generates too much noise in CI
- Resolved
-
JDK-8248013 Crash occurs in java/lang/StackWalker/LocalsAndOperands.java
- Closed
-
JDK-8248432 StackWalker/LocalsAndOperands.java crashes with -Xcomp in loom repo
- Closed