Skip to content

Commit 1ce72ea

Browse files
committed
8281297: TestStressG1Humongous fails with guarantee(is_range_uncommitted)
Reviewed-by: eosterlund, iwalulya, tschatzl
1 parent cdd1b0d commit 1ce72ea

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/hotspot/share/utilities/bitMap.cpp

+4-4
Original file line numberDiff line numberDiff line change
@@ -232,10 +232,10 @@ void BitMap::par_put_range_within_word(idx_t beg, idx_t end, bool value) {
232232
// With a valid range (beg <= end), this test ensures that end != 0, as
233233
// required by inverted_bit_mask_for_range. Also avoids an unnecessary write.
234234
if (beg != end) {
235-
bm_word_t* pw = word_addr(beg);
236-
bm_word_t w = *pw;
237-
bm_word_t mr = inverted_bit_mask_for_range(beg, end);
238-
bm_word_t nw = value ? (w | ~mr) : (w & mr);
235+
volatile bm_word_t* pw = word_addr(beg);
236+
bm_word_t w = Atomic::load(pw);
237+
bm_word_t mr = inverted_bit_mask_for_range(beg, end);
238+
bm_word_t nw = value ? (w | ~mr) : (w & mr);
239239
while (true) {
240240
bm_word_t res = Atomic::cmpxchg(pw, w, nw);
241241
if (res == w) break;

0 commit comments

Comments
 (0)