25 |
25 |
26 # All valid JVM features, regardless of platform |
26 # All valid JVM features, regardless of platform |
27 VALID_JVM_FEATURES="compiler1 compiler2 zero minimal dtrace jvmti jvmci \ |
27 VALID_JVM_FEATURES="compiler1 compiler2 zero minimal dtrace jvmti jvmci \ |
28 graal vm-structs jni-check services management cmsgc g1gc parallelgc serialgc epsilongc nmt cds \ |
28 graal vm-structs jni-check services management cmsgc g1gc parallelgc serialgc epsilongc nmt cds \ |
29 static-build link-time-opt aot jfr" |
29 static-build link-time-opt aot jfr" |
|
30 |
|
31 # Deprecated JVM features (these are ignored, but with a warning) |
|
32 DEPRECATED_JVM_FEATURES="trace" |
30 |
33 |
31 # All valid JVM variants |
34 # All valid JVM variants |
32 VALID_JVM_VARIANTS="server client minimal core zero custom" |
35 VALID_JVM_VARIANTS="server client minimal core zero custom" |
33 |
36 |
34 ############################################################################### |
37 ############################################################################### |
267 if test "x$with_jvm_features" != x; then |
270 if test "x$with_jvm_features" != x; then |
268 AC_MSG_CHECKING([user specified JVM feature list]) |
271 AC_MSG_CHECKING([user specified JVM feature list]) |
269 USER_JVM_FEATURE_LIST=`$ECHO $with_jvm_features | $SED -e 's/,/ /g'` |
272 USER_JVM_FEATURE_LIST=`$ECHO $with_jvm_features | $SED -e 's/,/ /g'` |
270 AC_MSG_RESULT([$user_jvm_feature_list]) |
273 AC_MSG_RESULT([$user_jvm_feature_list]) |
271 # These features will be added to all variant defaults |
274 # These features will be added to all variant defaults |
272 JVM_FEATURES=`$ECHO $USER_JVM_FEATURE_LIST | $AWK '{ for (i=1; i<=NF; i++) if (!match($i, /^-.*/)) print $i }'` |
275 JVM_FEATURES=`$ECHO $USER_JVM_FEATURE_LIST | $AWK '{ for (i=1; i<=NF; i++) if (!match($i, /^-.*/)) printf("%s ", $i) }'` |
273 # These features will be removed from all variant defaults |
276 # These features will be removed from all variant defaults |
274 DISABLED_JVM_FEATURES=`$ECHO $USER_JVM_FEATURE_LIST | $AWK '{ for (i=1; i<=NF; i++) if (match($i, /^-.*/)) print substr($i, 2) }'` |
277 DISABLED_JVM_FEATURES=`$ECHO $USER_JVM_FEATURE_LIST | $AWK '{ for (i=1; i<=NF; i++) if (match($i, /^-.*/)) printf("%s ", substr($i, 2))}'` |
275 |
278 |
276 # Verify that the user has provided valid features |
279 # Verify that the user has provided valid features |
277 BASIC_GET_NON_MATCHING_VALUES(INVALID_FEATURES, $JVM_FEATURES $DISABLED_JVM_FEATURES, $VALID_JVM_FEATURES) |
280 BASIC_GET_NON_MATCHING_VALUES(INVALID_FEATURES, $JVM_FEATURES $DISABLED_JVM_FEATURES, $VALID_JVM_FEATURES $DEPRECATED_JVM_FEATURES) |
278 if test "x$INVALID_FEATURES" != x; then |
281 if test "x$INVALID_FEATURES" != x; then |
279 AC_MSG_NOTICE([Unknown JVM features specified: "$INVALID_FEATURES"]) |
282 AC_MSG_NOTICE([Unknown JVM features specified: "$INVALID_FEATURES"]) |
280 AC_MSG_NOTICE([The available JVM features are: "$VALID_JVM_FEATURES"]) |
283 AC_MSG_NOTICE([The available JVM features are: "$VALID_JVM_FEATURES"]) |
281 AC_MSG_ERROR([Cannot continue]) |
284 AC_MSG_ERROR([Cannot continue]) |
|
285 fi |
|
286 |
|
287 # Check if the user has provided deprecated features |
|
288 BASIC_GET_MATCHING_VALUES(DEPRECATED_FEATURES, $JVM_FEATURES $DISABLED_JVM_FEATURES, $DEPRECATED_JVM_FEATURES) |
|
289 if test "x$DEPRECATED_FEATURES" != x; then |
|
290 AC_MSG_WARN([Deprecated JVM features specified (will be ignored): "$DEPRECATED_FEATURES"]) |
|
291 # Filter out deprecated features |
|
292 BASIC_GET_NON_MATCHING_VALUES(JVM_FEATURES, $JVM_FEATURES, $DEPRECATED_FEATURES) |
|
293 BASIC_GET_NON_MATCHING_VALUES(DISABLED_JVM_FEATURES, $DISABLED_JVM_FEATURES, $DEPRECATED_FEATURES) |
282 fi |
294 fi |
283 |
295 |
284 fi |
296 fi |
285 |
297 |
286 # Override hotspot cpu definitions for ARM platforms |
298 # Override hotspot cpu definitions for ARM platforms |
307 |
319 |
308 if HOTSPOT_CHECK_JVM_FEATURE(cmsgc) && ! HOTSPOT_CHECK_JVM_FEATURE(serialgc); then |
320 if HOTSPOT_CHECK_JVM_FEATURE(cmsgc) && ! HOTSPOT_CHECK_JVM_FEATURE(serialgc); then |
309 AC_MSG_ERROR([Specified JVM feature 'cmsgc' requires feature 'serialgc']) |
321 AC_MSG_ERROR([Specified JVM feature 'cmsgc' requires feature 'serialgc']) |
310 fi |
322 fi |
311 |
323 |
312 # Enable JFR by default, except on linux-sparcv9 and on minimal. |
324 # Enable JFR by default, except for Zero, linux-sparcv9 and on minimal. |
313 if test "x$OPENJDK_TARGET_OS" != xlinux || test "x$OPENJDK_TARGET_CPU" != xsparcv9; then |
325 if ! HOTSPOT_CHECK_JVM_VARIANT(zero); then |
314 NON_MINIMAL_FEATURES="$NON_MINIMAL_FEATURES jfr" |
326 if test "x$OPENJDK_TARGET_OS" != xlinux || test "x$OPENJDK_TARGET_CPU" != xsparcv9; then |
|
327 NON_MINIMAL_FEATURES="$NON_MINIMAL_FEATURES jfr" |
|
328 fi |
315 fi |
329 fi |
316 |
330 |
317 # Turn on additional features based on other parts of configure |
331 # Turn on additional features based on other parts of configure |
318 if test "x$INCLUDE_DTRACE" = "xtrue"; then |
332 if test "x$INCLUDE_DTRACE" = "xtrue"; then |
319 JVM_FEATURES="$JVM_FEATURES dtrace" |
333 JVM_FEATURES="$JVM_FEATURES dtrace" |