Mercurial > hg > truffle
comparison src/share/vm/gc_implementation/g1/heapRegionSet.inline.hpp @ 17841:14bd75c9dbfa
8039089: List verification enabled in product builds
Summary: Replaced the verification call to a conditional one that only runs verification in debug builds.
Reviewed-by: brutisso, tschatzl
author | jwilhelm |
---|---|
date | Thu, 03 Apr 2014 16:20:16 +0200 |
parents | 8ee855b4e667 |
children | 52b4284cb496 6701abbc4441 |
comparison
equal
deleted
inserted
replaced
17840:fd8ddf2d2f6b | 17841:14bd75c9dbfa |
---|---|
28 #include "gc_implementation/g1/heapRegionSet.hpp" | 28 #include "gc_implementation/g1/heapRegionSet.hpp" |
29 | 29 |
30 inline void HeapRegionSetBase::add(HeapRegion* hr) { | 30 inline void HeapRegionSetBase::add(HeapRegion* hr) { |
31 check_mt_safety(); | 31 check_mt_safety(); |
32 assert(hr->containing_set() == NULL, hrs_ext_msg(this, "should not already have a containing set %u")); | 32 assert(hr->containing_set() == NULL, hrs_ext_msg(this, "should not already have a containing set %u")); |
33 assert(hr->next() == NULL, hrs_ext_msg(this, "should not already be linked")); | 33 assert(hr->next() == NULL && hr->prev() == NULL, hrs_ext_msg(this, "should not already be linked")); |
34 | 34 |
35 _count.increment(1u, hr->capacity()); | 35 _count.increment(1u, hr->capacity()); |
36 hr->set_containing_set(this); | 36 hr->set_containing_set(this); |
37 verify_region(hr); | 37 verify_region(hr); |
38 } | 38 } |
39 | 39 |
40 inline void HeapRegionSetBase::remove(HeapRegion* hr) { | 40 inline void HeapRegionSetBase::remove(HeapRegion* hr) { |
41 check_mt_safety(); | 41 check_mt_safety(); |
42 verify_region(hr); | 42 verify_region(hr); |
43 assert(hr->next() == NULL, hrs_ext_msg(this, "should already be unlinked")); | 43 assert(hr->next() == NULL && hr->prev() == NULL, hrs_ext_msg(this, "should already be unlinked")); |
44 | 44 |
45 hr->set_containing_set(NULL); | 45 hr->set_containing_set(NULL); |
46 assert(_count.length() > 0, hrs_ext_msg(this, "pre-condition")); | 46 assert(_count.length() > 0, hrs_ext_msg(this, "pre-condition")); |
47 _count.decrement(1u, hr->capacity()); | 47 _count.decrement(1u, hr->capacity()); |
48 } | 48 } |