< prev index next >

src/hotspot/share/gc/g1/g1SATBCardTableModRefBS.cpp

RFE_8195103_reduce_initial_card_marks
 /*
- * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2001, 2018, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
  * under the terms of the GNU General Public License version 2 only, as
  * published by the Free Software Foundation.

@@ -129,10 +129,11 { _listener.set_card_table(this); } void G1SATBCardTableLoggingModRefBS::initialize(G1RegionToSpaceMapper* mapper) { + initialize_deferred_card_mark_barriers(); mapper->set_mapping_changed_listener(&_listener); _byte_map_size = mapper->reserved().byte_size(); _guard_index = cards_required(_whole_heap.word_size()) - 1;
@@ -211,5 +212,16 } } } } } + +bool G1SATBCardTableModRefBS::is_in_young(oop obj) const { + volatile jbyte* p = byte_for((void*)obj); + return *p == g1_young_card_val(); +} + +void G1SATBCardTableLoggingModRefBS::flush_deferred_barriers(JavaThread* thread) { + CardTableModRefBS::flush_deferred_barriers(thread); + thread->satb_mark_queue().flush(); + thread->dirty_card_queue().flush(); +}
< prev index next >