src/hotspot/os/aix/os_aix.cpp
changeset 59252 623722a6aeb9
parent 59108 6f42d2a19117
child 59290 97d13893ec3c
--- a/src/hotspot/os/aix/os_aix.cpp	Mon Nov 25 12:32:40 2019 +0100
+++ b/src/hotspot/os/aix/os_aix.cpp	Mon Nov 25 12:33:15 2019 +0100
@@ -1084,7 +1084,7 @@
     if (now <= prev) {
       return prev;   // same or retrograde time;
     }
-    jlong obsv = Atomic::cmpxchg(now, &max_real_time, prev);
+    jlong obsv = Atomic::cmpxchg(&max_real_time, prev, now);
     assert(obsv >= prev, "invariant");   // Monotonicity
     // If the CAS succeeded then we're done and return "now".
     // If the CAS failed and the observed value "obsv" is >= now then
@@ -1794,7 +1794,7 @@
   for (;;) {
     for (int i = 0; i < NSIG + 1; i++) {
       jint n = pending_signals[i];
-      if (n > 0 && n == Atomic::cmpxchg(n - 1, &pending_signals[i], n)) {
+      if (n > 0 && n == Atomic::cmpxchg(&pending_signals[i], n, n - 1)) {
         return i;
       }
     }