author | tschatzl |
Tue, 29 May 2018 09:26:00 +0200 | |
changeset 50605 | 7f63c74f0974 |
parent 50525 | 767cdb97f103 |
permissions | -rw-r--r-- |
1 | 1 |
/* |
46415
7d5a286cdf89
8138737: Remove oop_ms_adjust_pointers and use oop_iterate instead
sjohanss
parents:
35492
diff
changeset
|
2 |
* Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved. |
1 | 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 |
* |
|
5547
f4b087cbb361
6941466: Oracle rebranding changes for Hotspot repositories
trims
parents:
1374
diff
changeset
|
19 |
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
f4b087cbb361
6941466: Oracle rebranding changes for Hotspot repositories
trims
parents:
1374
diff
changeset
|
20 |
* or visit www.oracle.com if you need additional information or have any |
f4b087cbb361
6941466: Oracle rebranding changes for Hotspot repositories
trims
parents:
1374
diff
changeset
|
21 |
* questions. |
1 | 22 |
* |
23 |
*/ |
|
24 |
||
30764 | 25 |
#ifndef SHARE_VM_GC_SHARED_SPECIALIZED_OOP_CLOSURES_HPP |
26 |
#define SHARE_VM_GC_SHARED_SPECIALIZED_OOP_CLOSURES_HPP |
|
7397 | 27 |
|
49982 | 28 |
#include "utilities/macros.hpp" |
29 |
#if INCLUDE_CMSGC |
|
30 |
#include "gc/cms/cms_specialized_oop_closures.hpp" |
|
31 |
#endif |
|
32 |
#if INCLUDE_G1GC |
|
33 |
#include "gc/g1/g1_specialized_oop_closures.hpp" |
|
34 |
#endif |
|
35 |
#if INCLUDE_SERIALGC |
|
49735
b3c09ab95c1a
8201217: Split specialized_oop_closures.hpp into GC specific files
stefank
parents:
47885
diff
changeset
|
36 |
#include "gc/serial/serial_specialized_oop_closures.hpp" |
49982 | 37 |
#endif |
50525
767cdb97f103
8204210: Implementation: JEP 333: ZGC: A Scalable Low-Latency Garbage Collector (Experimental)
pliden
parents:
50035
diff
changeset
|
38 |
#if INCLUDE_ZGC |
767cdb97f103
8204210: Implementation: JEP 333: ZGC: A Scalable Low-Latency Garbage Collector (Experimental)
pliden
parents:
50035
diff
changeset
|
39 |
#include "gc/z/z_specialized_oop_closures.hpp" |
767cdb97f103
8204210: Implementation: JEP 333: ZGC: A Scalable Low-Latency Garbage Collector (Experimental)
pliden
parents:
50035
diff
changeset
|
40 |
#endif |
7397 | 41 |
|
1 | 42 |
// The following OopClosure types get specialized versions of |
43 |
// "oop_oop_iterate" that invoke the closures' do_oop methods |
|
44 |
// non-virtually, using a mechanism defined in this file. Extend these |
|
45 |
// macros in the obvious way to add specializations for new closures. |
|
46 |
||
47 |
// Forward declarations. |
|
49735
b3c09ab95c1a
8201217: Split specialized_oop_closures.hpp into GC specific files
stefank
parents:
47885
diff
changeset
|
48 |
class ExtendedOopClosure; |
b3c09ab95c1a
8201217: Split specialized_oop_closures.hpp into GC specific files
stefank
parents:
47885
diff
changeset
|
49 |
class NoHeaderExtendedOopClosure; |
1 | 50 |
class OopsInGenClosure; |
51 |
||
52 |
// This macro applies an argument macro to all OopClosures for which we |
|
53 |
// want specialized bodies of "oop_oop_iterate". The arguments to "f" are: |
|
54 |
// "f(closureType, non_virtual)" |
|
29687 | 55 |
// where "closureType" is the name of the particular subclass of ExtendedOopClosure, |
1 | 56 |
// and "non_virtual" will be the string "_nv" if the closure type should |
57 |
// have its "do_oop" method invoked non-virtually, or else the |
|
29687 | 58 |
// string "_v". ("ExtendedOopClosure" itself will be the only class in the latter |
1 | 59 |
// category.) |
60 |
||
61 |
// This is split into several because of a Visual C++ 6.0 compiler bug |
|
62 |
// where very long macros cause the compiler to crash |
|
63 |
||
49735
b3c09ab95c1a
8201217: Split specialized_oop_closures.hpp into GC specific files
stefank
parents:
47885
diff
changeset
|
64 |
#define SPECIALIZED_OOP_OOP_ITERATE_CLOSURES_1(f) \ |
b3c09ab95c1a
8201217: Split specialized_oop_closures.hpp into GC specific files
stefank
parents:
47885
diff
changeset
|
65 |
f(NoHeaderExtendedOopClosure,_nv) \ |
49982 | 66 |
SERIALGC_ONLY(SPECIALIZED_OOP_OOP_ITERATE_CLOSURES_S(f)) \ |
67 |
CMSGC_ONLY(SPECIALIZED_OOP_OOP_ITERATE_CLOSURES_P(f)) |
|
32606
fdaa30d06ada
8129417: Oop iteration clean-up to remove oop_ms_follow_contents
sjohanss
parents:
30764
diff
changeset
|
68 |
|
49735
b3c09ab95c1a
8201217: Split specialized_oop_closures.hpp into GC specific files
stefank
parents:
47885
diff
changeset
|
69 |
#define SPECIALIZED_OOP_OOP_ITERATE_CLOSURES_2(f) \ |
49982 | 70 |
SERIALGC_ONLY(SPECIALIZED_OOP_OOP_ITERATE_CLOSURES_MS(f)) \ |
71 |
CMSGC_ONLY(SPECIALIZED_OOP_OOP_ITERATE_CLOSURES_CMS(f)) \ |
|
72 |
G1GC_ONLY(SPECIALIZED_OOP_OOP_ITERATE_CLOSURES_G1(f)) \ |
|
50525
767cdb97f103
8204210: Implementation: JEP 333: ZGC: A Scalable Low-Latency Garbage Collector (Experimental)
pliden
parents:
50035
diff
changeset
|
73 |
G1GC_ONLY(SPECIALIZED_OOP_OOP_ITERATE_CLOSURES_G1FULL(f)) \ |
767cdb97f103
8204210: Implementation: JEP 333: ZGC: A Scalable Low-Latency Garbage Collector (Experimental)
pliden
parents:
50035
diff
changeset
|
74 |
ZGC_ONLY(SPECIALIZED_OOP_OOP_ITERATE_CLOSURES_Z(f)) |
1374 | 75 |
|
1 | 76 |
// We separate these out, because sometime the general one has |
77 |
// a different definition from the specialized ones, and sometimes it |
|
78 |
// doesn't. |
|
79 |
||
49735
b3c09ab95c1a
8201217: Split specialized_oop_closures.hpp into GC specific files
stefank
parents:
47885
diff
changeset
|
80 |
#define ALL_OOP_OOP_ITERATE_CLOSURES_1(f) \ |
b3c09ab95c1a
8201217: Split specialized_oop_closures.hpp into GC specific files
stefank
parents:
47885
diff
changeset
|
81 |
f(ExtendedOopClosure,_v) \ |
1 | 82 |
SPECIALIZED_OOP_OOP_ITERATE_CLOSURES_1(f) |
83 |
||
49735
b3c09ab95c1a
8201217: Split specialized_oop_closures.hpp into GC specific files
stefank
parents:
47885
diff
changeset
|
84 |
#define ALL_OOP_OOP_ITERATE_CLOSURES_2(f) \ |
1374 | 85 |
SPECIALIZED_OOP_OOP_ITERATE_CLOSURES_2(f) |
1 | 86 |
|
30764 | 87 |
#endif // SHARE_VM_GC_SHARED_SPECIALIZED_OOP_CLOSURES_HPP |