< prev index next >

src/hotspot/share/opto/runtime.cpp

Print this page

        

@@ -1657,11 +1657,11 @@
   NamedCounter* head;
   do {
     c->set_next(NULL);
     head = _named_counters;
     c->set_next(head);
-  } while (Atomic::cmpxchg(c, &_named_counters, head) != head);
+  } while (Atomic::cmpxchg(&_named_counters, head, c) != head);
   return c;
 }
 
 int trace_exception_counter = 0;
 static void trace_exception(outputStream* st, oop exception_oop, address exception_pc, const char* msg) {
< prev index next >