src/hotspot/share/opto/library_call.cpp
changeset 49796 6fa770f9f8ab
parent 48595 5d699d81c10c
child 49798 4bb2a92c13ea
--- a/src/hotspot/share/opto/library_call.cpp	Tue Feb 27 20:48:06 2018 +0000
+++ b/src/hotspot/share/opto/library_call.cpp	Mon Mar 05 13:18:55 2018 +0000
@@ -2578,7 +2578,8 @@
       // the one that guards them: pin the Load node
       LoadNode::ControlDependency dep = LoadNode::Pinned;
       Node* ctrl = control();
-      if (adr_type->isa_instptr()) {
+      // non volatile loads may be able to float
+      if (!need_mem_bar && adr_type->isa_instptr()) {
         assert(adr_type->meet(TypePtr::NULL_PTR) != adr_type->remove_speculative(), "should be not null");
         intptr_t offset = Type::OffsetBot;
         AddPNode::Ideal_base_and_offset(adr, &_gvn, offset);