Mercurial > hg > graal-compiler
diff src/share/vm/gc_implementation/g1/g1CollectedHeap.cpp @ 20359:4d3a43351904
Merge
author | tschatzl |
---|---|
date | Wed, 27 Aug 2014 09:36:55 +0200 |
parents | 4bfc44ba0d19 439f0d76cff3 |
children | a8ea2f110d87 |
line wrap: on
line diff
--- a/src/share/vm/gc_implementation/g1/g1CollectedHeap.cpp Tue Aug 26 14:15:42 2014 +0200 +++ b/src/share/vm/gc_implementation/g1/g1CollectedHeap.cpp Wed Aug 27 09:36:55 2014 +0200 @@ -2336,25 +2336,6 @@ return blk.result(); } -size_t G1CollectedHeap::unsafe_max_alloc() { - if (num_free_regions() > 0) return HeapRegion::GrainBytes; - // otherwise, is there space in the current allocation region? - - // We need to store the current allocation region in a local variable - // here. The problem is that this method doesn't take any locks and - // there may be other threads which overwrite the current allocation - // region field. attempt_allocation(), for example, sets it to NULL - // and this can happen *after* the NULL check here but before the call - // to free(), resulting in a SIGSEGV. Note that this doesn't appear - // to be a problem in the optimized build, since the two loads of the - // current allocation region field are optimized away. - HeapRegion* hr = _mutator_alloc_region.get(); - if (hr == NULL) { - return 0; - } - return hr->free(); -} - bool G1CollectedHeap::should_do_concurrent_full_gc(GCCause::Cause cause) { switch (cause) { case GCCause::_gc_locker: return GCLockerInvokesConcurrent;