< prev index next >
src/hotspot/share/code/nmethod.cpp
Print this page
@@ -1898,11 +1898,11 @@
assert(extract_state(_oops_do_mark_link) == claim_weak_request_tag ||
extract_state(_oops_do_mark_link) == claim_strong_request_tag,
"must be but is nmethod " PTR_FORMAT " %u", p2i(extract_nmethod(_oops_do_mark_link)), extract_state(_oops_do_mark_link));
- nmethod* old_head = Atomic::xchg(this, &_oops_do_mark_nmethods);
+ nmethod* old_head = Atomic::xchg(&_oops_do_mark_nmethods, this);
// Self-loop if needed.
if (old_head == NULL) {
old_head = this;
}
// Try to install end of list and weak done tag.
@@ -1915,11 +1915,11 @@
}
void nmethod::oops_do_add_to_list_as_strong_done() {
assert(SafepointSynchronize::is_at_safepoint(), "only at safepoint");
- nmethod* old_head = Atomic::xchg(this, &_oops_do_mark_nmethods);
+ nmethod* old_head = Atomic::xchg(&_oops_do_mark_nmethods, this);
// Self-loop if needed.
if (old_head == NULL) {
old_head = this;
}
assert(_oops_do_mark_link == mark_link(this, claim_strong_done_tag), "must be but is nmethod " PTR_FORMAT " state %u",
< prev index next >