src/share/vm/gc_implementation/g1/g1RegionToSpaceMapper.hpp
Print this page
rev 6805 : imported patch commit-uncommit-within-heap
rev 6807 : imported patch bengt-suggestions
rev 6808 : imported patch mikael-review-2
*** 28,37 ****
--- 28,39 ----
#include "gc_implementation/g1/g1PageBasedVirtualSpace.hpp"
#include "utilities/debug.hpp"
class G1MappingChangedListener VALUE_OBJ_CLASS_SPEC {
public:
+ // Fired after commit of the memory, i.e. the memory this listener is registered
+ // for can be accessed.
virtual void on_commit(uint start_idx, size_t num_regions) = 0;
};
// Maps region based commit/uncommit requests to the underlying page sized virtual
// space.
*** 63,72 ****
--- 65,79 ----
}
virtual void commit_regions(uintptr_t start_idx, size_t num_regions = 1) = 0;
virtual void uncommit_regions(uintptr_t start_idx, size_t num_regions = 1) = 0;
+ // Creates an appropriate G1RegionToSpaceMapper for the given parameters.
+ // The byte_translation_factor defines how many bytes in a region correspond to
+ // a single byte in the data structure this mapper is for.
+ // Eg. in the card table, this value corresponds to the size a single card
+ // table entry corresponds to.
static G1RegionToSpaceMapper* create_mapper(ReservedSpace rs,
size_t os_commit_granularity,
size_t region_granularity,
size_t byte_translation_factor,
MemoryType type);