src/share/vm/opto/library_call.cpp
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File 7143491 Cdiff src/share/vm/opto/library_call.cpp

src/share/vm/opto/library_call.cpp

Print this page
rev 3081 : 7143491: G1 C2 CTW: assert(p2x->outcnt() == 2) failed: expects 2 users: Xor and URShift nodes
Summary: Adjust the assert and code in eliminate_card_mark() method for case when stored value is NULL.
Reviewed-by: iveresov

*** 2676,2686 **** break; case T_LONG: cas = _gvn.transform(new (C, 5) CompareAndSwapLNode(control(), mem, adr, newval, oldval)); break; case T_OBJECT: ! // reference stores need a store barrier. // (They don't if CAS fails, but it isn't worth checking.) pre_barrier(true /* do_load*/, control(), base, adr, alias_idx, newval, value_type->make_oopptr(), NULL /* pre_val*/, T_OBJECT); --- 2676,2692 ---- break; case T_LONG: cas = _gvn.transform(new (C, 5) CompareAndSwapLNode(control(), mem, adr, newval, oldval)); break; case T_OBJECT: ! // Transformation of a value which could be NULL pointer (CastPP #NULL) ! // could be delayed during Parse (for example, in adjust_map_after_if()). ! // Execute transformation here to avoid barrier generation in such case. ! if (_gvn.type(newval) == TypePtr::NULL_PTR) ! newval = _gvn.makecon(TypePtr::NULL_PTR); ! ! // Reference stores need a store barrier. // (They don't if CAS fails, but it isn't worth checking.) pre_barrier(true /* do_load*/, control(), base, adr, alias_idx, newval, value_type->make_oopptr(), NULL /* pre_val*/, T_OBJECT);
src/share/vm/opto/library_call.cpp
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File