mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 15:24:43 +02:00
8234740: Harmonize parameter order in Atomic - cmpxchg
Reviewed-by: rehn, dholmes
This commit is contained in:
parent
3d426623bf
commit
0ad50c2b5c
144 changed files with 504 additions and 506 deletions
|
@ -273,7 +273,7 @@ void ClassLoaderData::clear_claim(int claim) {
|
|||
return;
|
||||
}
|
||||
int new_claim = old_claim & ~claim;
|
||||
if (Atomic::cmpxchg(new_claim, &_claim, old_claim) == old_claim) {
|
||||
if (Atomic::cmpxchg(&_claim, old_claim, new_claim) == old_claim) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -286,7 +286,7 @@ bool ClassLoaderData::try_claim(int claim) {
|
|||
return false;
|
||||
}
|
||||
int new_claim = old_claim | claim;
|
||||
if (Atomic::cmpxchg(new_claim, &_claim, old_claim) == old_claim) {
|
||||
if (Atomic::cmpxchg(&_claim, old_claim, new_claim) == old_claim) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue