Mercurial > hg > truffle
comparison src/share/vm/memory/genCollectedHeap.cpp @ 4708:3c648b9ad052
7121373: Clean up CollectedHeap::is_in
Summary: Fixed G1CollectedHeap::is_in, added tests, cleaned up comments and made Space::is_in pure virtual.
Reviewed-by: brutisso, tonyp, jcoomes
author | stefank |
---|---|
date | Wed, 14 Dec 2011 12:15:26 +0100 |
parents | 53074c2c4600 |
children | e7dead7e90af |
comparison
equal
deleted
inserted
replaced
4132:6d7d0790074d | 4708:3c648b9ad052 |
---|---|
955 assert(result == _gens[0]->is_in_reserved(p), | 955 assert(result == _gens[0]->is_in_reserved(p), |
956 err_msg("incorrect test - result=%d, p=" PTR_FORMAT, result, (void*)p)); | 956 err_msg("incorrect test - result=%d, p=" PTR_FORMAT, result, (void*)p)); |
957 return result; | 957 return result; |
958 } | 958 } |
959 | 959 |
960 // Returns "TRUE" iff "p" points into the allocated area of the heap. | 960 // Returns "TRUE" iff "p" points into the committed areas of the heap. |
961 bool GenCollectedHeap::is_in(const void* p) const { | 961 bool GenCollectedHeap::is_in(const void* p) const { |
962 #ifndef ASSERT | 962 #ifndef ASSERT |
963 guarantee(VerifyBeforeGC || | 963 guarantee(VerifyBeforeGC || |
964 VerifyDuringGC || | 964 VerifyDuringGC || |
965 VerifyBeforeExit || | 965 VerifyBeforeExit || |