< prev index next >

src/hotspot/cpu/s390/macroAssembler_s390.cpp

Print this page
rev 51633 : imported patch 8210381

@@ -3372,17 +3372,15 @@
   if (try_bias) {
     biased_locking_enter(oop, displacedHeader, temp, Z_R0, done);
   }
 
   // Handle existing monitor.
-  if ((EmitSync & 0x01) == 0) {
     // The object has an existing monitor iff (mark & monitor_value) != 0.
     guarantee(Immediate::is_uimm16(markOopDesc::monitor_value), "must be half-word");
     z_lr(temp, displacedHeader);
     z_nill(temp, markOopDesc::monitor_value);
     z_brne(object_has_monitor);
-  }
 
   // Set mark to markOop | markOopDesc::unlocked_value.
   z_oill(displacedHeader, markOopDesc::unlocked_value);
 
   // Load Compare Value application register.

@@ -3409,11 +3407,10 @@
   //   z_release();
   z_stg(currentHeader/*==0 or not 0*/, BasicLock::displaced_header_offset_in_bytes(), box);
 
   z_bru(done);
 
-  if ((EmitSync & 0x01) == 0) {
     Register zero = temp;
     Register monitor_tagged = displacedHeader; // Tagged with markOopDesc::monitor_value.
     bind(object_has_monitor);
     // The object's monitor m is unlocked iff m->owner == NULL,
     // otherwise m->owner may contain a thread or a stack address.

@@ -3430,11 +3427,10 @@
       // Invariant 1: _recursions should be 0.
       asm_assert_mem8_is_zero(OM_OFFSET_NO_MONITOR_VALUE_TAG(recursions), monitor_tagged,
                               "monitor->_recursions should be 0", -1);
       z_ltgr(zero, zero); // Set CR=EQ.
 #endif
-  }
   bind(done);
 
   BLOCK_COMMENT("} compiler_fast_lock_object");
   // If locking was successful, CR should indicate 'EQ'.
   // The compiler or the native wrapper generates a branch to the runtime call

@@ -3459,27 +3455,24 @@
   // if the displaced header is zero, we have a recursive unlock.
   load_and_test_long(displacedHeader, Address(box, BasicLock::displaced_header_offset_in_bytes()));
   z_bre(done);
 
   // Handle existing monitor.
-  if ((EmitSync & 0x02) == 0) {
     // The object has an existing monitor iff (mark & monitor_value) != 0.
     z_lg(currentHeader, oopDesc::mark_offset_in_bytes(), oop);
     guarantee(Immediate::is_uimm16(markOopDesc::monitor_value), "must be half-word");
     z_nill(currentHeader, markOopDesc::monitor_value);
     z_brne(object_has_monitor);
-  }
 
   // Check if it is still a light weight lock, this is true if we see
   // the stack address of the basicLock in the markOop of the object
   // copy box to currentHeader such that csg does not kill it.
   z_lgr(currentHeader, box);
   z_csg(currentHeader, displacedHeader, 0, oop);
   z_bru(done); // Csg sets CR as desired.
 
   // Handle existing monitor.
-  if ((EmitSync & 0x02) == 0) {
     bind(object_has_monitor);
     z_lg(currentHeader, oopDesc::mark_offset_in_bytes(), oop);    // CurrentHeader is tagged with monitor_value set.
     load_and_test_long(temp, Address(currentHeader, OM_OFFSET_NO_MONITOR_VALUE_TAG(recursions)));
     z_brne(done);
     load_and_test_long(temp, Address(currentHeader, OM_OFFSET_NO_MONITOR_VALUE_TAG(owner)));

@@ -3488,11 +3481,10 @@
     z_brne(done);
     load_and_test_long(temp, Address(currentHeader, OM_OFFSET_NO_MONITOR_VALUE_TAG(cxq)));
     z_brne(done);
     z_release();
     z_stg(temp/*=0*/, OM_OFFSET_NO_MONITOR_VALUE_TAG(owner), currentHeader);
-  }
 
   bind(done);
 
   BLOCK_COMMENT("} compiler_fast_unlock_object");
   // flag == EQ indicates success
< prev index next >