提交 91454ec9 编写于 作者: T tonyp

6810698: G1: two small bugs in the sparse remembered sets

Summary: The _expanded flag of the sparse RSets is not reset and this can leave a RSet in an inconsistent state if it is expanded more than once. Also, we should be iterating over the _cur, instead of the _next, sparse table
Reviewed-by: apetrusenko, iveresov
上级 adef30f6
......@@ -504,6 +504,7 @@ void SparsePRT::cleanup() {
// Make sure that the current and next tables agree. (Another mechanism
// takes care of deleting now-unused tables.)
_cur = _next;
set_expanded(false);
}
void SparsePRT::expand() {
......
......@@ -274,7 +274,7 @@ public:
// Clean up all tables on the expanded list. Called single threaded.
static void cleanup_all();
RSHashTable* next() const { return _next; }
RSHashTable* cur() const { return _cur; }
void init_iterator(SparsePRTIter* sprt_iter);
......@@ -300,7 +300,7 @@ public:
{}
void init(const SparsePRT* sprt) {
RSHashTableIter::init(sprt->next());
RSHashTableIter::init(sprt->cur());
}
bool has_next(size_t& card_index) {
return RSHashTableIter::has_next(card_index);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册