0 /*
1 * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
2 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3 *
4 * This code is free software; you can redistribute it and/or modify it
5 * under the terms of the GNU General Public License version 2 only, as
6 * published by the Free Software Foundation.
7 *
8 * This code is distributed in the hope that it will be useful, but WITHOUT
9 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
10 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
11 * version 2 for more details (a copy is included in the LICENSE file that
12 * accompanied this code).
13 *
14 * You should have received a copy of the GNU General Public License version
15 * 2 along with this work; if not, write to the Free Software Foundation,
16 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
17 *
18 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
19 * or visit www.oracle.com if you need additional information or have any
20 * questions.
|
0 /*
1 * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
2 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3 *
4 * This code is free software; you can redistribute it and/or modify it
5 * under the terms of the GNU General Public License version 2 only, as
6 * published by the Free Software Foundation.
7 *
8 * This code is distributed in the hope that it will be useful, but WITHOUT
9 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
10 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
11 * version 2 for more details (a copy is included in the LICENSE file that
12 * accompanied this code).
13 *
14 * You should have received a copy of the GNU General Public License version
15 * 2 along with this work; if not, write to the Free Software Foundation,
16 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
17 *
18 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
19 * or visit www.oracle.com if you need additional information or have any
20 * questions.
|
56 static CMSHeap* heap();
57
58 virtual Name kind() const {
59 return CollectedHeap::CMSHeap;
60 }
61
62 virtual const char* name() const {
63 return "Concurrent Mark Sweep";
64 }
65
66 WorkGang* workers() const { return _workers; }
67
68 virtual void print_gc_threads_on(outputStream* st) const;
69 virtual void gc_threads_do(ThreadClosure* tc) const;
70 virtual void print_on_error(outputStream* st) const;
71
72 // Perform a full collection of the heap; intended for use in implementing
73 // "System.gc". This implies as full a collection as the CollectedHeap
74 // supports. Caller does not hold the Heap_lock on entry.
75 void collect(GCCause::Cause cause);
76
77 bool card_mark_must_follow_store() const {
78 return true;
79 }
80
81 void stop();
82 void safepoint_synchronize_begin();
83 void safepoint_synchronize_end();
84
85 virtual GrowableArray<GCMemoryManager*> memory_managers();
86 virtual GrowableArray<MemoryPool*> memory_pools();
87
88 // If "young_gen_as_roots" is false, younger generations are
89 // not scanned as roots; in this case, the caller must be arranging to
90 // scan the younger generations itself. (For example, a generation might
91 // explicitly mark reachable objects in younger generations, to avoid
92 // excess storage retention.)
93 void cms_process_roots(StrongRootsScope* scope,
94 bool young_gen_as_roots,
95 ScanningOption so,
96 bool only_strong_roots,
97 OopsInGenClosure* root_closure,
98 CLDClosure* cld_closure);
|
56 static CMSHeap* heap();
57
58 virtual Name kind() const {
59 return CollectedHeap::CMSHeap;
60 }
61
62 virtual const char* name() const {
63 return "Concurrent Mark Sweep";
64 }
65
66 WorkGang* workers() const { return _workers; }
67
68 virtual void print_gc_threads_on(outputStream* st) const;
69 virtual void gc_threads_do(ThreadClosure* tc) const;
70 virtual void print_on_error(outputStream* st) const;
71
72 // Perform a full collection of the heap; intended for use in implementing
73 // "System.gc". This implies as full a collection as the CollectedHeap
74 // supports. Caller does not hold the Heap_lock on entry.
75 void collect(GCCause::Cause cause);
76
77 void stop();
78 void safepoint_synchronize_begin();
79 void safepoint_synchronize_end();
80
81 virtual GrowableArray<GCMemoryManager*> memory_managers();
82 virtual GrowableArray<MemoryPool*> memory_pools();
83
84 // If "young_gen_as_roots" is false, younger generations are
85 // not scanned as roots; in this case, the caller must be arranging to
86 // scan the younger generations itself. (For example, a generation might
87 // explicitly mark reachable objects in younger generations, to avoid
88 // excess storage retention.)
89 void cms_process_roots(StrongRootsScope* scope,
90 bool young_gen_as_roots,
91 ScanningOption so,
92 bool only_strong_roots,
93 OopsInGenClosure* root_closure,
94 CLDClosure* cld_closure);
|