2409 } |
2409 } |
2410 } |
2410 } |
2411 } |
2411 } |
2412 |
2412 |
2413 bool G1CollectedHeap::is_in(const void* p) const { |
2413 bool G1CollectedHeap::is_in(const void* p) const { |
2414 HeapRegion* hr = _hrs.addr_to_region((HeapWord*) p); |
2414 if (_g1_committed.contains(p)) { |
2415 if (hr != NULL) { |
2415 // Given that we know that p is in the committed space, |
|
2416 // heap_region_containing_raw() should successfully |
|
2417 // return the containing region. |
|
2418 HeapRegion* hr = heap_region_containing_raw(p); |
2416 return hr->is_in(p); |
2419 return hr->is_in(p); |
2417 } else { |
2420 } else { |
2418 return _perm_gen->as_gen()->is_in(p); |
2421 return _perm_gen->as_gen()->is_in(p); |
2419 } |
2422 } |
2420 } |
2423 } |