< prev index next >

src/hotspot/share/c1/c1_GraphBuilder.cpp

Print this page

        

@@ -2215,10 +2215,11 @@
 
 
 void GraphBuilder::monitorenter(Value x, int bci) {
   // save state before locking in case of deoptimization after a NullPointerException
   ValueStack* state_before = copy_state_for_exception_with_bci(bci);
+  compilation()->set_has_monitors(true);
   append_with_bci(new MonitorEnter(x, state()->lock(x), state_before), bci);
   kill_all();
 }
 
 
< prev index next >