< prev index next >

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

Print this page
@@ -444,11 +444,11 @@
           "Unexpected region attr type: %s", region_attr.get_type_str());
  
    // Get the klass once.  We'll need it again later, and this avoids
    // re-decoding when it's compressed.
    Klass* klass = old->klass();
-   const size_t word_sz = old->size_given_klass(klass);
+   const size_t word_sz = old->compact_size_given_klass(klass);
  
    uint age = 0;
    G1HeapRegionAttr dest_attr = next_region_attr(region_attr, old_mark, age);
    HeapRegion* const from_region = _g1h->heap_region_containing(old);
    uint node_index = from_region->node_index();

@@ -477,11 +477,11 @@
      return handle_evacuation_failure_par(old, old_mark, word_sz);
    }
  
    // We're going to allocate linearly, so might as well prefetch ahead.
    Prefetch::write(obj_ptr, PrefetchCopyIntervalInBytes);
-   Copy::aligned_disjoint_words(cast_from_oop<HeapWord*>(old), obj_ptr, word_sz);
+   old->copy_disjoint_compact(obj_ptr, word_sz);
  
    const oop obj = cast_to_oop(obj_ptr);
    const oop forward_ptr = old->forward_to_atomic(obj, old_mark, memory_order_relaxed);
    if (forward_ptr == NULL) {
  
< prev index next >