8134322: AArch64: Fix several errors in C2 biased locking implementation
authoradinn
Wed, 26 Aug 2015 17:13:59 +0100
changeset 32572 53295136b7bc
parent 32467 23b29549f8d1
child 32573 e0c433df24e0
8134322: AArch64: Fix several errors in C2 biased locking implementation Summary: Several errors in C2 biased locking require fixing Reviewed-by: kvn Contributed-by: hui.shi@linaro.org
hotspot/src/cpu/aarch64/vm/aarch64.ad
--- a/hotspot/src/cpu/aarch64/vm/aarch64.ad	Tue Sep 01 12:57:41 2015 +0300
+++ b/hotspot/src/cpu/aarch64/vm/aarch64.ad	Wed Aug 26 17:13:59 2015 +0100
@@ -4373,12 +4373,12 @@
       return;
     }
 
-    if (UseBiasedLocking) {
-      __ biased_locking_enter(disp_hdr, oop, box, tmp, true, cont);
+    if (UseBiasedLocking && !UseOptoBiasInlining) {
+      __ biased_locking_enter(box, oop, disp_hdr, tmp, true, cont);
     }
 
     // Handle existing monitor
-    if (EmitSync & 0x02) {
+    if ((EmitSync & 0x02) == 0) {
       // we can use AArch64's bit test and branch here but
       // markoopDesc does not define a bit index just the bit value
       // so assert in case the bit pos changes
@@ -4518,7 +4518,7 @@
       return;
     }
 
-    if (UseBiasedLocking) {
+    if (UseBiasedLocking && !UseOptoBiasInlining) {
       __ biased_locking_exit(oop, tmp, cont);
     }