< prev index next >

src/hotspot/share/opto/graphKit.cpp

8199604_cardtablemodrefbs_rename

*** 28,38 **** #include "gc/g1/g1BarrierSet.hpp" #include "gc/g1/g1CardTable.hpp" #include "gc/g1/heapRegion.hpp" #include "gc/shared/barrierSet.hpp" #include "gc/shared/cardTable.hpp" ! #include "gc/shared/cardTableModRefBS.hpp" #include "gc/shared/collectedHeap.hpp" #include "memory/resourceArea.hpp" #include "opto/addnode.hpp" #include "opto/castnode.hpp" #include "opto/convertnode.hpp" --- 28,38 ---- #include "gc/g1/g1BarrierSet.hpp" #include "gc/g1/g1CardTable.hpp" #include "gc/g1/heapRegion.hpp" #include "gc/shared/barrierSet.hpp" #include "gc/shared/cardTable.hpp" ! #include "gc/shared/cardTableBarrierSet.hpp" #include "gc/shared/collectedHeap.hpp" #include "memory/resourceArea.hpp" #include "opto/addnode.hpp" #include "opto/castnode.hpp" #include "opto/convertnode.hpp" ***************
*** 1563,1573 **** switch (bs->kind()) { case BarrierSet::G1BarrierSet: g1_write_barrier_pre(do_load, obj, adr, adr_idx, val, val_type, pre_val, bt); break; ! case BarrierSet::CardTableModRef: break; default : ShouldNotReachHere(); --- 1563,1573 ---- switch (bs->kind()) { case BarrierSet::G1BarrierSet: g1_write_barrier_pre(do_load, obj, adr, adr_idx, val, val_type, pre_val, bt); break; ! case BarrierSet::CardTableBarrierSet: break; default : ShouldNotReachHere(); ***************
*** 1578,1588 **** BarrierSet* bs = Universe::heap()->barrier_set(); switch (bs->kind()) { case BarrierSet::G1BarrierSet: return true; // Can move it if no safepoint ! case BarrierSet::CardTableModRef: return true; // There is no pre-barrier default : ShouldNotReachHere(); } --- 1578,1588 ---- BarrierSet* bs = Universe::heap()->barrier_set(); switch (bs->kind()) { case BarrierSet::G1BarrierSet: return true; // Can move it if no safepoint ! case BarrierSet::CardTableBarrierSet: return true; // There is no pre-barrier default : ShouldNotReachHere(); } ***************
*** 1602,1612 **** switch (bs->kind()) { case BarrierSet::G1BarrierSet: g1_write_barrier_post(store, obj, adr, adr_idx, val, bt, use_precise); break; ! case BarrierSet::CardTableModRef: write_barrier_post(store, obj, adr, adr_idx, val, use_precise); break; default : ShouldNotReachHere(); --- 1602,1612 ---- switch (bs->kind()) { case BarrierSet::G1BarrierSet: g1_write_barrier_post(store, obj, adr, adr_idx, val, bt, use_precise); break; ! case BarrierSet::CardTableBarrierSet: write_barrier_post(store, obj, adr, adr_idx, val, use_precise); break; default : ShouldNotReachHere(); ***************
*** 3809,3820 **** //----------------------------- store barriers ---------------------------- #define __ ideal. bool GraphKit::use_ReduceInitialCardMarks() { BarrierSet *bs = Universe::heap()->barrier_set(); ! return bs->is_a(BarrierSet::CardTableModRef) ! && barrier_set_cast<CardTableModRefBS>(bs)->can_elide_tlab_store_barriers() && ReduceInitialCardMarks; } void GraphKit::sync_kit(IdealKit& ideal) { set_all_memory(__ merged_memory()); --- 3809,3820 ---- //----------------------------- store barriers ---------------------------- #define __ ideal. bool GraphKit::use_ReduceInitialCardMarks() { BarrierSet *bs = Universe::heap()->barrier_set(); ! return bs->is_a(BarrierSet::CardTableBarrierSet) ! && barrier_set_cast<CardTableBarrierSet>(bs)->can_elide_tlab_store_barriers() && ReduceInitialCardMarks; } void GraphKit::sync_kit(IdealKit& ideal) { set_all_memory(__ merged_memory()); ***************
*** 3879,3889 **** // Convert the pointer to an int prior to doing math on it Node* cast = __ CastPX(__ ctrl(), adr); // Divide by card size ! assert(Universe::heap()->barrier_set()->is_a(BarrierSet::CardTableModRef), "Only one we handle so far."); Node* card_offset = __ URShiftX( cast, __ ConI(CardTable::card_shift) ); // Combine card table base and card offset Node* card_adr = __ AddP(__ top(), byte_map_base_node(), card_offset ); --- 3879,3889 ---- // Convert the pointer to an int prior to doing math on it Node* cast = __ CastPX(__ ctrl(), adr); // Divide by card size ! assert(Universe::heap()->barrier_set()->is_a(BarrierSet::CardTableBarrierSet), "Only one we handle so far."); Node* card_offset = __ URShiftX( cast, __ ConI(CardTable::card_shift) ); // Combine card table base and card offset Node* card_adr = __ AddP(__ top(), byte_map_base_node(), card_offset ); ***************
*** 4157,4167 **** * * In the case of slow allocation the allocation code must handle the barrier * as part of the allocation in the case the allocated object is not located * in the nursery, this would happen for humongous objects. This is similar to * how CMS is required to handle this case, see the comments for the method ! * CardTableModRefBS::on_allocation_slowpath_exit and OptoRuntime::new_deferred_store_barrier. * A deferred card mark is required for these objects and handled in the above * mentioned methods. * * Returns true if the post barrier can be removed */ --- 4157,4167 ---- * * In the case of slow allocation the allocation code must handle the barrier * as part of the allocation in the case the allocated object is not located * in the nursery, this would happen for humongous objects. This is similar to * how CMS is required to handle this case, see the comments for the method ! * CardTableBarrierSet::on_allocation_slowpath_exit and OptoRuntime::new_deferred_store_barrier. * A deferred card mark is required for these objects and handled in the above * mentioned methods. * * Returns true if the post barrier can be removed */
< prev index next >