提交 99ed4f0c 编写于 作者: I ihse

8217404: --with-jvm-features doesn't work when multiple features are explicitly disabled

Reviewed-by: vlivanov, kbarrett
上级 e5012627
......@@ -47,8 +47,8 @@ AC_DEFUN([HOTSPOT_CHECK_JVM_VARIANT],
[ [ [[ " $JVM_VARIANTS " =~ " $1 " ]] ] ])
###############################################################################
# Check if the specified JVM features are explicitly enabled. To be used in
# shell if constructs, like this:
# Check if the specified JVM feature is enabled. To be used in shell if
# constructs, like this:
# if HOTSPOT_CHECK_JVM_FEATURE(jvmti); then
#
# Only valid to use after HOTSPOT_SETUP_JVM_FEATURES has setup features.
......@@ -58,6 +58,20 @@ AC_DEFUN([HOTSPOT_CHECK_JVM_VARIANT],
AC_DEFUN([HOTSPOT_CHECK_JVM_FEATURE],
[ [ [[ " $JVM_FEATURES " =~ " $1 " ]] ] ])
###############################################################################
# Check if the specified JVM feature is explicitly disabled. To be used in
# shell if constructs, like this:
# if HOTSPOT_IS_JVM_FEATURE_DISABLED(jvmci); then
#
# This function is internal to hotspot.m4, and is only used when constructing
# the valid set of enabled JVM features. Users outside of hotspot.m4 should just
# use HOTSPOT_CHECK_JVM_FEATURE to check if a feature is enabled or not.
# Definition kept in one line to allow inlining in if statements.
# Additional [] needed to keep m4 from mangling shell constructs.
AC_DEFUN([HOTSPOT_IS_JVM_FEATURE_DISABLED],
[ [ [[ " $DISABLED_JVM_FEATURES " =~ " $1 " ]] ] ])
###############################################################################
# Check which variants of the JVM that we want to build. Available variants are:
# server: normal interpreter, and a tiered C1/C2 compiler
......@@ -377,8 +391,7 @@ AC_DEFUN_ONCE([HOTSPOT_SETUP_JVM_FEATURES],
AC_MSG_CHECKING([if jvmci module jdk.internal.vm.ci should be built])
# Check if jvmci is diabled
DISABLE_JVMCI=`$ECHO $DISABLED_JVM_FEATURES | $GREP jvmci`
if test "x$DISABLE_JVMCI" = "xjvmci"; then
if HOTSPOT_IS_JVM_FEATURE_DISABLED(jvmci); then
AC_MSG_RESULT([no, forced])
JVM_FEATURES_jvmci=""
INCLUDE_JVMCI="false"
......@@ -404,8 +417,7 @@ AC_DEFUN_ONCE([HOTSPOT_SETUP_JVM_FEATURES],
AC_MSG_CHECKING([if graal module jdk.internal.vm.compiler should be built])
# Check if graal is diabled
DISABLE_GRAAL=`$ECHO $DISABLED_JVM_FEATURES | $GREP graal`
if test "x$DISABLE_GRAAL" = "xgraal"; then
if HOTSPOT_IS_JVM_FEATURE_DISABLED(graal); then
AC_MSG_RESULT([no, forced])
JVM_FEATURES_graal=""
INCLUDE_GRAAL="false"
......@@ -437,8 +449,7 @@ AC_DEFUN_ONCE([HOTSPOT_SETUP_JVM_FEATURES],
AC_SUBST(INCLUDE_GRAAL)
# Disable aot with '--with-jvm-features=-aot'
DISABLE_AOT=`$ECHO $DISABLED_JVM_FEATURES | $GREP aot`
if test "x$DISABLE_AOT" = "xaot"; then
if HOTSPOT_IS_JVM_FEATURE_DISABLED(aot); then
ENABLE_AOT="false"
fi
......@@ -462,7 +473,7 @@ AC_DEFUN_ONCE([HOTSPOT_SETUP_JVM_FEATURES],
JVM_FEATURES_aot="aot"
fi
else
if test "x$enable_aot" = "xno" || test "x$DISABLE_AOT" = "xaot"; then
if test "x$enable_aot" = "xno" || HOTSPOT_IS_JVM_FEATURE_DISABLED(aot); then
AC_MSG_RESULT([no, forced])
else
AC_MSG_RESULT([no])
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册