< prev index next >

src/hotspot/share/gc/g1/g1FullGCPrepareTask.cpp

Print this page
@@ -32,10 +32,11 @@
  #include "gc/g1/g1FullGCPrepareTask.inline.hpp"
  #include "gc/g1/g1HotCardCache.hpp"
  #include "gc/g1/heapRegion.inline.hpp"
  #include "gc/shared/gcTraceTime.inline.hpp"
  #include "gc/shared/referenceProcessor.hpp"
+ #include "gc/shared/slidingForwarding.inline.hpp"
  #include "logging/log.hpp"
  #include "memory/iterator.inline.hpp"
  #include "oops/oop.inline.hpp"
  #include "utilities/ticks.hpp"
  

@@ -141,15 +142,15 @@
  
    return false;
  }
  
  G1FullGCPrepareTask::G1PrepareCompactLiveClosure::G1PrepareCompactLiveClosure(G1FullGCCompactionPoint* cp) :
-     _cp(cp) { }
+     _cp(cp), _forwarding(G1CollectedHeap::heap()->forwarding()) { }
  
  size_t G1FullGCPrepareTask::G1PrepareCompactLiveClosure::apply(oop object) {
    size_t size = object->size();
-   _cp->forward(object, size);
+   _cp->forward(_forwarding, object, size);
    return size;
  }
  
  void G1FullGCPrepareTask::G1CalculatePointersClosure::prepare_for_compaction(HeapRegion* hr) {
    if (!_collector->is_free(hr->hrm_index())) {
< prev index next >