< prev index next >

src/hotspot/share/utilities/bitMap.inline.hpp

Print this page

        

*** 70,80 **** do { const bm_word_t new_val = old_val | mask; if (new_val == old_val) { return false; // Someone else beat us to it. } ! const bm_word_t cur_val = Atomic::cmpxchg(new_val, addr, old_val, memory_order); if (cur_val == old_val) { return true; // Success. } old_val = cur_val; // The value changed, try again. } while (true); --- 70,80 ---- do { const bm_word_t new_val = old_val | mask; if (new_val == old_val) { return false; // Someone else beat us to it. } ! const bm_word_t cur_val = Atomic::cmpxchg(addr, old_val, new_val, memory_order); if (cur_val == old_val) { return true; // Success. } old_val = cur_val; // The value changed, try again. } while (true);
*** 89,99 **** do { const bm_word_t new_val = old_val & mask; if (new_val == old_val) { return false; // Someone else beat us to it. } ! const bm_word_t cur_val = Atomic::cmpxchg(new_val, addr, old_val, memory_order); if (cur_val == old_val) { return true; // Success. } old_val = cur_val; // The value changed, try again. } while (true); --- 89,99 ---- do { const bm_word_t new_val = old_val & mask; if (new_val == old_val) { return false; // Someone else beat us to it. } ! const bm_word_t cur_val = Atomic::cmpxchg(addr, old_val, new_val, memory_order); if (cur_val == old_val) { return true; // Success. } old_val = cur_val; // The value changed, try again. } while (true);
< prev index next >