hotspot/src/share/vm/gc_implementation/parallelScavenge/psPromotionManager.cpp
changeset 10676 1e1510b8031a
parent 8921 14bfe81f2a9d
child 11753 c9e420473a11
equal deleted inserted replaced
10675:8b887b2cb116 10676:1e1510b8031a
   378 
   378 
   379       // Try to deallocate the space.  If it was directly allocated we cannot
   379       // Try to deallocate the space.  If it was directly allocated we cannot
   380       // deallocate it, so we have to test.  If the deallocation fails,
   380       // deallocate it, so we have to test.  If the deallocation fails,
   381       // overwrite with a filler object.
   381       // overwrite with a filler object.
   382       if (new_obj_is_tenured) {
   382       if (new_obj_is_tenured) {
   383         if (!_old_lab.unallocate_object(new_obj)) {
   383         if (!_old_lab.unallocate_object((HeapWord*) new_obj, new_obj_size)) {
   384           CollectedHeap::fill_with_object((HeapWord*) new_obj, new_obj_size);
   384           CollectedHeap::fill_with_object((HeapWord*) new_obj, new_obj_size);
   385         }
   385         }
   386       } else if (!_young_lab.unallocate_object(new_obj)) {
   386       } else if (!_young_lab.unallocate_object((HeapWord*) new_obj, new_obj_size)) {
   387         CollectedHeap::fill_with_object((HeapWord*) new_obj, new_obj_size);
   387         CollectedHeap::fill_with_object((HeapWord*) new_obj, new_obj_size);
   388       }
   388       }
   389 
   389 
   390       // don't update this before the unallocation!
   390       // don't update this before the unallocation!
   391       new_obj = o->forwardee();
   391       new_obj = o->forwardee();