hotspot/src/share/vm/gc/g1/g1ParScanThreadState.inline.hpp
changeset 34622 12a738c34eb9
parent 34616 421a6405ca30
child 35051 002d874a4284
equal deleted inserted replaced
34621:7676bec20997 34622:12a738c34eb9
    38   // set, due to (benign) races in the claim mechanism during RSet scanning more
    38   // set, due to (benign) races in the claim mechanism during RSet scanning more
    39   // than one thread might claim the same card. So the same card may be
    39   // than one thread might claim the same card. So the same card may be
    40   // processed multiple times. So redo this check.
    40   // processed multiple times. So redo this check.
    41   const InCSetState in_cset_state = _g1h->in_cset_state(obj);
    41   const InCSetState in_cset_state = _g1h->in_cset_state(obj);
    42   if (in_cset_state.is_in_cset()) {
    42   if (in_cset_state.is_in_cset()) {
    43     oop forwardee;
       
    44     markOop m = obj->mark();
    43     markOop m = obj->mark();
    45     if (m->is_marked()) {
    44     if (m->is_marked()) {
    46       forwardee = (oop) m->decode_pointer();
    45       obj = (oop) m->decode_pointer();
    47     } else {
    46     } else {
    48       forwardee = copy_to_survivor_space(in_cset_state, obj, m);
    47       obj = copy_to_survivor_space(in_cset_state, obj, m);
    49     }
    48     }
    50     oopDesc::encode_store_heap_oop(p, forwardee);
    49     oopDesc::encode_store_heap_oop(p, obj);
    51   } else if (in_cset_state.is_humongous()) {
    50   } else if (in_cset_state.is_humongous()) {
    52     _g1h->set_humongous_is_live(obj);
    51     _g1h->set_humongous_is_live(obj);
    53   } else {
    52   } else {
    54     assert(!in_cset_state.is_in_cset_or_humongous(),
    53     assert(!in_cset_state.is_in_cset_or_humongous(),
    55            "In_cset_state must be NotInCSet here, but is " CSETSTATE_FORMAT, in_cset_state.value());
    54            "In_cset_state must be NotInCSet here, but is " CSETSTATE_FORMAT, in_cset_state.value());