diff -r 18bd95c0e463 -r e5534cc91a10 src/hotspot/share/utilities/bitMap.inline.hpp --- a/src/hotspot/share/utilities/bitMap.inline.hpp Sat Nov 10 19:27:52 2018 +0100 +++ b/src/hotspot/share/utilities/bitMap.inline.hpp Sat Nov 10 20:47:28 2018 +0100 @@ -237,10 +237,12 @@ } inline void BitMap::set_large_range_of_words(idx_t beg, idx_t end) { + assert(beg <= end, "underflow"); memset(_map + beg, ~(unsigned char)0, (end - beg) * sizeof(bm_word_t)); } inline void BitMap::clear_large_range_of_words(idx_t beg, idx_t end) { + assert(beg <= end, "underflow"); memset(_map + beg, 0, (end - beg) * sizeof(bm_word_t)); }