# HG changeset patch
# User zgu
# Date 1559740542 14400
# Node ID 27080d54c644f421508e2544355f3726ccd25430
# Parent  ec621f7f95f2c238385ca74ff18ada812ad61f00
8225341: Shenandoah: CM::update_thread_roots() needs to handle derived pointers
Reviewed-by: shade

diff -r ec621f7f95f2 -r 27080d54c644 src/hotspot/share/gc/shenandoah/shenandoahConcurrentMark.cpp
--- a/src/hotspot/share/gc/shenandoah/shenandoahConcurrentMark.cpp	Wed Jun 05 13:59:44 2019 +0100
+++ b/src/hotspot/share/gc/shenandoah/shenandoahConcurrentMark.cpp	Wed Jun 05 09:15:42 2019 -0400
@@ -331,8 +331,14 @@
 void ShenandoahConcurrentMark::update_thread_roots(ShenandoahPhaseTimings::Phase root_phase) {
   WorkGang* workers = _heap->workers();
   bool is_par = workers->active_workers() > 1;
+#if COMPILER2_OR_JVMCI
+  DerivedPointerTable::clear();
+#endif
   ShenandoahUpdateThreadRootsTask task(is_par, root_phase);
   workers->run_task(&task);
+#if COMPILER2_OR_JVMCI
+  DerivedPointerTable::update_pointers();
+#endif
 }
 
 void ShenandoahConcurrentMark::initialize(uint workers) {