Mercurial > hg > graal-compiler
annotate src/share/vm/gc_implementation/g1/heapRegionSet.inline.hpp @ 17833:bfdf528be8e8
8038498: Fix includes and C inlining after 8035330
Summary: Change 8035330: Remove G1ParScanPartialArrayClosure and G1ParScanHeapEvacClosure broke the debug build on AIX. The method do_oop_partial_array() is added in a header, but requires the inline function par_write_ref() through several inlined calls. In some cpp files, like arguments.cpp, par_write_ref() is not defined as the corresponding inline header and is not included. The AIX debug VM does not start because of the missing symbol. This change solves this by cleaning up include dependencies.
Reviewed-by: tschatzl, stefank
author | tschatzl |
---|---|
date | Fri, 04 Apr 2014 10:43:56 +0200 |
parents | 8ee855b4e667 |
children | 14bd75c9dbfa |
rev | line source |
---|---|
2152 | 1 /* |
17773
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
2 * Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved. |
2152 | 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * | |
5 * This code is free software; you can redistribute it and/or modify it | |
6 * under the terms of the GNU General Public License version 2 only, as | |
7 * published by the Free Software Foundation. | |
8 * | |
9 * This code is distributed in the hope that it will be useful, but WITHOUT | |
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | |
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License | |
12 * version 2 for more details (a copy is included in the LICENSE file that | |
13 * accompanied this code). | |
14 * | |
15 * You should have received a copy of the GNU General Public License version | |
16 * 2 along with this work; if not, write to the Free Software Foundation, | |
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. | |
18 * | |
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA | |
20 * or visit www.oracle.com if you need additional information or have any | |
21 * questions. | |
22 * | |
23 */ | |
24 | |
25 #ifndef SHARE_VM_GC_IMPLEMENTATION_G1_HEAPREGIONSET_INLINE_HPP | |
26 #define SHARE_VM_GC_IMPLEMENTATION_G1_HEAPREGIONSET_INLINE_HPP | |
27 | |
28 #include "gc_implementation/g1/heapRegionSet.hpp" | |
29 | |
17736
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
30 inline void HeapRegionSetBase::add(HeapRegion* hr) { |
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
31 check_mt_safety(); |
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
32 assert(hr->containing_set() == NULL, hrs_ext_msg(this, "should not already have a containing set %u")); |
2361 | 33 assert(hr->next() == NULL, hrs_ext_msg(this, "should not already be linked")); |
2152 | 34 |
17736
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
35 _count.increment(1u, hr->capacity()); |
2152 | 36 hr->set_containing_set(this); |
17736
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
37 verify_region(hr); |
2152 | 38 } |
39 | |
17736
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
40 inline void HeapRegionSetBase::remove(HeapRegion* hr) { |
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
41 check_mt_safety(); |
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
42 verify_region(hr); |
2361 | 43 assert(hr->next() == NULL, hrs_ext_msg(this, "should already be unlinked")); |
2152 | 44 |
45 hr->set_containing_set(NULL); | |
17736
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
46 assert(_count.length() > 0, hrs_ext_msg(this, "pre-condition")); |
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
47 _count.decrement(1u, hr->capacity()); |
2152 | 48 } |
49 | |
17773
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
50 inline void FreeRegionList::add_ordered(HeapRegion* hr) { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
51 check_mt_safety(); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
52 assert((length() == 0 && _head == NULL && _tail == NULL) || |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
53 (length() > 0 && _head != NULL && _tail != NULL), |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
54 hrs_ext_msg(this, "invariant")); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
55 // add() will verify the region and check mt safety. |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
56 add(hr); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
57 |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
58 // Now link the region |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
59 if (_head != NULL) { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
60 HeapRegion* curr; |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
61 |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
62 if (_last != NULL && _last->hrs_index() < hr->hrs_index()) { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
63 curr = _last; |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
64 } else { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
65 curr = _head; |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
66 } |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
67 |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
68 // Find first entry with a Region Index larger than entry to insert. |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
69 while (curr != NULL && curr->hrs_index() < hr->hrs_index()) { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
70 curr = curr->next(); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
71 } |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
72 |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
73 hr->set_next(curr); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
74 |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
75 if (curr == NULL) { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
76 // Adding at the end |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
77 hr->set_prev(_tail); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
78 _tail->set_next(hr); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
79 _tail = hr; |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
80 } else if (curr->prev() == NULL) { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
81 // Adding at the beginning |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
82 hr->set_prev(NULL); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
83 _head = hr; |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
84 curr->set_prev(hr); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
85 } else { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
86 hr->set_prev(curr->prev()); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
87 hr->prev()->set_next(hr); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
88 curr->set_prev(hr); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
89 } |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
90 } else { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
91 // The list was empty |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
92 _tail = hr; |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
93 _head = hr; |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
94 } |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
95 _last = hr; |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
96 } |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
97 |
17736
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
98 inline void FreeRegionList::add_as_head(HeapRegion* hr) { |
2432
455328d90876
7029458: G1: Add newly-reclaimed regions to the beginning of the region free list, not the end
tonyp
parents:
2361
diff
changeset
|
99 assert((length() == 0 && _head == NULL && _tail == NULL) || |
455328d90876
7029458: G1: Add newly-reclaimed regions to the beginning of the region free list, not the end
tonyp
parents:
2361
diff
changeset
|
100 (length() > 0 && _head != NULL && _tail != NULL), |
455328d90876
7029458: G1: Add newly-reclaimed regions to the beginning of the region free list, not the end
tonyp
parents:
2361
diff
changeset
|
101 hrs_ext_msg(this, "invariant")); |
17736
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
102 // add() will verify the region and check mt safety. |
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
103 add(hr); |
2432
455328d90876
7029458: G1: Add newly-reclaimed regions to the beginning of the region free list, not the end
tonyp
parents:
2361
diff
changeset
|
104 |
455328d90876
7029458: G1: Add newly-reclaimed regions to the beginning of the region free list, not the end
tonyp
parents:
2361
diff
changeset
|
105 // Now link the region. |
455328d90876
7029458: G1: Add newly-reclaimed regions to the beginning of the region free list, not the end
tonyp
parents:
2361
diff
changeset
|
106 if (_head != NULL) { |
455328d90876
7029458: G1: Add newly-reclaimed regions to the beginning of the region free list, not the end
tonyp
parents:
2361
diff
changeset
|
107 hr->set_next(_head); |
17773
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
108 _head->set_prev(hr); |
2432
455328d90876
7029458: G1: Add newly-reclaimed regions to the beginning of the region free list, not the end
tonyp
parents:
2361
diff
changeset
|
109 } else { |
455328d90876
7029458: G1: Add newly-reclaimed regions to the beginning of the region free list, not the end
tonyp
parents:
2361
diff
changeset
|
110 _tail = hr; |
455328d90876
7029458: G1: Add newly-reclaimed regions to the beginning of the region free list, not the end
tonyp
parents:
2361
diff
changeset
|
111 } |
455328d90876
7029458: G1: Add newly-reclaimed regions to the beginning of the region free list, not the end
tonyp
parents:
2361
diff
changeset
|
112 _head = hr; |
455328d90876
7029458: G1: Add newly-reclaimed regions to the beginning of the region free list, not the end
tonyp
parents:
2361
diff
changeset
|
113 } |
455328d90876
7029458: G1: Add newly-reclaimed regions to the beginning of the region free list, not the end
tonyp
parents:
2361
diff
changeset
|
114 |
17736
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
115 inline void FreeRegionList::add_as_tail(HeapRegion* hr) { |
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
116 check_mt_safety(); |
2152 | 117 assert((length() == 0 && _head == NULL && _tail == NULL) || |
118 (length() > 0 && _head != NULL && _tail != NULL), | |
2361 | 119 hrs_ext_msg(this, "invariant")); |
17773
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
120 // add() will verify the region and check mt safety. |
17736
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
121 add(hr); |
2152 | 122 |
123 // Now link the region. | |
124 if (_tail != NULL) { | |
125 _tail->set_next(hr); | |
17773
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
126 hr->set_prev(_tail); |
2152 | 127 } else { |
128 _head = hr; | |
129 } | |
130 _tail = hr; | |
131 } | |
132 | |
17736
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
133 inline HeapRegion* FreeRegionList::remove_head() { |
2361 | 134 assert(!is_empty(), hrs_ext_msg(this, "the list should not be empty")); |
2152 | 135 assert(length() > 0 && _head != NULL && _tail != NULL, |
2361 | 136 hrs_ext_msg(this, "invariant")); |
2152 | 137 |
138 // We need to unlink it first. | |
139 HeapRegion* hr = _head; | |
140 _head = hr->next(); | |
141 if (_head == NULL) { | |
142 _tail = NULL; | |
17773
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
143 } else { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
144 _head->set_prev(NULL); |
2152 | 145 } |
146 hr->set_next(NULL); | |
147 | |
17773
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
148 if (_last == hr) { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
149 _last = NULL; |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
150 } |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
151 |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
152 // remove() will verify the region and check mt safety. |
17736
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
153 remove(hr); |
2152 | 154 return hr; |
155 } | |
156 | |
17736
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
157 inline HeapRegion* FreeRegionList::remove_head_or_null() { |
58fc1b1523dc
8034079: G1: Refactor the HeapRegionSet hierarchy
brutisso
parents:
6254
diff
changeset
|
158 check_mt_safety(); |
2152 | 159 if (!is_empty()) { |
160 return remove_head(); | |
161 } else { | |
162 return NULL; | |
163 } | |
164 } | |
165 | |
17773
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
166 inline HeapRegion* FreeRegionList::remove_tail() { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
167 assert(!is_empty(), hrs_ext_msg(this, "The list should not be empty")); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
168 assert(length() > 0 && _head != NULL && _tail != NULL, |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
169 hrs_ext_msg(this, "invariant")); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
170 |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
171 // We need to unlink it first |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
172 HeapRegion* hr = _tail; |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
173 |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
174 _tail = hr->prev(); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
175 if (_tail == NULL) { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
176 _head = NULL; |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
177 } else { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
178 _tail->set_next(NULL); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
179 } |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
180 hr->set_prev(NULL); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
181 |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
182 if (_last == hr) { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
183 _last = NULL; |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
184 } |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
185 |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
186 // remove() will verify the region and check mt safety. |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
187 remove(hr); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
188 return hr; |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
189 } |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
190 |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
191 inline HeapRegion* FreeRegionList::remove_tail_or_null() { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
192 check_mt_safety(); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
193 |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
194 if (!is_empty()) { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
195 return remove_tail(); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
196 } else { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
197 return NULL; |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
198 } |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
199 } |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
200 |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
201 inline HeapRegion* FreeRegionList::remove_region(bool from_head) { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
202 if (from_head) { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
203 return remove_head_or_null(); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
204 } else { |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
205 return remove_tail_or_null(); |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
206 } |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
207 } |
8ee855b4e667
8036025: Sort the freelist in order to shrink the heap
jwilhelm
parents:
17736
diff
changeset
|
208 |
2152 | 209 #endif // SHARE_VM_GC_IMPLEMENTATION_G1_HEAPREGIONSET_INLINE_HPP |