Lines Matching defs:space

212   tty->print_cr("space  bottom     top        end        new_top");
216 const MutableSpace* space = _space_info[id].space();
221 summary_data().addr_to_region_idx(space->bottom()),
222 summary_data().addr_to_region_idx(space->top()),
223 summary_data().addr_to_region_idx(space->end()),
276 const MutableSpace* space = space_info[id].space();
277 print_generic_summary_data(summary_data, space->bottom(),
278 MAX2(space->top(), space_info[id].new_top()));
298 const MutableSpace* space) {
299 if (space->top() == space->bottom()) {
305 HeapWord* const top_aligned_up = summary_data.region_align_up(space->top());
309 const size_t live_in_space = pointer_delta(end_addr, space->bottom());
311 // Print (and count) the full regions at the beginning of the space.
313 size_t i = summary_data.addr_to_region_idx(space->bottom());
333 const size_t used_to_right = pointer_delta(space->top(), region_addr);
367 const MutableSpace* space;
369 space = space_info[id].space();
370 print_initial_summary_data(summary_data, space);
374 space = space_info[id].space();
375 print_generic_summary_data(summary_data, space->bottom(), space->top());
438 // Release memory reserved in the space.
559 // Find the point at which a space can be split and, if necessary, record the
562 // If the current src region (which overflowed the destination space) doesn't
584 "region should not fit into target space");
594 // destination space.
698 // If cur_region does not fit entirely into the target space, find a point
699 // at which the source space can be 'split' so that part is copied to the
700 // target space and the rest is copied elsewhere.
720 // to one destination space and the remaining data will be copied to
721 // another destination space. Adjust the initial destination_count and,
982 MutableSpace* const space = _space_info[id].space();
983 HeapWord* const bot = space->bottom();
984 HeapWord* const top = space->top();
1006 // Update the from & to space pointers in space_info, since they are swapped
1066 MutableSpace* const eden_space = _space_info[eden_space_id].space();
1067 MutableSpace* const from_space = _space_info[from_space_id].space();
1068 MutableSpace* const to_space = _space_info[to_space_id].space();
1121 const MutableSpace* const space = _space_info[id].space();
1122 HeapWord* const top_aligned_up = sd.region_align_up(space->top());
1123 const RegionData* const beg_cp = sd.addr_to_region_ptr(space->bottom());
1126 // Skip full regions at the beginning of the space--they are necessarily part
1143 const size_t space_live = pointer_delta(new_top, space->bottom());
1144 const size_t space_used = space->used_in_words();
1145 const size_t space_capacity = space->capacity_in_words();
1164 const RegionData* const top_cp = sd.addr_to_region_ptr(space->top() - 1);
1223 const MutableSpace* const space = _space_info[id].space();
1226 const size_t space_live = pointer_delta(new_top, space->bottom());
1228 const size_t space_cap = space->capacity_in_words();
1231 const size_t dead_to_right = space->top() - addr - live_to_right;
1362 // of each space into itself, and before final summarization.
1376 assert(new_top > bottom, "space is empty; should not be here");
1397 // the region with approximately that amount of dead space to the left is
1406 if (_space_info[id].dense_prefix() != _space_info[id].space()->bottom()) {
1407 // The value was chosen to provoke splitting a young gen space; use it.
1415 const MutableSpace* const space = _space_info[id].space();
1416 HeapWord* const top = space->top();
1420 HeapWord* const bottom = space->bottom();
1426 // Skip full regions at the beginning of the space--they are necessarily part
1430 space->is_empty(), "no dead space allowed to the left");
1432 "region must have dead space");
1447 const size_t space_used = space->used_in_words();
1448 const size_t space_capacity = space->capacity_in_words();
1469 // Locate the region with the desired amount of dead space to the left.
1473 // Scan from the first region with dead space to the limit region and find the
1487 // first region w/free space, choose the first region with free space
1523 MutableSpace* space = _space_info[id].space();
1530 } else if (src_addr > space->bottom()) {
1537 // Filling the entire space.
1538 dst_addr = space->bottom();
1544 src_addr, space->top(), NULL,
1545 dst_addr, space->end(),
1557 MutableSpace* const space = _space_info[id].space();
1558 if (space->is_empty()) {
1559 HeapWord* b = space->bottom();
1560 HeapWord* t = b + space->capacity_in_words() / 2;
1561 space->set_top(t);
1563 space->set_top_for_allocations();
1577 space->set_top(b);
1579 space->set_top_for_allocations();
1585 space->bottom(), space->top(), NULL,
1586 space->bottom(), space->end(), nta);
1587 assert(result, "space must fit into itself");
1601 MutableSpace* const eden_space = _space_info[eden_space_id].space();
1602 MutableSpace* const from_space = _space_info[from_space_id].space();
1614 // Choose the space to split; need at least 2 regions live (or fillable).
1616 MutableSpace* space;
1621 space = eden_space;
1626 space = from_space;
1636 HeapWord* const fill_start = space->top();
1639 space->set_top(fill_start + fill_words);
1641 space->set_top_for_allocations();
1666 // in the target young gen space (live_words / 2).
1668 space = _space_info[id].space();
1669 const size_t free_at_end = space->free_in_words();
1671 const size_t dead = pointer_delta(space->top(), _space_info[id].new_top());
1674 // Fill space above top() and set the dense prefix so everything survives.
1675 HeapWord* const fill_start = space->top();
1677 space->set_top(space->top() + fill_size);
1679 space->set_top_for_allocations();
1683 _space_info[id].set_dense_prefix(sd.region_align_down(space->top()));
1685 // Find a dense prefix that makes the right amount of space available.
1686 HeapWord* cur = sd.region_align_down(space->top());
1688 size_t dead_to_right = pointer_delta(space->end(), cur_destination);
1692 dead_to_right = pointer_delta(space->end(), cur_destination);
1702 const MutableSpace* space = _space_info[i].space();
1705 space->bottom(), space->top(), NULL,
1706 space->bottom(), space->end(), nta);
1707 assert(result, "space must fit into itself");
1708 _space_info[i].set_dense_prefix(space->bottom());
1724 // Only enough dead space is filled so that any remaining dead space to the
1728 // The size of the dead space to the right of the boundary is not a
1729 // concern, since compaction will be able to use whatever space is
1733 // surrounds the space to be filled with an object.
1800 assert(_space_info[id].dense_prefix() == _space_info[id].space()->bottom() ||
1804 const MutableSpace* space = _space_info[id].space();
1805 if (_space_info[id].new_top() != space->bottom()) {
1821 if (!maximum_compaction && dense_prefix_end != space->bottom()) {
1822 // If dead space crosses the dense prefix boundary, it is (at least
1826 // leaving a fragment of dead space that is too small to fill.
1830 _summary_data.summarize_dense_prefix(space->bottom(), dense_prefix_end);
1832 dense_prefix_end, space->top(), NULL,
1833 dense_prefix_end, space->end(),
1842 const size_t dp_words = pointer_delta(dense_prefix_end, space->bottom());
1849 id, space->capacity_in_words(), dense_prefix_end,
1896 // Quick summarization of each space into itself, to see how much is live.
1900 tty->print_cr("summary_phase: after summarizing each space to self");
1908 // The amount of live data that will end up in old space (assuming it fits).
1913 _space_info[id].space()->bottom());
1916 MutableSpace* const old_space = _space_info[old_space_id].space();
1932 // Summarize the remaining spaces in the young gen. The initial target space
1933 // is the old gen. If a space does not fit entirely into the target, then the
1934 // remainder is compacted into the space itself and that space becomes the new
1940 const MutableSpace* space = _space_info[id].space();
1942 space->bottom());
1946 SpaceId(id), space->bottom(), space->top());)
1950 space->bottom(), space->top(),
1954 assert(done, "space must fit into old gen");
1956 // Reset the new_top value for the space.
1957 _space_info[id].set_new_top(space->bottom());
1959 // Attempt to fit part of the source space into the target space.
1962 space->bottom(), space->top(),
1966 assert(!done, "space should not fit into old gen");
1969 // The source space becomes the new target, so the remainder is compacted
1970 // within the space itself.
1972 dst_space_end = space->end();
1975 space->bottom(), dst_space_end,
1976 SpaceId(id), next_src_addr, space->top());)
1978 next_src_addr, space->top(),
1980 space->bottom(), dst_space_end,
1982 assert(done, "space must fit when compacted into itself");
1983 assert(*new_top_addr <= space->top(), "usage should not grow");
2007 // activity. For example when the heap space is tight and full measure
2008 // are being taken to free space.
2170 // Calculate optimal free space amounts
2174 "Sizes of space in young gen are out-of-bounds");
2326 return false; // Must leave some space in eden.
2557 MutableSpace* const space = space_info->space();
2609 const MutableSpace* const space = _space_info[space_id].space();
2611 if (dense_prefix_end == space->bottom()) {
2612 // There is no dense prefix for this space.
2621 assert(dense_prefix_end == space->end() ||
2626 size_t region_index_start = sd.addr_to_region_idx(space->bottom());
2702 MutableSpace* const spc = _space_info[id].space();
2773 // All Regions between space bottom() to new_top() should be marked as filled
2779 HeapWord* old_top_addr = sd.region_align_up(si.space()->top());
2780 const size_t beg_region = sd.addr_to_region_idx(si.space()->bottom());
3040 if (beg_addr != space(space_id)->bottom()) {
3041 // Find the first live object or block of dead space that *starts* in this
3044 // processed. If dead space crosses onto the region, it is also skipped; it
3047 // space.
3048 assert(beg_addr > space(space_id)->bottom(), "sanity");
3058 // A live object or block of dead space starts in this range of Regions.
3080 // Return the SpaceId for the space containing addr. If addr is not in the
3087 if (_space_info[id].space()->contains(addr)) {
3092 assert(false, "no space contains the addr");
3098 assert(id < last_space_id, "bad space id");
3104 const MutableSpace* const space = space_info->space();
3105 assert(space_info->dense_prefix() >= space->bottom(), "dense_prefix not set");
3230 MutableSpace* const src_space = _space_info[src_space_id].space();
3267 // Skip empty regions (if any) up to the top of the space.
3278 // The next source region is in the current space. Update src_region_idx
3288 // Switch to a new source space and find the first non-empty region.
3295 MutableSpace* space = _space_info[space_id].space();
3296 HeapWord* const bottom = space->bottom();
3301 HeapWord* const top_aligned_up = sd.region_align_up(space->top());
3308 "first live obj in the space must match the destination");
3310 "a space cannot begin with a partial obj");
3313 src_space_top = space->top();
3347 HeapWord* src_space_top = _space_info[src_space_id].space()->top();
3404 assert(range_end < src_space_top, "obj cannot cross space boundary");
3491 const MutableSpace* sp = space(space_id);