diff --git a/src/hotspot/share/gc/shared/c2/barrierSetC2.cpp b/src/hotspot/share/gc/shared/c2/barrierSetC2.cpp index f41cd0e2ac3..69f89283f7d 100644 --- a/src/hotspot/share/gc/shared/c2/barrierSetC2.cpp +++ b/src/hotspot/share/gc/shared/c2/barrierSetC2.cpp @@ -85,9 +85,6 @@ Node* BarrierSetC2::store_at_resolved(C2Access& access, C2AccessValue& val) cons bool unsafe = (decorators & C2_UNSAFE_ACCESS) != 0; bool requires_atomic_access = (decorators & MO_UNORDERED) == 0; - bool in_native = (decorators & IN_NATIVE) != 0; - assert(!in_native || (unsafe && !access.is_oop()), "not supported yet"); - MemNode::MemOrd mo = access.mem_node_mo(); Node* store; @@ -144,8 +141,6 @@ Node* BarrierSetC2::load_at_resolved(C2Access& access, const Type* val_type) con bool unsafe = (decorators & C2_UNSAFE_ACCESS) != 0; bool immutable = (decorators & C2_IMMUTABLE_MEMORY) != 0; - bool in_native = (decorators & IN_NATIVE) != 0; - MemNode::MemOrd mo = access.mem_node_mo(); LoadNode::ControlDependency dep = unknown_control ? LoadNode::UnknownControl : LoadNode::DependsOnlyOnTest; diff --git a/src/hotspot/share/opto/library_call.cpp b/src/hotspot/share/opto/library_call.cpp index adef97537af..d4c511c672c 100644 --- a/src/hotspot/share/opto/library_call.cpp +++ b/src/hotspot/share/opto/library_call.cpp @@ -3350,9 +3350,7 @@ bool LibraryCallKit::inline_native_setCurrentThread() { = make_load(NULL, p, p->bottom_type()->is_ptr(), T_OBJECT, MemNode::unordered); thread_obj_handle = _gvn.transform(thread_obj_handle); const TypePtr *adr_type = _gvn.type(thread_obj_handle)->isa_ptr(); - // Stores of oops to native memory not supported yet by BarrierSetC2::store_at_resolved - // access_store_at(NULL, thread_obj_handle, adr_type, arr, _gvn.type(arr), T_OBJECT, IN_NATIVE | MO_UNORDERED); - store_to_memory(control(), thread_obj_handle, arr, T_OBJECT, adr_type, MemNode::unordered); + access_store_at(NULL, thread_obj_handle, adr_type, arr, _gvn.type(arr), T_OBJECT, IN_NATIVE | MO_UNORDERED); JFR_ONLY(extend_setCurrentThread(thread, arr);) return true; }