annotate src/share/vm/runtime/globals_extension.hpp @ 3979:4dfb2df418f2

6484982: G1: process references during evacuation pauses Summary: G1 now uses two reference processors - one is used by concurrent marking and the other is used by STW GCs (both full and incremental evacuation pauses). In an evacuation pause, the reference processor is embedded into the closures used to scan objects. Doing so causes causes reference objects to be 'discovered' by the reference processor. At the end of the evacuation pause, these discovered reference objects are processed - preserving (and copying) referent objects (and their reachable graphs) as appropriate. Reviewed-by: ysr, jwilhelm, brutisso, stefank, tonyp
author johnc
date Thu, 22 Sep 2011 10:57:37 -0700
parents f95d63e2154a
children 763f01599ff4
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
a61af66fc99e Initial load
duke
parents:
diff changeset
1 /*
1972
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1552
diff changeset
2 * Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved.
0
a61af66fc99e Initial load
duke
parents:
diff changeset
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
a61af66fc99e Initial load
duke
parents:
diff changeset
4 *
a61af66fc99e Initial load
duke
parents:
diff changeset
5 * This code is free software; you can redistribute it and/or modify it
a61af66fc99e Initial load
duke
parents:
diff changeset
6 * under the terms of the GNU General Public License version 2 only, as
a61af66fc99e Initial load
duke
parents:
diff changeset
7 * published by the Free Software Foundation.
a61af66fc99e Initial load
duke
parents:
diff changeset
8 *
a61af66fc99e Initial load
duke
parents:
diff changeset
9 * This code is distributed in the hope that it will be useful, but WITHOUT
a61af66fc99e Initial load
duke
parents:
diff changeset
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
a61af66fc99e Initial load
duke
parents:
diff changeset
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
a61af66fc99e Initial load
duke
parents:
diff changeset
12 * version 2 for more details (a copy is included in the LICENSE file that
a61af66fc99e Initial load
duke
parents:
diff changeset
13 * accompanied this code).
a61af66fc99e Initial load
duke
parents:
diff changeset
14 *
a61af66fc99e Initial load
duke
parents:
diff changeset
15 * You should have received a copy of the GNU General Public License version
a61af66fc99e Initial load
duke
parents:
diff changeset
16 * 2 along with this work; if not, write to the Free Software Foundation,
a61af66fc99e Initial load
duke
parents:
diff changeset
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
a61af66fc99e Initial load
duke
parents:
diff changeset
18 *
1552
c18cbe5936b8 6941466: Oracle rebranding changes for Hotspot repositories
trims
parents: 1080
diff changeset
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
c18cbe5936b8 6941466: Oracle rebranding changes for Hotspot repositories
trims
parents: 1080
diff changeset
20 * or visit www.oracle.com if you need additional information or have any
c18cbe5936b8 6941466: Oracle rebranding changes for Hotspot repositories
trims
parents: 1080
diff changeset
21 * questions.
0
a61af66fc99e Initial load
duke
parents:
diff changeset
22 *
a61af66fc99e Initial load
duke
parents:
diff changeset
23 */
a61af66fc99e Initial load
duke
parents:
diff changeset
24
1972
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1552
diff changeset
25 #ifndef SHARE_VM_RUNTIME_GLOBALS_EXTENSION_HPP
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1552
diff changeset
26 #define SHARE_VM_RUNTIME_GLOBALS_EXTENSION_HPP
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1552
diff changeset
27
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1552
diff changeset
28 #include "runtime/globals.hpp"
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1552
diff changeset
29 #include "utilities/top.hpp"
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1552
diff changeset
30
0
a61af66fc99e Initial load
duke
parents:
diff changeset
31 // Construct enum of Flag_<cmdline-arg> constants.
a61af66fc99e Initial load
duke
parents:
diff changeset
32
a61af66fc99e Initial load
duke
parents:
diff changeset
33 // Parens left off in the following for the enum decl below.
a61af66fc99e Initial load
duke
parents:
diff changeset
34 #define FLAG_MEMBER(flag) Flag_##flag
a61af66fc99e Initial load
duke
parents:
diff changeset
35
a61af66fc99e Initial load
duke
parents:
diff changeset
36 #define RUNTIME_PRODUCT_FLAG_MEMBER(type, name, value, doc) FLAG_MEMBER(name),
a61af66fc99e Initial load
duke
parents:
diff changeset
37 #define RUNTIME_PD_PRODUCT_FLAG_MEMBER(type, name, doc) FLAG_MEMBER(name),
a61af66fc99e Initial load
duke
parents:
diff changeset
38 #define RUNTIME_DIAGNOSTIC_FLAG_MEMBER(type, name, value, doc) FLAG_MEMBER(name),
350
d28aa69f0959 6618726: Introduce -XX:+UnlockExperimentalVMOptions flag
ysr
parents: 342
diff changeset
39 #define RUNTIME_EXPERIMENTAL_FLAG_MEMBER(type, name, value, doc) FLAG_MEMBER(name),
0
a61af66fc99e Initial load
duke
parents:
diff changeset
40 #define RUNTIME_MANAGEABLE_FLAG_MEMBER(type, name, value, doc) FLAG_MEMBER(name),
a61af66fc99e Initial load
duke
parents:
diff changeset
41 #define RUNTIME_PRODUCT_RW_FLAG_MEMBER(type, name, value, doc) FLAG_MEMBER(name),
a61af66fc99e Initial load
duke
parents:
diff changeset
42 #ifdef PRODUCT
a61af66fc99e Initial load
duke
parents:
diff changeset
43 #define RUNTIME_DEVELOP_FLAG_MEMBER(type, name, value, doc) /* flag is constant */
a61af66fc99e Initial load
duke
parents:
diff changeset
44 #define RUNTIME_PD_DEVELOP_FLAG_MEMBER(type, name, doc) /* flag is constant */
a61af66fc99e Initial load
duke
parents:
diff changeset
45 #define RUNTIME_NOTPRODUCT_FLAG_MEMBER(type, name, value, doc)
a61af66fc99e Initial load
duke
parents:
diff changeset
46 #else
a61af66fc99e Initial load
duke
parents:
diff changeset
47 #define RUNTIME_DEVELOP_FLAG_MEMBER(type, name, value, doc) FLAG_MEMBER(name),
a61af66fc99e Initial load
duke
parents:
diff changeset
48 #define RUNTIME_PD_DEVELOP_FLAG_MEMBER(type, name, doc) FLAG_MEMBER(name),
a61af66fc99e Initial load
duke
parents:
diff changeset
49 #define RUNTIME_NOTPRODUCT_FLAG_MEMBER(type, name, value, doc) FLAG_MEMBER(name),
a61af66fc99e Initial load
duke
parents:
diff changeset
50 #endif
113
ba764ed4b6f2 6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents: 13
diff changeset
51 #ifdef _LP64
ba764ed4b6f2 6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents: 13
diff changeset
52 #define RUNTIME_LP64_PRODUCT_FLAG_MEMBER(type, name, value, doc) FLAG_MEMBER(name),
ba764ed4b6f2 6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents: 13
diff changeset
53 #else
ba764ed4b6f2 6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents: 13
diff changeset
54 #define RUNTIME_LP64_PRODUCT_FLAG_MEMBER(type, name, value, doc) /* flag is constant */
ba764ed4b6f2 6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents: 13
diff changeset
55 #endif // _LP64
0
a61af66fc99e Initial load
duke
parents:
diff changeset
56
a61af66fc99e Initial load
duke
parents:
diff changeset
57 #define C1_PRODUCT_FLAG_MEMBER(type, name, value, doc) FLAG_MEMBER(name),
a61af66fc99e Initial load
duke
parents:
diff changeset
58 #define C1_PD_PRODUCT_FLAG_MEMBER(type, name, doc) FLAG_MEMBER(name),
a61af66fc99e Initial load
duke
parents:
diff changeset
59 #ifdef PRODUCT
a61af66fc99e Initial load
duke
parents:
diff changeset
60 #define C1_DEVELOP_FLAG_MEMBER(type, name, value, doc) /* flag is constant */
a61af66fc99e Initial load
duke
parents:
diff changeset
61 #define C1_PD_DEVELOP_FLAG_MEMBER(type, name, doc) /* flag is constant */
a61af66fc99e Initial load
duke
parents:
diff changeset
62 #define C1_NOTPRODUCT_FLAG_MEMBER(type, name, value, doc)
a61af66fc99e Initial load
duke
parents:
diff changeset
63 #else
a61af66fc99e Initial load
duke
parents:
diff changeset
64 #define C1_DEVELOP_FLAG_MEMBER(type, name, value, doc) FLAG_MEMBER(name),
a61af66fc99e Initial load
duke
parents:
diff changeset
65 #define C1_PD_DEVELOP_FLAG_MEMBER(type, name, doc) FLAG_MEMBER(name),
a61af66fc99e Initial load
duke
parents:
diff changeset
66 #define C1_NOTPRODUCT_FLAG_MEMBER(type, name, value, doc) FLAG_MEMBER(name),
a61af66fc99e Initial load
duke
parents:
diff changeset
67 #endif
a61af66fc99e Initial load
duke
parents:
diff changeset
68
a61af66fc99e Initial load
duke
parents:
diff changeset
69
a61af66fc99e Initial load
duke
parents:
diff changeset
70 #define C2_PRODUCT_FLAG_MEMBER(type, name, value, doc) FLAG_MEMBER(name),
a61af66fc99e Initial load
duke
parents:
diff changeset
71 #define C2_PD_PRODUCT_FLAG_MEMBER(type, name, doc) FLAG_MEMBER(name),
a61af66fc99e Initial load
duke
parents:
diff changeset
72 #define C2_DIAGNOSTIC_FLAG_MEMBER(type, name, value, doc) FLAG_MEMBER(name),
1080
7c57aead6d3e 6892658: C2 should optimize some stringbuilder patterns
never
parents: 1064
diff changeset
73 #define C2_EXPERIMENTAL_FLAG_MEMBER(type, name, value, doc) FLAG_MEMBER(name),
0
a61af66fc99e Initial load
duke
parents:
diff changeset
74 #ifdef PRODUCT
a61af66fc99e Initial load
duke
parents:
diff changeset
75 #define C2_DEVELOP_FLAG_MEMBER(type, name, value, doc) /* flag is constant */
a61af66fc99e Initial load
duke
parents:
diff changeset
76 #define C2_PD_DEVELOP_FLAG_MEMBER(type, name, doc) /* flag is constant */
a61af66fc99e Initial load
duke
parents:
diff changeset
77 #define C2_NOTPRODUCT_FLAG_MEMBER(type, name, value, doc)
a61af66fc99e Initial load
duke
parents:
diff changeset
78 #else
a61af66fc99e Initial load
duke
parents:
diff changeset
79 #define C2_DEVELOP_FLAG_MEMBER(type, name, value, doc) FLAG_MEMBER(name),
a61af66fc99e Initial load
duke
parents:
diff changeset
80 #define C2_PD_DEVELOP_FLAG_MEMBER(type, name, doc) FLAG_MEMBER(name),
a61af66fc99e Initial load
duke
parents:
diff changeset
81 #define C2_NOTPRODUCT_FLAG_MEMBER(type, name, value, doc) FLAG_MEMBER(name),
a61af66fc99e Initial load
duke
parents:
diff changeset
82 #endif
a61af66fc99e Initial load
duke
parents:
diff changeset
83
a61af66fc99e Initial load
duke
parents:
diff changeset
84 typedef enum {
350
d28aa69f0959 6618726: Introduce -XX:+UnlockExperimentalVMOptions flag
ysr
parents: 342
diff changeset
85 RUNTIME_FLAGS(RUNTIME_DEVELOP_FLAG_MEMBER, RUNTIME_PD_DEVELOP_FLAG_MEMBER, RUNTIME_PRODUCT_FLAG_MEMBER, RUNTIME_PD_PRODUCT_FLAG_MEMBER, RUNTIME_DIAGNOSTIC_FLAG_MEMBER, RUNTIME_EXPERIMENTAL_FLAG_MEMBER, RUNTIME_NOTPRODUCT_FLAG_MEMBER, RUNTIME_MANAGEABLE_FLAG_MEMBER, RUNTIME_PRODUCT_RW_FLAG_MEMBER, RUNTIME_LP64_PRODUCT_FLAG_MEMBER)
342
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
86 RUNTIME_OS_FLAGS(RUNTIME_DEVELOP_FLAG_MEMBER, RUNTIME_PD_DEVELOP_FLAG_MEMBER, RUNTIME_PRODUCT_FLAG_MEMBER, RUNTIME_PD_PRODUCT_FLAG_MEMBER, RUNTIME_DIAGNOSTIC_FLAG_MEMBER, RUNTIME_NOTPRODUCT_FLAG_MEMBER)
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
87 #ifndef KERNEL
350
d28aa69f0959 6618726: Introduce -XX:+UnlockExperimentalVMOptions flag
ysr
parents: 342
diff changeset
88 G1_FLAGS(RUNTIME_DEVELOP_FLAG_MEMBER, RUNTIME_PD_DEVELOP_FLAG_MEMBER, RUNTIME_PRODUCT_FLAG_MEMBER, RUNTIME_PD_PRODUCT_FLAG_MEMBER, RUNTIME_DIAGNOSTIC_FLAG_MEMBER, RUNTIME_EXPERIMENTAL_FLAG_MEMBER, RUNTIME_NOTPRODUCT_FLAG_MEMBER, RUNTIME_MANAGEABLE_FLAG_MEMBER, RUNTIME_PRODUCT_RW_FLAG_MEMBER)
342
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
89 #endif
0
a61af66fc99e Initial load
duke
parents:
diff changeset
90 #ifdef COMPILER1
342
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
91 C1_FLAGS(C1_DEVELOP_FLAG_MEMBER, C1_PD_DEVELOP_FLAG_MEMBER, C1_PRODUCT_FLAG_MEMBER, C1_PD_PRODUCT_FLAG_MEMBER, C1_NOTPRODUCT_FLAG_MEMBER)
0
a61af66fc99e Initial load
duke
parents:
diff changeset
92 #endif
a61af66fc99e Initial load
duke
parents:
diff changeset
93 #ifdef COMPILER2
1080
7c57aead6d3e 6892658: C2 should optimize some stringbuilder patterns
never
parents: 1064
diff changeset
94 C2_FLAGS(C2_DEVELOP_FLAG_MEMBER, C2_PD_DEVELOP_FLAG_MEMBER, C2_PRODUCT_FLAG_MEMBER, C2_PD_PRODUCT_FLAG_MEMBER, C2_DIAGNOSTIC_FLAG_MEMBER, C2_EXPERIMENTAL_FLAG_MEMBER, C2_NOTPRODUCT_FLAG_MEMBER)
0
a61af66fc99e Initial load
duke
parents:
diff changeset
95 #endif
a61af66fc99e Initial load
duke
parents:
diff changeset
96 NUM_CommandLineFlag
a61af66fc99e Initial load
duke
parents:
diff changeset
97 } CommandLineFlag;
a61af66fc99e Initial load
duke
parents:
diff changeset
98
a61af66fc99e Initial load
duke
parents:
diff changeset
99 // Construct enum of Flag_<cmdline-arg>_<type> constants.
a61af66fc99e Initial load
duke
parents:
diff changeset
100
a61af66fc99e Initial load
duke
parents:
diff changeset
101 #define FLAG_MEMBER_WITH_TYPE(flag,type) Flag_##flag##_##type
a61af66fc99e Initial load
duke
parents:
diff changeset
102
a61af66fc99e Initial load
duke
parents:
diff changeset
103 #define RUNTIME_PRODUCT_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) FLAG_MEMBER_WITH_TYPE(name,type),
a61af66fc99e Initial load
duke
parents:
diff changeset
104 #define RUNTIME_PD_PRODUCT_FLAG_MEMBER_WITH_TYPE(type, name, doc) FLAG_MEMBER_WITH_TYPE(name,type),
a61af66fc99e Initial load
duke
parents:
diff changeset
105 #define RUNTIME_DIAGNOSTIC_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) FLAG_MEMBER_WITH_TYPE(name,type),
350
d28aa69f0959 6618726: Introduce -XX:+UnlockExperimentalVMOptions flag
ysr
parents: 342
diff changeset
106 #define RUNTIME_EXPERIMENTAL_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) FLAG_MEMBER_WITH_TYPE(name,type),
0
a61af66fc99e Initial load
duke
parents:
diff changeset
107 #define RUNTIME_MANAGEABLE_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) FLAG_MEMBER_WITH_TYPE(name,type),
a61af66fc99e Initial load
duke
parents:
diff changeset
108 #define RUNTIME_PRODUCT_RW_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) FLAG_MEMBER_WITH_TYPE(name,type),
a61af66fc99e Initial load
duke
parents:
diff changeset
109 #ifdef PRODUCT
a61af66fc99e Initial load
duke
parents:
diff changeset
110 #define RUNTIME_DEVELOP_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) /* flag is constant */
a61af66fc99e Initial load
duke
parents:
diff changeset
111 #define RUNTIME_PD_DEVELOP_FLAG_MEMBER_WITH_TYPE(type, name, doc) /* flag is constant */
a61af66fc99e Initial load
duke
parents:
diff changeset
112 #define RUNTIME_NOTPRODUCT_FLAG_MEMBER_WITH_TYPE(type, name, value, doc)
a61af66fc99e Initial load
duke
parents:
diff changeset
113 #else
a61af66fc99e Initial load
duke
parents:
diff changeset
114 #define RUNTIME_DEVELOP_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) FLAG_MEMBER_WITH_TYPE(name,type),
a61af66fc99e Initial load
duke
parents:
diff changeset
115 #define RUNTIME_PD_DEVELOP_FLAG_MEMBER_WITH_TYPE(type, name, doc) FLAG_MEMBER_WITH_TYPE(name,type),
a61af66fc99e Initial load
duke
parents:
diff changeset
116 #define RUNTIME_NOTPRODUCT_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) FLAG_MEMBER_WITH_TYPE(name,type),
a61af66fc99e Initial load
duke
parents:
diff changeset
117 #endif
a61af66fc99e Initial load
duke
parents:
diff changeset
118
a61af66fc99e Initial load
duke
parents:
diff changeset
119 #define C1_PRODUCT_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) FLAG_MEMBER_WITH_TYPE(name,type),
a61af66fc99e Initial load
duke
parents:
diff changeset
120 #define C1_PD_PRODUCT_FLAG_MEMBER_WITH_TYPE(type, name, doc) FLAG_MEMBER_WITH_TYPE(name,type),
a61af66fc99e Initial load
duke
parents:
diff changeset
121 #ifdef PRODUCT
a61af66fc99e Initial load
duke
parents:
diff changeset
122 #define C1_DEVELOP_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) /* flag is constant */
a61af66fc99e Initial load
duke
parents:
diff changeset
123 #define C1_PD_DEVELOP_FLAG_MEMBER_WITH_TYPE(type, name, doc) /* flag is constant */
a61af66fc99e Initial load
duke
parents:
diff changeset
124 #define C1_NOTPRODUCT_FLAG_MEMBER_WITH_TYPE(type, name, value, doc)
a61af66fc99e Initial load
duke
parents:
diff changeset
125 #else
a61af66fc99e Initial load
duke
parents:
diff changeset
126 #define C1_DEVELOP_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) FLAG_MEMBER_WITH_TYPE(name,type),
a61af66fc99e Initial load
duke
parents:
diff changeset
127 #define C1_PD_DEVELOP_FLAG_MEMBER_WITH_TYPE(type, name, doc) FLAG_MEMBER_WITH_TYPE(name,type),
a61af66fc99e Initial load
duke
parents:
diff changeset
128 #define C1_NOTPRODUCT_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) FLAG_MEMBER_WITH_TYPE(name,type),
a61af66fc99e Initial load
duke
parents:
diff changeset
129 #endif
113
ba764ed4b6f2 6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents: 13
diff changeset
130 #ifdef _LP64
ba764ed4b6f2 6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents: 13
diff changeset
131 #define RUNTIME_LP64_PRODUCT_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) FLAG_MEMBER_WITH_TYPE(name,type),
ba764ed4b6f2 6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents: 13
diff changeset
132 #else
ba764ed4b6f2 6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents: 13
diff changeset
133 #define RUNTIME_LP64_PRODUCT_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) /* flag is constant */
ba764ed4b6f2 6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents: 13
diff changeset
134 #endif // _LP64
0
a61af66fc99e Initial load
duke
parents:
diff changeset
135
a61af66fc99e Initial load
duke
parents:
diff changeset
136
a61af66fc99e Initial load
duke
parents:
diff changeset
137 #define C2_PRODUCT_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) FLAG_MEMBER_WITH_TYPE(name,type),
a61af66fc99e Initial load
duke
parents:
diff changeset
138 #define C2_PD_PRODUCT_FLAG_MEMBER_WITH_TYPE(type, name, doc) FLAG_MEMBER_WITH_TYPE(name,type),
a61af66fc99e Initial load
duke
parents:
diff changeset
139 #define C2_DIAGNOSTIC_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) FLAG_MEMBER_WITH_TYPE(name,type),
1080
7c57aead6d3e 6892658: C2 should optimize some stringbuilder patterns
never
parents: 1064
diff changeset
140 #define C2_EXPERIMENTAL_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) FLAG_MEMBER_WITH_TYPE(name,type),
0
a61af66fc99e Initial load
duke
parents:
diff changeset
141 #ifdef PRODUCT
a61af66fc99e Initial load
duke
parents:
diff changeset
142 #define C2_DEVELOP_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) /* flag is constant */
a61af66fc99e Initial load
duke
parents:
diff changeset
143 #define C2_PD_DEVELOP_FLAG_MEMBER_WITH_TYPE(type, name, doc) /* flag is constant */
a61af66fc99e Initial load
duke
parents:
diff changeset
144 #define C2_NOTPRODUCT_FLAG_MEMBER_WITH_TYPE(type, name, value, doc)
a61af66fc99e Initial load
duke
parents:
diff changeset
145 #else
a61af66fc99e Initial load
duke
parents:
diff changeset
146 #define C2_DEVELOP_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) FLAG_MEMBER_WITH_TYPE(name,type),
a61af66fc99e Initial load
duke
parents:
diff changeset
147 #define C2_PD_DEVELOP_FLAG_MEMBER_WITH_TYPE(type, name, doc) FLAG_MEMBER_WITH_TYPE(name,type),
a61af66fc99e Initial load
duke
parents:
diff changeset
148 #define C2_NOTPRODUCT_FLAG_MEMBER_WITH_TYPE(type, name, value, doc) FLAG_MEMBER_WITH_TYPE(name,type),
a61af66fc99e Initial load
duke
parents:
diff changeset
149 #endif
a61af66fc99e Initial load
duke
parents:
diff changeset
150
a61af66fc99e Initial load
duke
parents:
diff changeset
151 typedef enum {
342
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
152 RUNTIME_FLAGS(RUNTIME_DEVELOP_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
153 RUNTIME_PD_DEVELOP_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
154 RUNTIME_PRODUCT_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
155 RUNTIME_PD_PRODUCT_FLAG_MEMBER_WITH_TYPE,
0
a61af66fc99e Initial load
duke
parents:
diff changeset
156 RUNTIME_DIAGNOSTIC_FLAG_MEMBER_WITH_TYPE,
350
d28aa69f0959 6618726: Introduce -XX:+UnlockExperimentalVMOptions flag
ysr
parents: 342
diff changeset
157 RUNTIME_EXPERIMENTAL_FLAG_MEMBER_WITH_TYPE,
0
a61af66fc99e Initial load
duke
parents:
diff changeset
158 RUNTIME_NOTPRODUCT_FLAG_MEMBER_WITH_TYPE,
a61af66fc99e Initial load
duke
parents:
diff changeset
159 RUNTIME_MANAGEABLE_FLAG_MEMBER_WITH_TYPE,
113
ba764ed4b6f2 6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents: 13
diff changeset
160 RUNTIME_PRODUCT_RW_FLAG_MEMBER_WITH_TYPE,
ba764ed4b6f2 6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents: 13
diff changeset
161 RUNTIME_LP64_PRODUCT_FLAG_MEMBER_WITH_TYPE)
342
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
162 RUNTIME_OS_FLAGS(RUNTIME_DEVELOP_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
163 RUNTIME_PD_DEVELOP_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
164 RUNTIME_PRODUCT_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
165 RUNTIME_PD_PRODUCT_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
166 RUNTIME_DIAGNOSTIC_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
167 RUNTIME_NOTPRODUCT_FLAG_MEMBER_WITH_TYPE)
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
168 #ifndef KERNEL
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
169 G1_FLAGS(RUNTIME_DEVELOP_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
170 RUNTIME_PD_DEVELOP_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
171 RUNTIME_PRODUCT_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
172 RUNTIME_PD_PRODUCT_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
173 RUNTIME_DIAGNOSTIC_FLAG_MEMBER_WITH_TYPE,
350
d28aa69f0959 6618726: Introduce -XX:+UnlockExperimentalVMOptions flag
ysr
parents: 342
diff changeset
174 RUNTIME_EXPERIMENTAL_FLAG_MEMBER_WITH_TYPE,
342
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
175 RUNTIME_NOTPRODUCT_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
176 RUNTIME_MANAGEABLE_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
177 RUNTIME_PRODUCT_RW_FLAG_MEMBER_WITH_TYPE)
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
178 #endif // KERNEL
0
a61af66fc99e Initial load
duke
parents:
diff changeset
179 #ifdef COMPILER1
342
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
180 C1_FLAGS(C1_DEVELOP_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
181 C1_PD_DEVELOP_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
182 C1_PRODUCT_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
183 C1_PD_PRODUCT_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
184 C1_NOTPRODUCT_FLAG_MEMBER_WITH_TYPE)
0
a61af66fc99e Initial load
duke
parents:
diff changeset
185 #endif
a61af66fc99e Initial load
duke
parents:
diff changeset
186 #ifdef COMPILER2
342
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
187 C2_FLAGS(C2_DEVELOP_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
188 C2_PD_DEVELOP_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
189 C2_PRODUCT_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
190 C2_PD_PRODUCT_FLAG_MEMBER_WITH_TYPE,
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
191 C2_DIAGNOSTIC_FLAG_MEMBER_WITH_TYPE,
1080
7c57aead6d3e 6892658: C2 should optimize some stringbuilder patterns
never
parents: 1064
diff changeset
192 C2_EXPERIMENTAL_FLAG_MEMBER_WITH_TYPE,
342
37f87013dfd8 6711316: Open source the Garbage-First garbage collector
ysr
parents: 113
diff changeset
193 C2_NOTPRODUCT_FLAG_MEMBER_WITH_TYPE)
0
a61af66fc99e Initial load
duke
parents:
diff changeset
194 #endif
a61af66fc99e Initial load
duke
parents:
diff changeset
195 NUM_CommandLineFlagWithType
a61af66fc99e Initial load
duke
parents:
diff changeset
196 } CommandLineFlagWithType;
a61af66fc99e Initial load
duke
parents:
diff changeset
197
a61af66fc99e Initial load
duke
parents:
diff changeset
198 #define FLAG_IS_DEFAULT(name) (CommandLineFlagsEx::is_default(FLAG_MEMBER(name)))
13
183f41cf8bfe 6557851: CMS: ergonomics defaults are not set with FLAG_SET_ERGO
jmasa
parents: 0
diff changeset
199 #define FLAG_IS_ERGO(name) (CommandLineFlagsEx::is_ergo(FLAG_MEMBER(name)))
183f41cf8bfe 6557851: CMS: ergonomics defaults are not set with FLAG_SET_ERGO
jmasa
parents: 0
diff changeset
200 #define FLAG_IS_CMDLINE(name) (CommandLineFlagsEx::is_cmdline(FLAG_MEMBER(name)))
0
a61af66fc99e Initial load
duke
parents:
diff changeset
201
a61af66fc99e Initial load
duke
parents:
diff changeset
202 #define FLAG_SET_DEFAULT(name, value) ((name) = (value))
a61af66fc99e Initial load
duke
parents:
diff changeset
203
a61af66fc99e Initial load
duke
parents:
diff changeset
204 #define FLAG_SET_CMDLINE(type, name, value) (CommandLineFlagsEx::type##AtPut(FLAG_MEMBER_WITH_TYPE(name,type), (type)(value), COMMAND_LINE))
a61af66fc99e Initial load
duke
parents:
diff changeset
205 #define FLAG_SET_ERGO(type, name, value) (CommandLineFlagsEx::type##AtPut(FLAG_MEMBER_WITH_TYPE(name,type), (type)(value), ERGONOMIC))
a61af66fc99e Initial load
duke
parents:
diff changeset
206
a61af66fc99e Initial load
duke
parents:
diff changeset
207 // Can't put the following in CommandLineFlags because
a61af66fc99e Initial load
duke
parents:
diff changeset
208 // of a circular dependency on the enum definition.
a61af66fc99e Initial load
duke
parents:
diff changeset
209 class CommandLineFlagsEx : CommandLineFlags {
a61af66fc99e Initial load
duke
parents:
diff changeset
210 public:
a61af66fc99e Initial load
duke
parents:
diff changeset
211 static void boolAtPut(CommandLineFlagWithType flag, bool value, FlagValueOrigin origin);
a61af66fc99e Initial load
duke
parents:
diff changeset
212 static void intxAtPut(CommandLineFlagWithType flag, intx value, FlagValueOrigin origin);
a61af66fc99e Initial load
duke
parents:
diff changeset
213 static void uintxAtPut(CommandLineFlagWithType flag, uintx value, FlagValueOrigin origin);
1064
473cce303f13 6887571: Increase default heap config sizes
phh
parents: 356
diff changeset
214 static void uint64_tAtPut(CommandLineFlagWithType flag, uint64_t value, FlagValueOrigin origin);
0
a61af66fc99e Initial load
duke
parents:
diff changeset
215 static void doubleAtPut(CommandLineFlagWithType flag, double value, FlagValueOrigin origin);
a61af66fc99e Initial load
duke
parents:
diff changeset
216 static void ccstrAtPut(CommandLineFlagWithType flag, ccstr value, FlagValueOrigin origin);
a61af66fc99e Initial load
duke
parents:
diff changeset
217
a61af66fc99e Initial load
duke
parents:
diff changeset
218 static bool is_default(CommandLineFlag flag);
13
183f41cf8bfe 6557851: CMS: ergonomics defaults are not set with FLAG_SET_ERGO
jmasa
parents: 0
diff changeset
219 static bool is_ergo(CommandLineFlag flag);
183f41cf8bfe 6557851: CMS: ergonomics defaults are not set with FLAG_SET_ERGO
jmasa
parents: 0
diff changeset
220 static bool is_cmdline(CommandLineFlag flag);
0
a61af66fc99e Initial load
duke
parents:
diff changeset
221 };
1972
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1552
diff changeset
222
f95d63e2154a 6989984: Use standard include model for Hospot
stefank
parents: 1552
diff changeset
223 #endif // SHARE_VM_RUNTIME_GLOBALS_EXTENSION_HPP