- 
    Type:
Bug
 - 
    Resolution: Fixed
 - 
    Priority:
  P3                     
     - 
    Affects Version/s: 8-shenandoah, 11.0.9, 15, 16
 - 
    Component/s: hotspot
 
- 
        b28
 
| Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build | 
|---|---|---|---|---|---|---|
| JDK-8257868 | 15u-cpu | Zhengyu Gu | P3 | Resolved | Fixed | master | 
| JDK-8257841 | 15.0.2 | Zhengyu Gu | P3 | Resolved | Fixed | b07 | 
| JDK-8258020 | 11.0.11 | Zhengyu Gu | P3 | Resolved | Fixed | b01 | 
| JDK-8257839 | 11.0.10 | Zhengyu Gu | P3 | Resolved | Fixed | b06 | 
                    Shenandoah GC specific safepoints are scheduled by control thread, therefore, query from control thread should return false.
I saw an assertion failure on x86_32, due to the wrong answer.
# Internal Error (/home/zgu/ws/jdk/src/hotspot/share/gc/shenandoah/shenandoahHeap.cpp:2036), pid=1410312, tid=1410328
# assert(nworkers == ParallelGCThreads) failed: Use ParallelGCThreads within safepoints
Native frames: (J=compiled Java code, A=aot compiled Java code, j=interpreted, Vv=VM code, C=native code)
V [libjvm.so+0x14c3977] ShenandoahHeap::assert_gc_workers(unsigned int)+0x157
V [libjvm.so+0x1497a9e] ShenandoahConcurrentGC::entry_evacuate()+0x8e
V [libjvm.so+0x149a4de] ShenandoahConcurrentGC::collect(GCCause::Cause)+0x28e
V [libjvm.so+0x14ac296] ShenandoahControlThread::service_concurrent_normal_cycle(GCCause::Cause)+0x96
V [libjvm.so+0x14acddd] ShenandoahControlThread::run_service()+0x74d
V [libjvm.so+0x9455c6] ConcurrentGCThread::run()+0x26
V [libjvm.so+0x16c602a] Thread::call_run()+0xfa
V [libjvm.so+0x12cd3d7] thread_native_entry(Thread*)+0x137
C [libpthread.so.0+0x867e] start_thread+0xee
            
I saw an assertion failure on x86_32, due to the wrong answer.
# Internal Error (/home/zgu/ws/jdk/src/hotspot/share/gc/shenandoah/shenandoahHeap.cpp:2036), pid=1410312, tid=1410328
# assert(nworkers == ParallelGCThreads) failed: Use ParallelGCThreads within safepoints
Native frames: (J=compiled Java code, A=aot compiled Java code, j=interpreted, Vv=VM code, C=native code)
V [libjvm.so+0x14c3977] ShenandoahHeap::assert_gc_workers(unsigned int)+0x157
V [libjvm.so+0x1497a9e] ShenandoahConcurrentGC::entry_evacuate()+0x8e
V [libjvm.so+0x149a4de] ShenandoahConcurrentGC::collect(GCCause::Cause)+0x28e
V [libjvm.so+0x14ac296] ShenandoahControlThread::service_concurrent_normal_cycle(GCCause::Cause)+0x96
V [libjvm.so+0x14acddd] ShenandoahControlThread::run_service()+0x74d
V [libjvm.so+0x9455c6] ConcurrentGCThread::run()+0x26
V [libjvm.so+0x16c602a] Thread::call_run()+0xfa
V [libjvm.so+0x12cd3d7] thread_native_entry(Thread*)+0x137
C [libpthread.so.0+0x867e] start_thread+0xee
- backported by
 - 
                    
JDK-8257839 Shenandoah: Query is_at_shenandoah_safepoint() from control thread should return false
-         
     - Resolved
 
 -         
 - 
                    
JDK-8257841 Shenandoah: Query is_at_shenandoah_safepoint() from control thread should return false
-         
     - Resolved
 
 -         
 - 
                    
JDK-8257868 Shenandoah: Query is_at_shenandoah_safepoint() from control thread should return false
-         
     - Resolved
 
 -         
 - 
                    
JDK-8258020 Shenandoah: Query is_at_shenandoah_safepoint() from control thread should return false
-         
     - Resolved
 
 -         
 
- relates to
 - 
                    
JDK-8253778 ShenandoahSafepoint::is_at_shenandoah_safepoint should not access VMThread state from other threads
-         
     - Closed
 
 -         
 
             (2 links to)