src/hotspot/share/gc/shenandoah/shenandoahRootProcessor.inline.hpp
changeset 59296 9186be5c78ba
parent 57837 2227a0cfd6b3
equal deleted inserted replaced
59295:8b6cc0bb93d0 59296:9186be5c78ba
    26 
    26 
    27 #include "classfile/classLoaderDataGraph.hpp"
    27 #include "classfile/classLoaderDataGraph.hpp"
    28 #include "classfile/stringTable.hpp"
    28 #include "classfile/stringTable.hpp"
    29 #include "classfile/systemDictionary.hpp"
    29 #include "classfile/systemDictionary.hpp"
    30 #include "gc/shared/oopStorageParState.inline.hpp"
    30 #include "gc/shared/oopStorageParState.inline.hpp"
       
    31 #include "gc/shenandoah/shenandoahClosures.inline.hpp"
       
    32 #include "gc/shenandoah/shenandoahConcurrentRoots.hpp"
    31 #include "gc/shenandoah/shenandoahHeuristics.hpp"
    33 #include "gc/shenandoah/shenandoahHeuristics.hpp"
    32 #include "gc/shenandoah/shenandoahRootProcessor.hpp"
    34 #include "gc/shenandoah/shenandoahRootProcessor.hpp"
    33 #include "gc/shenandoah/shenandoahTimingTracker.hpp"
    35 #include "gc/shenandoah/shenandoahTimingTracker.hpp"
    34 #include "gc/shenandoah/shenandoahUtils.hpp"
    36 #include "gc/shenandoah/shenandoahUtils.hpp"
    35 #include "memory/resourceArea.hpp"
    37 #include "memory/resourceArea.hpp"
   263 }
   265 }
   264 
   266 
   265 template <typename IsAlive, typename KeepAlive>
   267 template <typename IsAlive, typename KeepAlive>
   266 void ShenandoahRootUpdater::roots_do(uint worker_id, IsAlive* is_alive, KeepAlive* keep_alive) {
   268 void ShenandoahRootUpdater::roots_do(uint worker_id, IsAlive* is_alive, KeepAlive* keep_alive) {
   267   CodeBlobToOopClosure update_blobs(keep_alive, CodeBlobToOopClosure::FixRelocations);
   269   CodeBlobToOopClosure update_blobs(keep_alive, CodeBlobToOopClosure::FixRelocations);
       
   270   ShenandoahCodeBlobAndDisarmClosure blobs_and_disarm_Cl(keep_alive);
       
   271   CodeBlobToOopClosure* codes_cl = ShenandoahConcurrentRoots::can_do_concurrent_class_unloading() ?
       
   272                                   static_cast<CodeBlobToOopClosure*>(&blobs_and_disarm_Cl) :
       
   273                                   static_cast<CodeBlobToOopClosure*>(&update_blobs);
       
   274 
   268   CLDToOopClosure clds(keep_alive, ClassLoaderData::_claim_strong);
   275   CLDToOopClosure clds(keep_alive, ClassLoaderData::_claim_strong);
   269 
   276 
   270   _serial_roots.oops_do(keep_alive, worker_id);
   277   _serial_roots.oops_do(keep_alive, worker_id);
   271   _vm_roots.oops_do(keep_alive, worker_id);
   278   _vm_roots.oops_do(keep_alive, worker_id);
   272 
   279 
   273   _thread_roots.oops_do(keep_alive, NULL, worker_id);
       
   274   _cld_roots.cld_do(&clds, worker_id);
   280   _cld_roots.cld_do(&clds, worker_id);
   275   _code_roots.code_blobs_do(&update_blobs, worker_id);
   281   _code_roots.code_blobs_do(&update_blobs, worker_id);
       
   282   _thread_roots.oops_do(keep_alive, NULL, worker_id);
   276 
   283 
   277   _serial_weak_roots.weak_oops_do(is_alive, keep_alive, worker_id);
   284   _serial_weak_roots.weak_oops_do(is_alive, keep_alive, worker_id);
   278   _weak_roots.weak_oops_do(is_alive, keep_alive, worker_id);
   285   _weak_roots.weak_oops_do(is_alive, keep_alive, worker_id);
   279   _dedup_roots.oops_do(is_alive, keep_alive, worker_id);
   286   _dedup_roots.oops_do(is_alive, keep_alive, worker_id);
   280 }
   287 }