src/share/vm/gc_implementation/g1/g1RemSet.inline.hpp

changeset 3466
b4ebad3520bb
parent 3357
441e946dc1af
child 6876
710a3c8b516e
child 6937
b0c374311c4e
     1.1 --- a/src/share/vm/gc_implementation/g1/g1RemSet.inline.hpp	Wed Jan 25 21:14:11 2012 -0800
     1.2 +++ b/src/share/vm/gc_implementation/g1/g1RemSet.inline.hpp	Thu Jan 26 14:14:55 2012 -0800
     1.3 @@ -1,5 +1,5 @@
     1.4  /*
     1.5 - * Copyright (c) 2001, 2010, Oracle and/or its affiliates. All rights reserved.
     1.6 + * Copyright (c) 2001, 2012, Oracle and/or its affiliates. All rights reserved.
     1.7   * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     1.8   *
     1.9   * This code is free software; you can redistribute it and/or modify it
    1.10 @@ -85,66 +85,4 @@
    1.11    }
    1.12  }
    1.13  
    1.14 -template <class T>
    1.15 -inline void UpdateRSOrPushRefOopClosure::do_oop_work(T* p) {
    1.16 -  oop obj = oopDesc::load_decode_heap_oop(p);
    1.17 -#ifdef ASSERT
    1.18 -  // can't do because of races
    1.19 -  // assert(obj == NULL || obj->is_oop(), "expected an oop");
    1.20 -
    1.21 -  // Do the safe subset of is_oop
    1.22 -  if (obj != NULL) {
    1.23 -#ifdef CHECK_UNHANDLED_OOPS
    1.24 -    oopDesc* o = obj.obj();
    1.25 -#else
    1.26 -    oopDesc* o = obj;
    1.27 -#endif // CHECK_UNHANDLED_OOPS
    1.28 -    assert((intptr_t)o % MinObjAlignmentInBytes == 0, "not oop aligned");
    1.29 -    assert(Universe::heap()->is_in_reserved(obj), "must be in heap");
    1.30 -  }
    1.31 -#endif // ASSERT
    1.32 -
    1.33 -  assert(_from != NULL, "from region must be non-NULL");
    1.34 -
    1.35 -  HeapRegion* to = _g1->heap_region_containing(obj);
    1.36 -  if (to != NULL && _from != to) {
    1.37 -    // The _record_refs_into_cset flag is true during the RSet
    1.38 -    // updating part of an evacuation pause. It is false at all
    1.39 -    // other times:
    1.40 -    //  * rebuilding the rembered sets after a full GC
    1.41 -    //  * during concurrent refinement.
    1.42 -    //  * updating the remembered sets of regions in the collection
    1.43 -    //    set in the event of an evacuation failure (when deferred
    1.44 -    //    updates are enabled).
    1.45 -
    1.46 -    if (_record_refs_into_cset && to->in_collection_set()) {
    1.47 -      // We are recording references that point into the collection
    1.48 -      // set and this particular reference does exactly that...
    1.49 -      // If the referenced object has already been forwarded
    1.50 -      // to itself, we are handling an evacuation failure and
    1.51 -      // we have already visited/tried to copy this object
    1.52 -      // there is no need to retry.
    1.53 -      if (!self_forwarded(obj)) {
    1.54 -        assert(_push_ref_cl != NULL, "should not be null");
    1.55 -        // Push the reference in the refs queue of the G1ParScanThreadState
    1.56 -        // instance for this worker thread.
    1.57 -        _push_ref_cl->do_oop(p);
    1.58 -      }
    1.59 -
    1.60 -      // Deferred updates to the CSet are either discarded (in the normal case),
    1.61 -      // or processed (if an evacuation failure occurs) at the end
    1.62 -      // of the collection.
    1.63 -      // See G1RemSet::cleanup_after_oops_into_collection_set_do().
    1.64 -    } else {
    1.65 -      // We either don't care about pushing references that point into the
    1.66 -      // collection set (i.e. we're not during an evacuation pause) _or_
    1.67 -      // the reference doesn't point into the collection set. Either way
    1.68 -      // we add the reference directly to the RSet of the region containing
    1.69 -      // the referenced object.
    1.70 -      _g1_rem_set->par_write_ref(_from, p, _worker_i);
    1.71 -    }
    1.72 -  }
    1.73 -}
    1.74 -
    1.75 -
    1.76  #endif // SHARE_VM_GC_IMPLEMENTATION_G1_G1REMSET_INLINE_HPP

mercurial