< prev index next >

src/hotspot/share/gc/shared/c2/barrierSetC2.cpp

Print this page

        

*** 130,146 **** bool mismatched = (decorators & C2_MISMATCHED) != 0; bool requires_atomic_access = (decorators & MO_UNORDERED) == 0; bool unaligned = (decorators & C2_UNALIGNED) != 0; bool control_dependent = (decorators & C2_CONTROL_DEPENDENT_LOAD) != 0; ! bool unknown_control = (decorators & C2_UNKNOWN_CONTROL_LOAD) != 0; bool unsafe = (decorators & C2_UNSAFE_ACCESS) != 0; bool in_native = (decorators & IN_NATIVE) != 0; MemNode::MemOrd mo = access.mem_node_mo(); ! LoadNode::ControlDependency dep = unknown_control ? LoadNode::UnknownControl : LoadNode::DependsOnlyOnTest; Node* load; if (access.is_parse_access()) { C2ParseAccess& parse_access = static_cast<C2ParseAccess&>(access); GraphKit* kit = parse_access.kit(); --- 130,146 ---- bool mismatched = (decorators & C2_MISMATCHED) != 0; bool requires_atomic_access = (decorators & MO_UNORDERED) == 0; bool unaligned = (decorators & C2_UNALIGNED) != 0; bool control_dependent = (decorators & C2_CONTROL_DEPENDENT_LOAD) != 0; ! bool pinned = (decorators & C2_PINNED_LOAD) != 0; bool unsafe = (decorators & C2_UNSAFE_ACCESS) != 0; bool in_native = (decorators & IN_NATIVE) != 0; MemNode::MemOrd mo = access.mem_node_mo(); ! LoadNode::ControlDependency dep = pinned ? LoadNode::Pinned : LoadNode::DependsOnlyOnTest; Node* load; if (access.is_parse_access()) { C2ParseAccess& parse_access = static_cast<C2ParseAccess&>(access); GraphKit* kit = parse_access.kit();
*** 347,357 **** if (is_read && !is_write && anonymous) { // To be valid, unsafe loads may depend on other conditions than // the one that guards them: pin the Load node _decorators |= C2_CONTROL_DEPENDENT_LOAD; ! _decorators |= C2_UNKNOWN_CONTROL_LOAD; const TypePtr* adr_type = _addr.type(); Node* adr = _addr.node(); if (!needs_cpu_membar() && adr_type->isa_instptr()) { assert(adr_type->meet(TypePtr::NULL_PTR) != adr_type->remove_speculative(), "should be not null"); intptr_t offset = Type::OffsetBot; --- 347,357 ---- if (is_read && !is_write && anonymous) { // To be valid, unsafe loads may depend on other conditions than // the one that guards them: pin the Load node _decorators |= C2_CONTROL_DEPENDENT_LOAD; ! _decorators |= C2_PINNED_LOAD; const TypePtr* adr_type = _addr.type(); Node* adr = _addr.node(); if (!needs_cpu_membar() && adr_type->isa_instptr()) { assert(adr_type->meet(TypePtr::NULL_PTR) != adr_type->remove_speculative(), "should be not null"); intptr_t offset = Type::OffsetBot;
*** 359,369 **** if (offset >= 0) { int s = Klass::layout_helper_size_in_bytes(adr_type->isa_instptr()->klass()->layout_helper()); if (offset < s) { // Guaranteed to be a valid access, no need to pin it _decorators ^= C2_CONTROL_DEPENDENT_LOAD; ! _decorators ^= C2_UNKNOWN_CONTROL_LOAD; } } } } } --- 359,369 ---- if (offset >= 0) { int s = Klass::layout_helper_size_in_bytes(adr_type->isa_instptr()->klass()->layout_helper()); if (offset < s) { // Guaranteed to be a valid access, no need to pin it _decorators ^= C2_CONTROL_DEPENDENT_LOAD; ! _decorators ^= C2_PINNED_LOAD; } } } } }
< prev index next >