This commit is contained in:
Igor Ignatyev 2017-08-02 15:59:32 +00:00
commit d8e0821f0b
657 changed files with 14655 additions and 8283 deletions

View File

@ -1,3 +1,8 @@
e2b70be325bd10dae4c06f74c46d70d480854916 jdk-9+179
5b16a1c3ccffff2a82c88bb7ea894c4ff1c9ebde jdk-9+180
43bf6f30fcba031ecf0cc7e511efe3a8179d0f77 jdk-9+176
d9f6bc6ba599d0487dc18b2fbdb6c34eedf6f958 jdk-9+177
bc9df7dd63ec76f50fafeb4acc44465044662f0a jdk-9+178
994036e74ab805bcc09afa0646be17a725bec42f jdk-9+175
94680c6d60ecd9ed3ffd1847706efde7eb947afc jdk-9+174
6dd7fda42bab7ecf648cafb0a4e9b4ca11b3094f jdk-9+173
@ -432,3 +437,7 @@ b0f2b8ff25a2209b2c807785d75f20e5086bbfc2 jdk-10+10
036dbf8b381798e5d31065109714d04d97bf98a4 jdk-10+11
e6d70017f5b9adbb2ec82d826973d0251800a3c3 jdk-10+12
9927a9f16738e240ab7014f0118f41e314ef8f99 jdk-10+13
9ef5029b247b4d940080417a287440bbdbab995b jdk-10+14
878e216039322cb3f0ecbd0944642a2b4e2593f3 jdk-10+15
4bbea012e5676e8025ade2bcfab4d6581e6e9f4b jdk-10+16
7db699468b4f84abbcc01647e5a964409737411a jdk-10+17

View File

@ -432,3 +432,11 @@ b94be69cbb1d2943b886bf2d458745756df146e4 jdk-10+9
8d4ed1e06fe184c9cb08c5b708e7d6f5c066644f jdk-10+12
8f7227c6012b0051ea4e0bcee040c627bf699b88 jdk-9+175
d67a3f1f057f7e31e12f33ebe3667cb73d252268 jdk-10+13
1fd5901544acc50bb30fde9388c8e53cb7c449e4 jdk-10+14
84777531d994ef70163d35078ec9c4127f2eadb5 jdk-9+176
a4371edb589c60db01142e45c317adb9ccbcb083 jdk-9+177
a6c830ee8a6798b186730475e700027cdf4598aa jdk-10+15
2fe66ca1e2b3c361f949de9cb2894661dc0a3fa2 jdk-10+16
ec4159ebe7050fcc5dcee8a2d150cf948ecc97db jdk-9+178
252475ccfd84cc249f8d6faf4b7806b5e2c384ce jdk-9+179
a133a7d1007b1456bc62824382fd8ac93b45d329 jdk-10+17

View File

@ -1024,14 +1024,18 @@ AC_DEFUN([FLAGS_SETUP_COMPILER_FLAGS_FOR_JDK_HELPER],
$2JVM_CFLAGS="[$]$2JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE"
$2JVM_CFLAGS="[$]$2JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \
-mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \
-DMAC_OS_X_VERSION_MAX_ALLOWED=1070 -mmacosx-version-min=10.7.0 \
-fno-omit-frame-pointer"
elif test "x$OPENJDK_$1_OS" = xaix; then
$2JVM_CFLAGS="[$]$2JVM_CFLAGS -DAIX"
# We may need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows.
$2JVM_CFLAGS="[$]$2JVM_CFLAGS -qtune=balanced \
-qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \
-qlanglvl=noredefmac -qnortti -qnoeh -qignerrno"
# We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows.
# Hotspot now overflows its 64K TOC (currently only for slowdebug),
# so for slowdebug we build with '-qpic=large -bbigtoc'.
if test "x$DEBUG_LEVEL" = xslowdebug; then
$2JVM_CFLAGS="[$]$2JVM_CFLAGS -qpic=large"
fi
elif test "x$OPENJDK_$1_OS" = xbsd; then
$2COMMON_CCXXFLAGS_JDK="[$]$2COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE"
elif test "x$OPENJDK_$1_OS" = xwindows; then
@ -1109,18 +1113,50 @@ AC_DEFUN([FLAGS_SETUP_COMPILER_FLAGS_FOR_JDK_HELPER],
# Additional macosx handling
if test "x$OPENJDK_$1_OS" = xmacosx; then
# Setting these parameters makes it an error to link to macosx APIs that are
# newer than the given OS version and makes the linked binaries compatible
# even if built on a newer version of the OS.
# The expected format is X.Y.Z
# MACOSX_VERSION_MIN is the c++ and ld is -mmacosx-version-min argument. The expected
# format is X.Y.Z. It's hard-coded to the minimum OSX version on which the
# JDK can be built and makes the linked binaries compatible even if built on
# a newer version of the OS.
MACOSX_VERSION_MIN=10.7.0
AC_SUBST(MACOSX_VERSION_MIN)
# The macro takes the version with no dots, ex: 1070
# Setting --with-macosx-version-max=<version> makes it an error to build or
# link to macosx APIs that are newer than the given OS version. The expected
# format for <version> is either nn.n.n or nn.nn.nn. See /usr/include/AvailabilityMacros.h.
AC_ARG_WITH([macosx-version-max], [AS_HELP_STRING([--with-macosx-version-max],
[error on use of newer functionality. @<:@macosx@:>@])],
[
if echo "$with_macosx_version_max" | $GREP -q "^[[0-9]][[0-9]]\.[[0-9]]\.[[0-9]]\$"; then
MACOSX_VERSION_MAX=$with_macosx_version_max
elif echo "$with_macosx_version_max" | $GREP -q "^[[0-9]][[0-9]]\.[[0-9]][[0-9]]\.[[0-9]][[0-9]]\$"; then
MACOSX_VERSION_MAX=$with_macosx_version_max
elif test "x$with_macosx_version_max" = "xno"; then
# Use build system default
MACOSX_VERSION_MAX=
else
AC_MSG_ERROR([osx version format must be nn.n.n or nn.nn.nn])
fi
],
[MACOSX_VERSION_MAX=]
)
AC_SUBST(MACOSX_VERSION_MAX)
# Let the flags variables get resolved in make for easier override on make
# command line.
$2COMMON_CCXXFLAGS_JDK="[$]$2COMMON_CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
# command line. AvailabilityMacros.h versions have no dots, ex: 1070.
$2COMMON_CCXXFLAGS_JDK="[$]$2COMMON_CCXXFLAGS_JDK \
-DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \
-mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
$2LDFLAGS_JDK="[$]$2LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
$2JVM_CFLAGS="[$]$2JVM_CFLAGS \
-DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \
-mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
if test -n "$MACOSX_VERSION_MAX"; then
$2COMMON_CCXXFLAGS_JDK="[$]$2COMMON_CCXXFLAGS_JDK \
-DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))"
$2JVM_CFLAGS="[$]$2JVM_CFLAGS \
-DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))"
fi
fi
# Setup some hard coded includes
@ -1246,6 +1282,12 @@ AC_DEFUN([FLAGS_SETUP_COMPILER_FLAGS_FOR_JDK_HELPER],
LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok"
$2LDFLAGS_JDK="${$2LDFLAGS_JDK} $LDFLAGS_XLC"
$2JVM_LDFLAGS="[$]$2JVM_LDFLAGS $LDFLAGS_XLC"
# We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows.
# Hotspot now overflows its 64K TOC (currently only for slowdebug),
# so for slowdebug we build with '-qpic=large -bbigtoc'.
if test "x$DEBUG_LEVEL" = xslowdebug; then
$2JVM_LDFLAGS="[$]$2JVM_LDFLAGS -bbigtoc"
fi
fi
# Customize LDFLAGS for executables

View File

@ -747,6 +747,7 @@ CXXFLAGS_JDKEXE
CXXFLAGS_JDKLIB
CFLAGS_JDKEXE
CFLAGS_JDKLIB
MACOSX_VERSION_MAX
MACOSX_VERSION_MIN
CXXSTD_CXXFLAG
JDK_ARCH_ABI_PROP_NAME
@ -1182,6 +1183,7 @@ with_build_devkit
with_jtreg
with_jib
with_abi_profile
with_macosx_version_max
enable_warnings_as_errors
with_native_debug_symbols
enable_debug_symbols
@ -2128,6 +2130,8 @@ Optional Packages:
(arm-vfp-sflt,arm-vfp-hflt,arm-sflt,
armv5-vfp-sflt,armv6-vfp-hflt,arm64,aarch64)
[toolchain dependent]
--with-macosx-version-max
error on use of newer functionality. [macosx]
--with-native-debug-symbols
set the native debug symbol configuration (none,
internal, external, zipped) [varying]
@ -4969,7 +4973,7 @@ TOOLCHAIN_DESCRIPTION_xlc="IBM XL C/C++"
# Minimum supported versions, empty means unspecified
TOOLCHAIN_MINIMUM_VERSION_clang="3.2"
TOOLCHAIN_MINIMUM_VERSION_gcc="4.3"
TOOLCHAIN_MINIMUM_VERSION_gcc="4.7"
TOOLCHAIN_MINIMUM_VERSION_microsoft="16.00.30319.01" # VS2010
TOOLCHAIN_MINIMUM_VERSION_solstudio="5.13"
TOOLCHAIN_MINIMUM_VERSION_xlc=""
@ -5151,7 +5155,7 @@ VS_SDK_PLATFORM_NAME_2013=
#CUSTOM_AUTOCONF_INCLUDE
# Do not change or remove the following line, it is needed for consistency checks:
DATE_WHEN_GENERATED=1498593591
DATE_WHEN_GENERATED=1501617733
###############################################################################
#
@ -51541,14 +51545,18 @@ $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLA
JVM_CFLAGS="$JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE"
JVM_CFLAGS="$JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \
-mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \
-DMAC_OS_X_VERSION_MAX_ALLOWED=1070 -mmacosx-version-min=10.7.0 \
-fno-omit-frame-pointer"
elif test "x$OPENJDK_TARGET_OS" = xaix; then
JVM_CFLAGS="$JVM_CFLAGS -DAIX"
# We may need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows.
JVM_CFLAGS="$JVM_CFLAGS -qtune=balanced \
-qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \
-qlanglvl=noredefmac -qnortti -qnoeh -qignerrno"
# We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows.
# Hotspot now overflows its 64K TOC (currently only for slowdebug),
# so for slowdebug we build with '-qpic=large -bbigtoc'.
if test "x$DEBUG_LEVEL" = xslowdebug; then
JVM_CFLAGS="$JVM_CFLAGS -qpic=large"
fi
elif test "x$OPENJDK_TARGET_OS" = xbsd; then
COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE"
elif test "x$OPENJDK_TARGET_OS" = xwindows; then
@ -51715,18 +51723,54 @@ $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLA
# Additional macosx handling
if test "x$OPENJDK_TARGET_OS" = xmacosx; then
# Setting these parameters makes it an error to link to macosx APIs that are
# newer than the given OS version and makes the linked binaries compatible
# even if built on a newer version of the OS.
# The expected format is X.Y.Z
# MACOSX_VERSION_MIN is the c++ and ld is -mmacosx-version-min argument. The expected
# format is X.Y.Z. It's hard-coded to the minimum OSX version on which the
# JDK can be built and makes the linked binaries compatible even if built on
# a newer version of the OS.
MACOSX_VERSION_MIN=10.7.0
# The macro takes the version with no dots, ex: 1070
# Setting --with-macosx-version-max=<version> makes it an error to build or
# link to macosx APIs that are newer than the given OS version. The expected
# format for <version> is either nn.n.n or nn.nn.nn. See /usr/include/AvailabilityMacros.h.
# Check whether --with-macosx-version-max was given.
if test "${with_macosx_version_max+set}" = set; then :
withval=$with_macosx_version_max;
if echo "$with_macosx_version_max" | $GREP -q "^[0-9][0-9]\.[0-9]\.[0-9]\$"; then
MACOSX_VERSION_MAX=$with_macosx_version_max
elif echo "$with_macosx_version_max" | $GREP -q "^[0-9][0-9]\.[0-9][0-9]\.[0-9][0-9]\$"; then
MACOSX_VERSION_MAX=$with_macosx_version_max
elif test "x$with_macosx_version_max" = "xno"; then
# Use build system default
MACOSX_VERSION_MAX=
else
as_fn_error $? "osx version format must be nn.n.n or nn.nn.nn" "$LINENO" 5
fi
else
MACOSX_VERSION_MAX=
fi
# Let the flags variables get resolved in make for easier override on make
# command line.
COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
# command line. AvailabilityMacros.h versions have no dots, ex: 1070.
COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \
-DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \
-mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
JVM_CFLAGS="$JVM_CFLAGS \
-DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \
-mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
if test -n "$MACOSX_VERSION_MAX"; then
COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \
-DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))"
JVM_CFLAGS="$JVM_CFLAGS \
-DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))"
fi
fi
# Setup some hard coded includes
@ -51852,6 +51896,12 @@ $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLA
LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok"
LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_XLC"
JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_XLC"
# We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows.
# Hotspot now overflows its 64K TOC (currently only for slowdebug),
# so for slowdebug we build with '-qpic=large -bbigtoc'.
if test "x$DEBUG_LEVEL" = xslowdebug; then
JVM_LDFLAGS="$JVM_LDFLAGS -bbigtoc"
fi
fi
# Customize LDFLAGS for executables
@ -52374,14 +52424,18 @@ $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLA
OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE"
OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \
-mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \
-DMAC_OS_X_VERSION_MAX_ALLOWED=1070 -mmacosx-version-min=10.7.0 \
-fno-omit-frame-pointer"
elif test "x$OPENJDK_BUILD_OS" = xaix; then
OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DAIX"
# We may need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows.
OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qtune=balanced \
-qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \
-qlanglvl=noredefmac -qnortti -qnoeh -qignerrno"
# We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows.
# Hotspot now overflows its 64K TOC (currently only for slowdebug),
# so for slowdebug we build with '-qpic=large -bbigtoc'.
if test "x$DEBUG_LEVEL" = xslowdebug; then
OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qpic=large"
fi
elif test "x$OPENJDK_BUILD_OS" = xbsd; then
OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE"
elif test "x$OPENJDK_BUILD_OS" = xwindows; then
@ -52548,18 +52602,54 @@ $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLA
# Additional macosx handling
if test "x$OPENJDK_BUILD_OS" = xmacosx; then
# Setting these parameters makes it an error to link to macosx APIs that are
# newer than the given OS version and makes the linked binaries compatible
# even if built on a newer version of the OS.
# The expected format is X.Y.Z
# MACOSX_VERSION_MIN is the c++ and ld is -mmacosx-version-min argument. The expected
# format is X.Y.Z. It's hard-coded to the minimum OSX version on which the
# JDK can be built and makes the linked binaries compatible even if built on
# a newer version of the OS.
MACOSX_VERSION_MIN=10.7.0
# The macro takes the version with no dots, ex: 1070
# Setting --with-macosx-version-max=<version> makes it an error to build or
# link to macosx APIs that are newer than the given OS version. The expected
# format for <version> is either nn.n.n or nn.nn.nn. See /usr/include/AvailabilityMacros.h.
# Check whether --with-macosx-version-max was given.
if test "${with_macosx_version_max+set}" = set; then :
withval=$with_macosx_version_max;
if echo "$with_macosx_version_max" | $GREP -q "^[0-9][0-9]\.[0-9]\.[0-9]\$"; then
MACOSX_VERSION_MAX=$with_macosx_version_max
elif echo "$with_macosx_version_max" | $GREP -q "^[0-9][0-9]\.[0-9][0-9]\.[0-9][0-9]\$"; then
MACOSX_VERSION_MAX=$with_macosx_version_max
elif test "x$with_macosx_version_max" = "xno"; then
# Use build system default
MACOSX_VERSION_MAX=
else
as_fn_error $? "osx version format must be nn.n.n or nn.nn.nn" "$LINENO" 5
fi
else
MACOSX_VERSION_MAX=
fi
# Let the flags variables get resolved in make for easier override on make
# command line.
OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
# command line. AvailabilityMacros.h versions have no dots, ex: 1070.
OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \
-DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \
-mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS \
-DMAC_OS_X_VERSION_MIN_REQUIRED=\$(subst .,,\$(MACOSX_VERSION_MIN)) \
-mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
if test -n "$MACOSX_VERSION_MAX"; then
OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \
-DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))"
OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS \
-DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MAX))"
fi
fi
# Setup some hard coded includes
@ -52685,6 +52775,12 @@ $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLA
LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok"
OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_XLC"
OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_XLC"
# We need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows.
# Hotspot now overflows its 64K TOC (currently only for slowdebug),
# so for slowdebug we build with '-qpic=large -bbigtoc'.
if test "x$DEBUG_LEVEL" = xslowdebug; then
OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -bbigtoc"
fi
fi
# Customize LDFLAGS for executables

View File

@ -335,8 +335,10 @@ GCOV_ENABLED=@GCOV_ENABLED@
X_CFLAGS:=@X_CFLAGS@
X_LIBS:=@X_LIBS@
# The lowest required version of macosx to enforce compatiblity for
# The lowest required version of macosx
MACOSX_VERSION_MIN=@MACOSX_VERSION_MIN@
# The highest allowed version of macosx
MACOSX_VERSION_MAX=@MACOSX_VERSION_MAX@
# Toolchain type: gcc, clang, solstudio, lxc, microsoft...
TOOLCHAIN_TYPE:=@TOOLCHAIN_TYPE@

View File

@ -52,7 +52,7 @@ TOOLCHAIN_DESCRIPTION_xlc="IBM XL C/C++"
# Minimum supported versions, empty means unspecified
TOOLCHAIN_MINIMUM_VERSION_clang="3.2"
TOOLCHAIN_MINIMUM_VERSION_gcc="4.3"
TOOLCHAIN_MINIMUM_VERSION_gcc="4.7"
TOOLCHAIN_MINIMUM_VERSION_microsoft="16.00.30319.01" # VS2010
TOOLCHAIN_MINIMUM_VERSION_solstudio="5.13"
TOOLCHAIN_MINIMUM_VERSION_xlc=""

View File

@ -436,7 +436,8 @@ var getJibProfilesProfiles = function (input, common, data) {
target_os: "macosx",
target_cpu: "x64",
dependencies: ["devkit"],
configure_args: concat(common.configure_args_64bit, "--with-zlib=system"),
configure_args: concat(common.configure_args_64bit, "--with-zlib=system",
"--with-macosx-version-max=10.7.0"),
},
"solaris-x64": {
@ -615,6 +616,8 @@ var getJibProfilesProfiles = function (input, common, data) {
}
var testOnlyProfilesPrebuilt = {
"run-test-prebuilt": {
target_os: input.build_os,
target_cpu: input.build_cpu,
src: "src.conf",
dependencies: [ "jtreg", "gnumake", "boot_jdk", "jib", testedProfile + ".jdk",
testedProfile + ".test", "src.full"
@ -635,13 +638,14 @@ var getJibProfilesProfiles = function (input, common, data) {
if (input.profile == "run-test-prebuilt") {
if (profiles[testedProfile] == null) {
error("testedProfile is not defined: " + testedProfile);
} else {
testOnlyProfilesPrebuilt["run-test-prebuilt"]["target_os"]
= profiles[testedProfile]["target_os"];
testOnlyProfilesPrebuilt["run-test-prebuilt"]["target_cpu"]
= profiles[testedProfile]["target_cpu"];
}
}
if (profiles[testedProfile] != null) {
testOnlyProfilesPrebuilt["run-test-prebuilt"]["target_os"]
= profiles[testedProfile]["target_os"];
testOnlyProfilesPrebuilt["run-test-prebuilt"]["target_cpu"]
= profiles[testedProfile]["target_cpu"];
}
profiles = concatObjects(profiles, testOnlyProfilesPrebuilt);
// On macosx add the devkit bin dir to the path in all the run-test profiles.

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -6,7 +6,7 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes">
<title>Testing OpenJDK</title>
<style type="text/css">code{white-space: pre;}</style>
<link rel="stylesheet" href="../../jdk/make/data/docs-resources/specs/resources/jdk-default.css">
<link rel="stylesheet" href="../../jdk/make/data/docs-resources/resources/jdk-default.css">
<!--[if lt IE 9]>
<script src="//cdnjs.cloudflare.com/ajax/libs/html5shiv/3.7.3/html5shiv-printshiv.min.js"></script>
<![endif]-->

View File

@ -3517,7 +3517,6 @@
<Elem>COMPILER2</Elem>
<Elem>DTRACE_ENABLED</Elem>
<Elem>HOTSPOT_LIB_ARCH="amd64"</Elem>
<Elem>MAC_OS_X_VERSION_MAX_ALLOWED=1070</Elem>
<Elem>TARGET_ARCH_MODEL_x86_64</Elem>
<Elem>TARGET_ARCH_x86</Elem>
<Elem>TARGET_COMPILER_gcc</Elem>
@ -10570,7 +10569,6 @@
<Elem>COMPILER2</Elem>
<Elem>DTRACE_ENABLED</Elem>
<Elem>HOTSPOT_LIB_ARCH="amd64"</Elem>
<Elem>MAC_OS_X_VERSION_MAX_ALLOWED=1070</Elem>
<Elem>TARGET_ARCH_MODEL_x86_64</Elem>
<Elem>TARGET_ARCH_x86</Elem>
<Elem>TARGET_COMPILER_gcc</Elem>
@ -18227,7 +18225,6 @@
<Elem>COMPILER2</Elem>
<Elem>DTRACE_ENABLED</Elem>
<Elem>HOTSPOT_LIB_ARCH="amd64"</Elem>
<Elem>MAC_OS_X_VERSION_MAX_ALLOWED=1070</Elem>
<Elem>TARGET_ARCH_MODEL_x86_64</Elem>
<Elem>TARGET_ARCH_x86</Elem>
<Elem>TARGET_COMPILER_gcc</Elem>
@ -20787,7 +20784,6 @@
<Elem>COMPILER2</Elem>
<Elem>DTRACE_ENABLED</Elem>
<Elem>HOTSPOT_LIB_ARCH="amd64"</Elem>
<Elem>MAC_OS_X_VERSION_MAX_ALLOWED=1070</Elem>
<Elem>TARGET_ARCH_MODEL_x86_64</Elem>
<Elem>TARGET_ARCH_x86</Elem>
<Elem>TARGET_COMPILER_gcc</Elem>
@ -21531,7 +21527,6 @@
<Elem>ARCHPROPNAME="x86_64"</Elem>
<Elem>DEBUG</Elem>
<Elem>MACOSX</Elem>
<Elem>MAC_OS_X_VERSION_MAX_ALLOWED=1070</Elem>
<Elem>THIS_FILE="java_props_macosx.c"</Elem>
<Elem>_ALLBSD_SOURCE</Elem>
<Elem>_DARWIN_UNLIMITED_SELECT</Elem>
@ -23025,7 +23020,6 @@
<Elem>ARCHPROPNAME="x86_64"</Elem>
<Elem>DEBUG</Elem>
<Elem>MACOSX</Elem>
<Elem>MAC_OS_X_VERSION_MAX_ALLOWED=1070</Elem>
<Elem>THIS_FILE="java_props_md.c"</Elem>
<Elem>_ALLBSD_SOURCE</Elem>
<Elem>_DARWIN_UNLIMITED_SELECT</Elem>
@ -23104,7 +23098,6 @@
<Elem>ARCH="x86_64"</Elem>
<Elem>DEBUG</Elem>
<Elem>MACOSX</Elem>
<Elem>MAC_OS_X_VERSION_MAX_ALLOWED=1070</Elem>
<Elem>THIS_FILE="ExtendedOptionsImpl.c"</Elem>
<Elem>_ALLBSD_SOURCE</Elem>
<Elem>_DARWIN_UNLIMITED_SELECT</Elem>
@ -23481,7 +23474,6 @@
<Elem>ARCH="x86_64"</Elem>
<Elem>DEBUG</Elem>
<Elem>MACOSX</Elem>
<Elem>MAC_OS_X_VERSION_MAX_ALLOWED=1070</Elem>
<Elem>THIS_FILE="SocketDispatcher.c"</Elem>
<Elem>_ALLBSD_SOURCE</Elem>
<Elem>_DARWIN_UNLIMITED_SELECT</Elem>
@ -29987,7 +29979,6 @@
<Elem>COMPILER2</Elem>
<Elem>DTRACE_ENABLED</Elem>
<Elem>HOTSPOT_LIB_ARCH="amd64"</Elem>
<Elem>MAC_OS_X_VERSION_MAX_ALLOWED=1070</Elem>
<Elem>TARGET_ARCH_MODEL_x86_64</Elem>
<Elem>TARGET_ARCH_x86</Elem>
<Elem>TARGET_COMPILER_gcc</Elem>
@ -30069,7 +30060,6 @@
<Elem>COMPILER2</Elem>
<Elem>DTRACE_ENABLED</Elem>
<Elem>HOTSPOT_LIB_ARCH="amd64"</Elem>
<Elem>MAC_OS_X_VERSION_MAX_ALLOWED=1070</Elem>
<Elem>TARGET_ARCH_MODEL_x86_64</Elem>
<Elem>TARGET_ARCH_x86</Elem>
<Elem>TARGET_COMPILER_gcc</Elem>
@ -30104,7 +30094,6 @@
<Elem>ARCH="x86_64"</Elem>
<Elem>DEBUG</Elem>
<Elem>MACOSX</Elem>
<Elem>MAC_OS_X_VERSION_MAX_ALLOWED=1070</Elem>
<Elem>_ALLBSD_SOURCE</Elem>
<Elem>_DARWIN_UNLIMITED_SELECT</Elem>
<Elem>_GNU_SOURCE</Elem>
@ -30147,7 +30136,6 @@
<Elem>COMPILER2</Elem>
<Elem>DTRACE_ENABLED</Elem>
<Elem>HOTSPOT_LIB_ARCH="amd64"</Elem>
<Elem>MAC_OS_X_VERSION_MAX_ALLOWED=1070</Elem>
<Elem>TARGET_ARCH_MODEL_x86_64</Elem>
<Elem>TARGET_ARCH_x86</Elem>
<Elem>TARGET_COMPILER_gcc</Elem>
@ -30211,7 +30199,6 @@
<Elem>COMPILER2</Elem>
<Elem>DTRACE_ENABLED</Elem>
<Elem>HOTSPOT_LIB_ARCH="amd64"</Elem>
<Elem>MAC_OS_X_VERSION_MAX_ALLOWED=1070</Elem>
<Elem>TARGET_ARCH_MODEL_x86_64</Elem>
<Elem>TARGET_ARCH_x86</Elem>
<Elem>TARGET_COMPILER_gcc</Elem>
@ -30274,7 +30261,6 @@
<Elem>COMPILER2</Elem>
<Elem>DTRACE_ENABLED</Elem>
<Elem>HOTSPOT_LIB_ARCH="amd64"</Elem>
<Elem>MAC_OS_X_VERSION_MAX_ALLOWED=1070</Elem>
<Elem>TARGET_ARCH_MODEL_x86_64</Elem>
<Elem>TARGET_ARCH_x86</Elem>
<Elem>TARGET_COMPILER_gcc</Elem>
@ -30341,7 +30327,6 @@
<preprocessorList>
<Elem>ARCH="x86_64"</Elem>
<Elem>MACOSX</Elem>
<Elem>MAC_OS_X_VERSION_MAX_ALLOWED=1070</Elem>
<Elem>THIS_FILE="agent_util.c"</Elem>
<Elem>_ALLBSD_SOURCE</Elem>
<Elem>_DARWIN_UNLIMITED_SELECT</Elem>
@ -30354,7 +30339,6 @@
<preprocessorList>
<Elem>ARCH="x86_64"</Elem>
<Elem>MACOSX</Elem>
<Elem>MAC_OS_X_VERSION_MAX_ALLOWED=1070</Elem>
<Elem>THIS_FILE="Agent.cpp"</Elem>
<Elem>_ALLBSD_SOURCE</Elem>
<Elem>_DARWIN_UNLIMITED_SELECT</Elem>

View File

@ -432,3 +432,11 @@ c62e5964cfcf144d8f72e9ba69757897785349a9 jdk-9+171
00ae6307d78bac49883ddc85d687aa88c49f3971 jdk-10+12
dc78a3dd6b3a4f11cdae8a3e3d160e6a78bc7838 jdk-9+175
564fced058bd2c8375e9104aa8f9494642cd7bdd jdk-10+13
25d991a67cba240eeaf15c19c5857b40fdd71561 jdk-10+14
40fb9f229471ef357d493813d34b15afcce9f32b jdk-9+176
c72e9d3823f04cb3ef3166646dfea9e4c2769133 jdk-9+177
15f59cfc6fbe9387423fb173e962265c7b5d357e jdk-10+15
b82b62ed5debda2d98dda597506ef29cf947fbae jdk-10+16
9c1e9712648921ae389d623042d22561fad82d75 jdk-9+178
24390da83c5ee9e23ceafbcaff4460a01e37bb3a jdk-9+179
50ff1fd66362f212a8db6de76089d9d0ffa4df0f jdk-10+17

View File

@ -26,7 +26,7 @@
/**
* Defines the Java binding of the OMG CORBA APIs, and the RMI-IIOP API.
*
* <p> This module is upgradeble.
* <p> This module is upgradeable.
*
* @moduleGraph
* @since 9

View File

@ -592,3 +592,11 @@ e64b1cb48d6e7703928a9d1da106fc27f8cb65fd jdk-9+173
070aa7a2eb14c4645f7eb31384cba0a2ba72a4b5 jdk-10+12
8f04d457168b9f1f4a1b2c37f49e0513ca9d33a7 jdk-9+175
a9da03357f190807591177fe9846d6e68ad64fc0 jdk-10+13
e920b4d008d914f3414bd4630b58837cf0b7f08d jdk-10+14
2ab74e5dbdc2b6a962c865500cafd23cf387dc60 jdk-9+176
1ca8f038fceb88c640badf9bd18905205bc63b43 jdk-9+177
c1f3649a3a42f124b418a5a916dbad13d059b757 jdk-10+15
2fe2a593e8ebf3a9e4dcd9ba3333a7b43126589d jdk-10+16
9d032191f82fca5ba0aac98682f69c4ff0f1283d jdk-9+178
d2661aa42bff322badbe6c1337fc638d2e0f5730 jdk-9+179
73e2cb8700bfa51304bd4b02f224620859a3f600 jdk-10+17

View File

@ -14394,7 +14394,7 @@ instruct compL_reg_reg(rFlagsReg cr, iRegL op1, iRegL op2)
ins_pipe(icmp_reg_reg);
%}
instruct compL_reg_immI0(rFlagsReg cr, iRegL op1, immI0 zero)
instruct compL_reg_immL0(rFlagsReg cr, iRegL op1, immL0 zero)
%{
match(Set cr (CmpL op1 zero));
@ -14436,6 +14436,62 @@ instruct compL_reg_immL(rFlagsReg cr, iRegL op1, immL op2)
ins_pipe(icmp_reg_imm);
%}
instruct compUL_reg_reg(rFlagsRegU cr, iRegL op1, iRegL op2)
%{
match(Set cr (CmpUL op1 op2));
effect(DEF cr, USE op1, USE op2);
ins_cost(INSN_COST);
format %{ "cmp $op1, $op2" %}
ins_encode(aarch64_enc_cmp(op1, op2));
ins_pipe(icmp_reg_reg);
%}
instruct compUL_reg_immL0(rFlagsRegU cr, iRegL op1, immL0 zero)
%{
match(Set cr (CmpUL op1 zero));
effect(DEF cr, USE op1);
ins_cost(INSN_COST);
format %{ "tst $op1" %}
ins_encode(aarch64_enc_cmp_imm_addsub(op1, zero));
ins_pipe(icmp_reg_imm);
%}
instruct compUL_reg_immLAddSub(rFlagsRegU cr, iRegL op1, immLAddSub op2)
%{
match(Set cr (CmpUL op1 op2));
effect(DEF cr, USE op1);
ins_cost(INSN_COST);
format %{ "cmp $op1, $op2" %}
ins_encode(aarch64_enc_cmp_imm_addsub(op1, op2));
ins_pipe(icmp_reg_imm);
%}
instruct compUL_reg_immL(rFlagsRegU cr, iRegL op1, immL op2)
%{
match(Set cr (CmpUL op1 op2));
effect(DEF cr, USE op1);
ins_cost(INSN_COST * 2);
format %{ "cmp $op1, $op2" %}
ins_encode(aarch64_enc_cmp_imm(op1, op2));
ins_pipe(icmp_reg_imm);
%}
instruct compP_reg_reg(rFlagsRegU cr, iRegP op1, iRegP op2)
%{
match(Set cr (CmpP op1 op2));
@ -14920,7 +14976,7 @@ instruct cmpUI_imm0_branch(cmpOpUEqNeLtGe cmp, iRegIorL2I op1, immI0 op2, label
%}
instruct cmpUL_imm0_branch(cmpOpUEqNeLtGe cmp, iRegL op1, immL0 op2, label labl, rFlagsRegU cr) %{
match(If cmp (CmpU op1 op2));
match(If cmp (CmpUL op1 op2));
effect(USE labl);
ins_cost(BRANCH_COST);

View File

@ -49,12 +49,11 @@ define_pd_global(intx, ConditionalMoveLimit, 3);
define_pd_global(intx, FLOATPRESSURE, 64);
define_pd_global(intx, FreqInlineSize, 325);
define_pd_global(intx, MinJumpTableSize, 10);
define_pd_global(intx, INTPRESSURE, 25);
define_pd_global(intx, INTPRESSURE, 24);
define_pd_global(intx, InteriorEntryAlignment, 16);
define_pd_global(intx, NewSizeThreadIncrease, ScaleForWordSize(4*K));
define_pd_global(intx, LoopUnrollLimit, 60);
define_pd_global(intx, LoopPercentProfileLimit, 10);
define_pd_global(intx, PostLoopMultiversioning, false);
// InitialCodeCacheSize derived from specjbb2000 run.
define_pd_global(intx, InitialCodeCacheSize, 2496*K); // Integral multiple of CodeCacheExpansionSize
define_pd_global(intx, CodeCacheExpansionSize, 64*K);

View File

@ -2695,6 +2695,30 @@ operand flagsRegL_LEGT() %{
format %{ "apsr_L_LEGT" %}
interface(REG_INTER);
%}
operand flagsRegUL_LTGE() %{
constraint(ALLOC_IN_RC(int_flags));
match(RegFlags);
format %{ "apsr_UL_LTGE" %}
interface(REG_INTER);
%}
operand flagsRegUL_EQNE() %{
constraint(ALLOC_IN_RC(int_flags));
match(RegFlags);
format %{ "apsr_UL_EQNE" %}
interface(REG_INTER);
%}
operand flagsRegUL_LEGT() %{
constraint(ALLOC_IN_RC(int_flags));
match(RegFlags);
format %{ "apsr_UL_LEGT" %}
interface(REG_INTER);
%}
#endif
// Condition Code Register, floating comparisons, unordered same as "less".
@ -3249,6 +3273,39 @@ operand cmpOpL_commute() %{
%}
%}
operand cmpOpUL() %{
match(Bool);
format %{ "UL" %}
interface(COND_INTER) %{
equal(0x0);
not_equal(0x1);
less(0x3);
greater_equal(0x2);
less_equal(0x9);
greater(0x8);
overflow(0x0); // unsupported/unimplemented
no_overflow(0x0); // unsupported/unimplemented
%}
%}
operand cmpOpUL_commute() %{
match(Bool);
format %{ "UL" %}
interface(COND_INTER) %{
equal(0x0);
not_equal(0x1);
less(0x8);
greater_equal(0x9);
less_equal(0x2);
greater(0x3);
overflow(0x0); // unsupported/unimplemented
no_overflow(0x0); // unsupported/unimplemented
%}
%}
//----------OPERAND CLASSES----------------------------------------------------
// Operand Classes are groups of operands that are used to simplify
// instruction definitions by not requiring the AD writer to specify separate
@ -10467,6 +10524,17 @@ instruct compL_reg_reg(flagsReg xcc, iRegL op1, iRegL op2)
%}
ins_pipe(ialu_cconly_reg_reg);
%}
instruct compUL_iReg(flagsRegU xcc, iRegL op1, iRegL op2) %{
match(Set xcc (CmpUL op1 op2));
size(4);
format %{ "CMP $op1,$op2\t! unsigned long" %}
ins_encode %{
__ cmp($op1$$Register, $op2$$Register);
%}
ins_pipe(ialu_cconly_reg_reg);
%}
#else
instruct compL_reg_reg_LTGE(flagsRegL_LTGE xcc, iRegL op1, iRegL op2, iRegL tmp) %{
match(Set xcc (CmpL op1 op2));
@ -10481,6 +10549,20 @@ instruct compL_reg_reg_LTGE(flagsRegL_LTGE xcc, iRegL op1, iRegL op2, iRegL tmp)
%}
ins_pipe(ialu_cconly_reg_reg);
%}
instruct compUL_reg_reg_LTGE(flagsRegUL_LTGE xcc, iRegL op1, iRegL op2, iRegL tmp) %{
match(Set xcc (CmpUL op1 op2));
effect(DEF xcc, USE op1, USE op2, TEMP tmp);
size(8);
format %{ "SUBS $tmp,$op1.low,$op2.low\t\t! unsigned long\n\t"
"SBCS $tmp,$op1.hi,$op2.hi" %}
ins_encode %{
__ subs($tmp$$Register, $op1$$Register, $op2$$Register);
__ sbcs($tmp$$Register->successor(), $op1$$Register->successor(), $op2$$Register->successor());
%}
ins_pipe(ialu_cconly_reg_reg);
%}
#endif
#ifdef AARCH64
@ -10496,6 +10578,19 @@ instruct compL_reg_con(flagsReg xcc, iRegL op1, aimmL con) %{
ins_pipe(ialu_cconly_reg_imm);
%}
instruct compUL_reg_con(flagsRegU xcc, iRegL op1, aimmL con) %{
match(Set xcc (CmpUL op1 con));
effect(DEF xcc, USE op1, USE con);
size(8);
format %{ "CMP $op1,$con\t\t! unsigned long" %}
ins_encode %{
__ cmp($op1$$Register, $con$$constant);
%}
ins_pipe(ialu_cconly_reg_imm);
%}
#else
instruct compL_reg_reg_EQNE(flagsRegL_EQNE xcc, iRegL op1, iRegL op2) %{
match(Set xcc (CmpL op1 op2));
@ -10575,6 +10670,85 @@ instruct compL_reg_con_LEGT(flagsRegL_LEGT xcc, iRegL op1, immLlowRot con, iRegL
ins_pipe(ialu_cconly_reg_reg);
%}
instruct compUL_reg_reg_EQNE(flagsRegUL_EQNE xcc, iRegL op1, iRegL op2) %{
match(Set xcc (CmpUL op1 op2));
effect(DEF xcc, USE op1, USE op2);
size(8);
format %{ "TEQ $op1.hi,$op2.hi\t\t! unsigned long\n\t"
"TEQ.eq $op1.lo,$op2.lo" %}
ins_encode %{
__ teq($op1$$Register->successor(), $op2$$Register->successor());
__ teq($op1$$Register, $op2$$Register, eq);
%}
ins_pipe(ialu_cconly_reg_reg);
%}
instruct compUL_reg_reg_LEGT(flagsRegUL_LEGT xcc, iRegL op1, iRegL op2, iRegL tmp) %{
match(Set xcc (CmpUL op1 op2));
effect(DEF xcc, USE op1, USE op2, TEMP tmp);
size(8);
format %{ "SUBS $tmp,$op2.low,$op1.low\t\t! unsigned long\n\t"
"SBCS $tmp,$op2.hi,$op1.hi" %}
ins_encode %{
__ subs($tmp$$Register, $op2$$Register, $op1$$Register);
__ sbcs($tmp$$Register->successor(), $op2$$Register->successor(), $op1$$Register->successor());
%}
ins_pipe(ialu_cconly_reg_reg);
%}
// TODO: try immLRot2 instead, (0, $con$$constant) becomes
// (hi($con$$constant), lo($con$$constant)) becomes
instruct compUL_reg_con_LTGE(flagsRegUL_LTGE xcc, iRegL op1, immLlowRot con, iRegL tmp) %{
match(Set xcc (CmpUL op1 con));
effect(DEF xcc, USE op1, USE con, TEMP tmp);
size(8);
format %{ "SUBS $tmp,$op1.low,$con\t\t! unsigned long\n\t"
"SBCS $tmp,$op1.hi,0" %}
ins_encode %{
__ subs($tmp$$Register, $op1$$Register, $con$$constant);
__ sbcs($tmp$$Register->successor(), $op1$$Register->successor(), 0);
%}
ins_pipe(ialu_cconly_reg_reg);
%}
// TODO: try immLRot2 instead, (0, $con$$constant) becomes
// (hi($con$$constant), lo($con$$constant)) becomes
instruct compUL_reg_con_EQNE(flagsRegUL_EQNE xcc, iRegL op1, immLlowRot con) %{
match(Set xcc (CmpUL op1 con));
effect(DEF xcc, USE op1, USE con);
size(8);
format %{ "TEQ $op1.hi,0\t\t! unsigned long\n\t"
"TEQ.eq $op1.lo,$con" %}
ins_encode %{
__ teq($op1$$Register->successor(), 0);
__ teq($op1$$Register, $con$$constant, eq);
%}
ins_pipe(ialu_cconly_reg_reg);
%}
// TODO: try immLRot2 instead, (0, $con$$constant) becomes
// (hi($con$$constant), lo($con$$constant)) becomes
instruct compUL_reg_con_LEGT(flagsRegUL_LEGT xcc, iRegL op1, immLlowRot con, iRegL tmp) %{
match(Set xcc (CmpUL op1 con));
effect(DEF xcc, USE op1, USE con, TEMP tmp);
size(8);
format %{ "RSBS $tmp,$op1.low,$con\t\t! unsigned long\n\t"
"RSCS $tmp,$op1.hi,0" %}
ins_encode %{
__ rsbs($tmp$$Register, $op1$$Register, $con$$constant);
__ rscs($tmp$$Register->successor(), $op1$$Register->successor(), 0);
%}
ins_pipe(ialu_cconly_reg_reg);
%}
#endif
/* instruct testL_reg_reg(flagsRegL xcc, iRegL op1, iRegL op2, immL0 zero) %{ */
@ -11126,6 +11300,48 @@ instruct branchConL_LEGT(cmpOpL_commute cmp, flagsRegL_LEGT xcc, label labl) %{
%}
ins_pipe(br_cc);
%}
instruct branchConUL_LTGE(cmpOpUL cmp, flagsRegUL_LTGE xcc, label labl) %{
match(If cmp xcc);
effect(USE labl);
predicate(_kids[0]->_leaf->as_Bool()->_test._test == BoolTest::lt || _kids[0]->_leaf->as_Bool()->_test._test == BoolTest::ge);
size(4);
ins_cost(BRANCH_COST);
format %{ "B$cmp $xcc,$labl" %}
ins_encode %{
__ b(*($labl$$label), (AsmCondition)($cmp$$cmpcode));
%}
ins_pipe(br_cc);
%}
instruct branchConUL_EQNE(cmpOpUL cmp, flagsRegUL_EQNE xcc, label labl) %{
match(If cmp xcc);
effect(USE labl);
predicate(_kids[0]->_leaf->as_Bool()->_test._test == BoolTest::eq || _kids[0]->_leaf->as_Bool()->_test._test == BoolTest::ne);
size(4);
ins_cost(BRANCH_COST);
format %{ "B$cmp $xcc,$labl" %}
ins_encode %{
__ b(*($labl$$label), (AsmCondition)($cmp$$cmpcode));
%}
ins_pipe(br_cc);
%}
instruct branchConUL_LEGT(cmpOpUL_commute cmp, flagsRegUL_LEGT xcc, label labl) %{
match(If cmp xcc);
effect(USE labl);
predicate(_kids[0]->_leaf->as_Bool()->_test._test == BoolTest::gt || _kids[0]->_leaf->as_Bool()->_test._test == BoolTest::le);
size(4);
ins_cost(BRANCH_COST);
format %{ "B$cmp $xcc,$labl" %}
ins_encode %{
__ b(*($labl$$label), (AsmCondition)($cmp$$cmpcode));
%}
ins_pipe(br_cc);
%}
#endif
instruct branchLoopEnd(cmpOp cmp, flagsReg icc, label labl) %{

View File

@ -70,7 +70,6 @@ define_pd_global(bool, UseTLAB, true);
define_pd_global(bool, ResizeTLAB, true);
define_pd_global(intx, LoopUnrollLimit, 60); // Design center runs on 1.3.1
define_pd_global(intx, LoopPercentProfileLimit, 10);
define_pd_global(intx, PostLoopMultiversioning, false);
define_pd_global(intx, MinJumpTableSize, 16);
// Peephole and CISC spilling both break the graph, and so makes the

View File

@ -55,7 +55,6 @@ define_pd_global(bool, UseTLAB, true);
define_pd_global(bool, ResizeTLAB, true);
define_pd_global(intx, LoopUnrollLimit, 60);
define_pd_global(intx, LoopPercentProfileLimit, 10);
define_pd_global(intx, PostLoopMultiversioning, false);
// Peephole and CISC spilling both break the graph, and so make the
// scheduler sick.

View File

@ -11048,6 +11048,29 @@ instruct cmpL_reg_imm16(flagsReg crx, iRegLsrc src1, immL16 src2) %{
ins_pipe(pipe_class_compare);
%}
// Added CmpUL for LoopPredicate.
instruct cmpUL_reg_reg(flagsReg crx, iRegLsrc src1, iRegLsrc src2) %{
match(Set crx (CmpUL src1 src2));
format %{ "CMPLD $crx, $src1, $src2" %}
size(4);
ins_encode %{
// TODO: PPC port $archOpcode(ppc64Opcode_cmpl);
__ cmpld($crx$$CondRegister, $src1$$Register, $src2$$Register);
%}
ins_pipe(pipe_class_compare);
%}
instruct cmpUL_reg_imm16(flagsReg crx, iRegLsrc src1, uimmL16 src2) %{
match(Set crx (CmpUL src1 src2));
format %{ "CMPLDI $crx, $src1, $src2" %}
size(4);
ins_encode %{
// TODO: PPC port $archOpcode(ppc64Opcode_cmpli);
__ cmpldi($crx$$CondRegister, $src1$$Register, $src2$$constant);
%}
ins_pipe(pipe_class_compare);
%}
instruct testL_reg_reg(flagsRegCR0 cr0, iRegLsrc src1, iRegLsrc src2, immL_0 zero) %{
match(Set cr0 (CmpL (AndL src1 src2) zero));
// r0 is killed

View File

@ -56,7 +56,6 @@ define_pd_global(bool, UseTLAB, true);
define_pd_global(bool, ResizeTLAB, true);
define_pd_global(intx, LoopUnrollLimit, 60);
define_pd_global(intx, LoopPercentProfileLimit, 10);
define_pd_global(intx, PostLoopMultiversioning, false);
define_pd_global(intx, MinJumpTableSize, 18);
// Peephole and CISC spilling both break the graph, and so makes the

View File

@ -8475,6 +8475,24 @@ instruct compL_reg_memI(iRegL dst, memory src, flagsReg cr)%{
%}
// LONG unsigned
// Added CmpUL for LoopPredicate.
instruct compUL_reg_reg(flagsReg cr, iRegL op1, iRegL op2) %{
match(Set cr (CmpUL op1 op2));
size(4);
format %{ "CLGR $op1,$op2\t # long" %}
opcode(CLGR_ZOPC);
ins_encode(z_rreform(op1, op2));
ins_pipe(pipe_class_dummy);
%}
instruct compUL_reg_imm32(flagsReg cr, iRegL op1, uimmL32 con) %{
match(Set cr (CmpUL op1 con));
size(6);
format %{ "CLGFI $op1,$con" %}
opcode(CLGFI_ZOPC);
ins_encode(z_rilform_unsigned(op1, con));
ins_pipe(pipe_class_dummy);
%}
// PTR unsigned

View File

@ -53,7 +53,6 @@ define_pd_global(bool, UseTLAB, true);
define_pd_global(bool, ResizeTLAB, true);
define_pd_global(intx, LoopUnrollLimit, 60); // Design center runs on 1.3.1
define_pd_global(intx, LoopPercentProfileLimit, 10);
define_pd_global(intx, PostLoopMultiversioning, false);
define_pd_global(intx, MinJumpTableSize, 5);
// Peephole and CISC spilling both break the graph, and so makes the

View File

@ -3403,6 +3403,16 @@ operand immU12() %{
interface(CONST_INTER);
%}
// Unsigned Long Immediate: 12-bit (non-negative that fits in simm13)
operand immUL12() %{
predicate((0 <= n->get_long()) && (n->get_long() == (int)n->get_long()) && Assembler::is_simm13((int)n->get_long()));
match(ConL);
op_cost(0);
format %{ %}
interface(CONST_INTER);
%}
// Integer Immediate non-negative
operand immU31()
%{
@ -3936,6 +3946,15 @@ operand flagsRegL() %{
interface(REG_INTER);
%}
// Condition Code Register, unsigned long comparisons.
operand flagsRegUL() %{
constraint(ALLOC_IN_RC(int_flags));
match(RegFlags);
format %{ "xcc_UL" %}
interface(REG_INTER);
%}
// Condition Code Register, floating comparisons, unordered same as "less".
operand flagsRegF() %{
constraint(ALLOC_IN_RC(float_flags));
@ -8797,6 +8816,17 @@ instruct compU_iReg(flagsRegU icc, iRegI op1, iRegI op2) %{
ins_pipe(ialu_cconly_reg_reg);
%}
instruct compUL_iReg(flagsRegUL xcc, iRegL op1, iRegL op2) %{
match(Set xcc (CmpUL op1 op2));
effect(DEF xcc, USE op1, USE op2);
size(4);
format %{ "CMP $op1,$op2\t! unsigned long" %}
opcode(Assembler::subcc_op3, Assembler::arith_op);
ins_encode(form3_rs1_rs2_rd(op1, op2, R_G0));
ins_pipe(ialu_cconly_reg_reg);
%}
instruct compI_iReg_imm13(flagsReg icc, iRegI op1, immI13 op2) %{
match(Set icc (CmpI op1 op2));
effect( DEF icc, USE op1 );
@ -8883,6 +8913,17 @@ instruct compU_iReg_imm13(flagsRegU icc, iRegI op1, immU12 op2 ) %{
ins_pipe(ialu_cconly_reg_imm);
%}
instruct compUL_iReg_imm13(flagsRegUL xcc, iRegL op1, immUL12 op2) %{
match(Set xcc (CmpUL op1 op2));
effect(DEF xcc, USE op1, USE op2);
size(4);
format %{ "CMP $op1,$op2\t! unsigned long" %}
opcode(Assembler::subcc_op3, Assembler::arith_op);
ins_encode(form3_rs1_simm13_rd(op1, op2, R_G0));
ins_pipe(ialu_cconly_reg_imm);
%}
// Compare Pointers
instruct compP_iRegP(flagsRegP pcc, iRegP op1, iRegP op2 ) %{
match(Set pcc (CmpP op1 op2));
@ -9256,6 +9297,44 @@ instruct cmpU_imm_branch(cmpOpU cmp, iRegI op1, immI5 op2, label labl, flagsRegU
ins_pipe(cmp_br_reg_imm);
%}
instruct cmpUL_reg_branch(cmpOpU cmp, iRegL op1, iRegL op2, label labl, flagsRegUL xcc) %{
match(If cmp (CmpUL op1 op2));
effect(USE labl, KILL xcc);
size(12);
ins_cost(BRANCH_COST);
format %{ "CMP $op1,$op2\t! unsigned long\n\t"
"BP$cmp $labl" %}
ins_encode %{
Label* L = $labl$$label;
Assembler::Predict predict_taken =
cbuf.is_backward_branch(*L) ? Assembler::pt : Assembler::pn;
__ cmp($op1$$Register, $op2$$Register);
__ bp((Assembler::Condition)($cmp$$cmpcode), false, Assembler::xcc, predict_taken, *L);
__ delayed()->nop();
%}
ins_pipe(cmp_br_reg_reg);
%}
instruct cmpUL_imm_branch(cmpOpU cmp, iRegL op1, immL5 op2, label labl, flagsRegUL xcc) %{
match(If cmp (CmpUL op1 op2));
effect(USE labl, KILL xcc);
size(12);
ins_cost(BRANCH_COST);
format %{ "CMP $op1,$op2\t! unsigned long\n\t"
"BP$cmp $labl" %}
ins_encode %{
Label* L = $labl$$label;
Assembler::Predict predict_taken =
cbuf.is_backward_branch(*L) ? Assembler::pt : Assembler::pn;
__ cmp($op1$$Register, $op2$$constant);
__ bp((Assembler::Condition)($cmp$$cmpcode), false, Assembler::xcc, predict_taken, *L);
__ delayed()->nop();
%}
ins_pipe(cmp_br_reg_imm);
%}
instruct cmpL_reg_branch(cmpOp cmp, iRegL op1, iRegL op2, label labl, flagsRegL xcc) %{
match(If cmp (CmpL op1 op2));
effect(USE labl, KILL xcc);
@ -9484,6 +9563,42 @@ instruct cmpU_imm_branch_short(cmpOpU cmp, iRegI op1, immI5 op2, label labl, fla
ins_pipe(cbcond_reg_imm);
%}
instruct cmpUL_reg_branch_short(cmpOpU cmp, iRegL op1, iRegL op2, label labl, flagsRegUL xcc) %{
match(If cmp (CmpUL op1 op2));
predicate(UseCBCond);
effect(USE labl, KILL xcc);
size(4);
ins_cost(BRANCH_COST);
format %{ "CXB$cmp $op1,$op2,$labl\t! unsigned long" %}
ins_encode %{
Label* L = $labl$$label;
assert(__ use_cbcond(*L), "back to back cbcond");
__ cbcond((Assembler::Condition)($cmp$$cmpcode), Assembler::xcc, $op1$$Register, $op2$$Register, *L);
%}
ins_short_branch(1);
ins_avoid_back_to_back(AVOID_BEFORE_AND_AFTER);
ins_pipe(cbcond_reg_reg);
%}
instruct cmpUL_imm_branch_short(cmpOpU cmp, iRegL op1, immL5 op2, label labl, flagsRegUL xcc) %{
match(If cmp (CmpUL op1 op2));
predicate(UseCBCond);
effect(USE labl, KILL xcc);
size(4);
ins_cost(BRANCH_COST);
format %{ "CXB$cmp $op1,$op2,$labl\t! unsigned long" %}
ins_encode %{
Label* L = $labl$$label;
assert(__ use_cbcond(*L), "back to back cbcond");
__ cbcond((Assembler::Condition)($cmp$$cmpcode), Assembler::xcc, $op1$$Register, $op2$$constant, *L);
%}
ins_short_branch(1);
ins_avoid_back_to_back(AVOID_BEFORE_AND_AFTER);
ins_pipe(cbcond_reg_imm);
%}
instruct cmpL_reg_branch_short(cmpOp cmp, iRegL op1, iRegL op2, label labl, flagsRegL xcc) %{
match(If cmp (CmpL op1 op2));
predicate(UseCBCond);
@ -9722,6 +9837,25 @@ instruct branchCon_long(cmpOp cmp, flagsRegL xcc, label labl) %{
ins_pipe(br_cc);
%}
instruct branchConU_long(cmpOpU cmp, flagsRegUL xcc, label labl) %{
match(If cmp xcc);
effect(USE labl);
size(8);
ins_cost(BRANCH_COST);
format %{ "BP$cmp $xcc,$labl" %}
ins_encode %{
Label* L = $labl$$label;
Assembler::Predict predict_taken =
cbuf.is_backward_branch(*L) ? Assembler::pt : Assembler::pn;
__ bp((Assembler::Condition)($cmp$$cmpcode), false, Assembler::xcc, predict_taken, *L);
__ delayed()->nop();
%}
ins_avoid_back_to_back(AVOID_BEFORE);
ins_pipe(br_cc);
%}
// Manifest a CmpL3 result in an integer register. Very painful.
// This is the test to avoid.
instruct cmpL3_reg_reg(iRegI dst, iRegL src1, iRegL src2, flagsReg ccr ) %{

View File

@ -47,7 +47,6 @@ define_pd_global(intx, ConditionalMoveLimit, 3);
define_pd_global(intx, FreqInlineSize, 325);
define_pd_global(intx, MinJumpTableSize, 10);
define_pd_global(intx, LoopPercentProfileLimit, 30);
define_pd_global(intx, PostLoopMultiversioning, true);
#ifdef AMD64
define_pd_global(intx, INTPRESSURE, 13);
define_pd_global(intx, FLOATPRESSURE, 14);

View File

@ -116,7 +116,7 @@ define_pd_global(intx, InitArrayShortSize, 8*BytesPerLong);
product(bool, UseStoreImmI16, true, \
"Use store immediate 16-bits value instruction on x86") \
\
product(intx, UseAVX, 99, \
product(intx, UseAVX, 2, \
"Highest supported AVX instructions set on x86/x64") \
range(0, 99) \
\

View File

@ -4030,6 +4030,26 @@ operand flagsReg_long_LEGT() %{
interface(REG_INTER);
%}
// Condition Code Register used by unsigned long compare
operand flagsReg_ulong_LTGE() %{
constraint(ALLOC_IN_RC(int_flags));
match(RegFlags);
format %{ "FLAGS_U_LTGE" %}
interface(REG_INTER);
%}
operand flagsReg_ulong_EQNE() %{
constraint(ALLOC_IN_RC(int_flags));
match(RegFlags);
format %{ "FLAGS_U_EQNE" %}
interface(REG_INTER);
%}
operand flagsReg_ulong_LEGT() %{
constraint(ALLOC_IN_RC(int_flags));
match(RegFlags);
format %{ "FLAGS_U_LEGT" %}
interface(REG_INTER);
%}
// Float register operands
operand regDPR() %{
predicate( UseSSE < 2 );
@ -4588,7 +4608,7 @@ operand cmpOp_fcmov() %{
%}
%}
// Comparision Code used in long compares
// Comparison Code used in long compares
operand cmpOp_commute() %{
match(Bool);
@ -4605,6 +4625,23 @@ operand cmpOp_commute() %{
%}
%}
// Comparison Code used in unsigned long compares
operand cmpOpU_commute() %{
match(Bool);
format %{ "" %}
interface(COND_INTER) %{
equal(0x4, "e");
not_equal(0x5, "ne");
less(0x7, "nbe");
greater_equal(0x6, "be");
less_equal(0x3, "nb");
greater(0x2, "b");
overflow(0x0, "o");
no_overflow(0x1, "no");
%}
%}
//----------OPERAND CLASSES----------------------------------------------------
// Operand Classes are groups of operands that are used as to simplify
// instruction definitions by not requiring the AD writer to specify separate
@ -12639,6 +12676,44 @@ instruct cmpL_LTGE(cmpOp cmp, flagsReg_long_LTGE flags, label labl) %{
%}
%}
//======
// Manifest a CmpUL result in the normal flags. Only good for LT or GE
// compares. Can be used for LE or GT compares by reversing arguments.
// NOT GOOD FOR EQ/NE tests.
instruct cmpUL_zero_flags_LTGE(flagsReg_ulong_LTGE flags, eRegL src, immL0 zero) %{
match(Set flags (CmpUL src zero));
ins_cost(100);
format %{ "TEST $src.hi,$src.hi" %}
opcode(0x85);
ins_encode(OpcP, RegReg_Hi2(src, src));
ins_pipe(ialu_cr_reg_reg);
%}
// Manifest a CmpUL result in the normal flags. Only good for LT or GE
// compares. Can be used for LE or GT compares by reversing arguments.
// NOT GOOD FOR EQ/NE tests.
instruct cmpUL_reg_flags_LTGE(flagsReg_ulong_LTGE flags, eRegL src1, eRegL src2, rRegI tmp) %{
match(Set flags (CmpUL src1 src2));
effect(TEMP tmp);
ins_cost(300);
format %{ "CMP $src1.lo,$src2.lo\t! Unsigned long compare; set flags for low bits\n\t"
"MOV $tmp,$src1.hi\n\t"
"SBB $tmp,$src2.hi\t! Compute flags for unsigned long compare" %}
ins_encode(long_cmp_flags2(src1, src2, tmp));
ins_pipe(ialu_cr_reg_reg);
%}
// Unsigned long compares reg < zero/req OR reg >= zero/req.
// Just a wrapper for a normal branch, plus the predicate test.
instruct cmpUL_LTGE(cmpOpU cmp, flagsReg_ulong_LTGE flags, label labl) %{
match(If cmp flags);
effect(USE labl);
predicate(_kids[0]->_leaf->as_Bool()->_test._test == BoolTest::lt || _kids[0]->_leaf->as_Bool()->_test._test == BoolTest::ge);
expand %{
jmpCon(cmp, flags, labl); // JLT or JGE...
%}
%}
// Compare 2 longs and CMOVE longs.
instruct cmovLL_reg_LTGE(cmpOp cmp, flagsReg_long_LTGE flags, eRegL dst, eRegL src) %{
match(Set dst (CMoveL (Binary cmp flags) (Binary dst src)));
@ -12767,6 +12842,41 @@ instruct cmpL_EQNE(cmpOp cmp, flagsReg_long_EQNE flags, label labl) %{
%}
%}
//======
// Manifest a CmpUL result in the normal flags. Only good for EQ/NE compares.
instruct cmpUL_zero_flags_EQNE(flagsReg_ulong_EQNE flags, eRegL src, immL0 zero, rRegI tmp) %{
match(Set flags (CmpUL src zero));
effect(TEMP tmp);
ins_cost(200);
format %{ "MOV $tmp,$src.lo\n\t"
"OR $tmp,$src.hi\t! Unsigned long is EQ/NE 0?" %}
ins_encode(long_cmp_flags0(src, tmp));
ins_pipe(ialu_reg_reg_long);
%}
// Manifest a CmpUL result in the normal flags. Only good for EQ/NE compares.
instruct cmpUL_reg_flags_EQNE(flagsReg_ulong_EQNE flags, eRegL src1, eRegL src2) %{
match(Set flags (CmpUL src1 src2));
ins_cost(200+300);
format %{ "CMP $src1.lo,$src2.lo\t! Unsigned long compare; set flags for low bits\n\t"
"JNE,s skip\n\t"
"CMP $src1.hi,$src2.hi\n\t"
"skip:\t" %}
ins_encode(long_cmp_flags1(src1, src2));
ins_pipe(ialu_cr_reg_reg);
%}
// Unsigned long compare reg == zero/reg OR reg != zero/reg
// Just a wrapper for a normal branch, plus the predicate test.
instruct cmpUL_EQNE(cmpOpU cmp, flagsReg_ulong_EQNE flags, label labl) %{
match(If cmp flags);
effect(USE labl);
predicate(_kids[0]->_leaf->as_Bool()->_test._test == BoolTest::eq || _kids[0]->_leaf->as_Bool()->_test._test == BoolTest::ne);
expand %{
jmpCon(cmp, flags, labl); // JEQ or JNE...
%}
%}
// Compare 2 longs and CMOVE longs.
instruct cmovLL_reg_EQNE(cmpOp cmp, flagsReg_long_EQNE flags, eRegL dst, eRegL src) %{
match(Set dst (CMoveL (Binary cmp flags) (Binary dst src)));
@ -12900,6 +13010,46 @@ instruct cmpL_LEGT(cmpOp_commute cmp, flagsReg_long_LEGT flags, label labl) %{
%}
%}
//======
// Manifest a CmpUL result in the normal flags. Only good for LE or GT compares.
// Same as cmpUL_reg_flags_LEGT except must negate src
instruct cmpUL_zero_flags_LEGT(flagsReg_ulong_LEGT flags, eRegL src, immL0 zero, rRegI tmp) %{
match(Set flags (CmpUL src zero));
effect(TEMP tmp);
ins_cost(300);
format %{ "XOR $tmp,$tmp\t# Unsigned long compare for -$src < 0, use commuted test\n\t"
"CMP $tmp,$src.lo\n\t"
"SBB $tmp,$src.hi\n\t" %}
ins_encode(long_cmp_flags3(src, tmp));
ins_pipe(ialu_reg_reg_long);
%}
// Manifest a CmpUL result in the normal flags. Only good for LE or GT compares.
// Same as cmpUL_reg_flags_LTGE except operands swapped. Swapping operands
// requires a commuted test to get the same result.
instruct cmpUL_reg_flags_LEGT(flagsReg_ulong_LEGT flags, eRegL src1, eRegL src2, rRegI tmp) %{
match(Set flags (CmpUL src1 src2));
effect(TEMP tmp);
ins_cost(300);
format %{ "CMP $src2.lo,$src1.lo\t! Unsigned long compare, swapped operands, use with commuted test\n\t"
"MOV $tmp,$src2.hi\n\t"
"SBB $tmp,$src1.hi\t! Compute flags for unsigned long compare" %}
ins_encode(long_cmp_flags2( src2, src1, tmp));
ins_pipe(ialu_cr_reg_reg);
%}
// Unsigned long compares reg < zero/req OR reg >= zero/req.
// Just a wrapper for a normal branch, plus the predicate test
instruct cmpUL_LEGT(cmpOpU_commute cmp, flagsReg_ulong_LEGT flags, label labl) %{
match(If cmp flags);
effect(USE labl);
predicate(_kids[0]->_leaf->as_Bool()->_test._test == BoolTest::gt || _kids[0]->_leaf->as_Bool()->_test._test == BoolTest::le);
ins_cost(300);
expand %{
jmpCon(cmp, flags, labl); // JGT or JLE...
%}
%}
// Compare 2 longs and CMOVE longs.
instruct cmovLL_reg_LEGT(cmpOp_commute cmp, flagsReg_long_LEGT flags, eRegL dst, eRegL src) %{
match(Set dst (CMoveL (Binary cmp flags) (Binary dst src)));

View File

@ -11518,6 +11518,48 @@ instruct cmpL3_reg_reg(rRegI dst, rRegL src1, rRegL src2, rFlagsReg flags)
ins_pipe(pipe_slow);
%}
// Unsigned long compare Instructions; really, same as signed long except they
// produce an rFlagsRegU instead of rFlagsReg.
instruct compUL_rReg(rFlagsRegU cr, rRegL op1, rRegL op2)
%{
match(Set cr (CmpUL op1 op2));
format %{ "cmpq $op1, $op2\t# unsigned" %}
opcode(0x3B); /* Opcode 3B /r */
ins_encode(REX_reg_reg_wide(op1, op2), OpcP, reg_reg(op1, op2));
ins_pipe(ialu_cr_reg_reg);
%}
instruct compUL_rReg_imm(rFlagsRegU cr, rRegL op1, immL32 op2)
%{
match(Set cr (CmpUL op1 op2));
format %{ "cmpq $op1, $op2\t# unsigned" %}
opcode(0x81, 0x07); /* Opcode 81 /7 */
ins_encode(OpcSErm_wide(op1, op2), Con8or32(op2));
ins_pipe(ialu_cr_reg_imm);
%}
instruct compUL_rReg_mem(rFlagsRegU cr, rRegL op1, memory op2)
%{
match(Set cr (CmpUL op1 (LoadL op2)));
format %{ "cmpq $op1, $op2\t# unsigned" %}
opcode(0x3B); /* Opcode 3B /r */
ins_encode(REX_reg_mem_wide(op1, op2), OpcP, reg_mem(op1, op2));
ins_pipe(ialu_cr_reg_mem);
%}
instruct testUL_reg(rFlagsRegU cr, rRegL src, immL0 zero)
%{
match(Set cr (CmpUL src zero));
format %{ "testq $src, $src\t# unsigned" %}
opcode(0x85);
ins_encode(REX_reg_reg_wide(src, src), OpcP, reg_reg(src, src));
ins_pipe(ialu_cr_reg_imm);
%}
//----------Max and Min--------------------------------------------------------
// Min Instructions

View File

@ -23,6 +23,7 @@
package org.graalvm.compiler.hotspot;
import java.util.Formatter;
import java.util.Objects;
/**
* Mechanism for checking that the current Java runtime environment supports the minimum JVMCI API
@ -37,10 +38,11 @@ import java.util.Formatter;
class JVMCIVersionCheck {
private static final int JVMCI8_MIN_MAJOR_VERSION = 0;
private static final int JVMCI8_MIN_MINOR_VERSION = 23;
private static final int JVMCI8_MIN_MINOR_VERSION = 26;
// Will be updated once an ea build with the required JVMCI API is available.
private static final int JVMCI9_MIN_EA_BUILD = 143;
// MAX_VALUE indicates that no current EA version is compatible with Graal.
// Note: Keep README.md in sync with the EA version support checked here.
private static final int JVMCI9_MIN_EA_BUILD = 176;
private static void failVersionCheck(boolean exit, String reason, Object... args) {
Formatter errorMessage = new Formatter().format(reason, args);
@ -77,13 +79,27 @@ class JVMCIVersionCheck {
start += "-jvmci-".length();
int end = vmVersion.indexOf('.', start);
if (end > 0) {
int major = Integer.parseInt(vmVersion.substring(start, end));
int major;
try {
major = Integer.parseInt(vmVersion.substring(start, end));
} catch (NumberFormatException e) {
failVersionCheck(exitOnFailure, "The VM does not support the minimum JVMCI API version required by Graal.%n" +
"Cannot read JVMCI major version from java.vm.version property: %s.%n", vmVersion);
return;
}
start = end + 1;
end = start;
while (end < vmVersion.length() && Character.isDigit(vmVersion.charAt(end))) {
end++;
}
int minor = Integer.parseInt(vmVersion.substring(start, end));
int minor;
try {
minor = Integer.parseInt(vmVersion.substring(start, end));
} catch (NumberFormatException e) {
failVersionCheck(exitOnFailure, "The VM does not support the minimum JVMCI API version required by Graal.%n" +
"Cannot read JVMCI minor version from java.vm.version property: %s.%n", vmVersion);
return;
}
if (major >= JVMCI8_MIN_MAJOR_VERSION && minor >= JVMCI8_MIN_MINOR_VERSION) {
return;
}
@ -96,7 +112,7 @@ class JVMCIVersionCheck {
"Cannot read JVMCI version from java.vm.version property: %s.%n", vmVersion);
} else {
if (vmVersion.contains("SNAPSHOT")) {
// The snapshot of http://hg.openjdk.java.net/jdk9/hs tip is expected to work
// The snapshot of http://hg.openjdk.java.net/jdk9/dev tip is expected to work
return;
}
if (vmVersion.contains("internal")) {
@ -104,23 +120,36 @@ class JVMCIVersionCheck {
return;
}
// http://openjdk.java.net/jeps/223
// Only support EA builds until GA is available
if (vmVersion.startsWith("9-ea+")) {
int start = "9-ea+".length();
if (vmVersion.startsWith("9+")) {
int start = "9+".length();
int end = start;
end = start;
while (end < vmVersion.length() && Character.isDigit(vmVersion.charAt(end))) {
end++;
}
int build = Integer.parseInt(vmVersion.substring(start, end));
int build;
try {
build = Integer.parseInt(vmVersion.substring(start, end));
} catch (NumberFormatException e) {
failVersionCheck(exitOnFailure, "The VM does not support the minimum JVMCI API version required by Graal.%n" +
"Cannot read JDK9 EA build number from java.vm.version property: %s.%n", vmVersion);
return;
}
if (build >= JVMCI9_MIN_EA_BUILD) {
return;
}
failVersionCheck(exitOnFailure, "The VM is an insufficiently recent EA JDK9 build for Graal: %d < %d.%n", build, JVMCI9_MIN_EA_BUILD);
// Using Object.equals suppresses Eclipse's "Dead code" warning.
// Unfortunately @SuppressWarnings("unused") can only be applied at method level.
if (Objects.equals(JVMCI9_MIN_EA_BUILD, Integer.MAX_VALUE)) {
failVersionCheck(exitOnFailure, "This version of Graal is not compatible with any JDK 9 Early Access build.%n");
} else {
failVersionCheck(exitOnFailure, "The VM is an insufficiently recent EA JDK9 build for Graal: %d < %d.%n", build, JVMCI9_MIN_EA_BUILD);
}
return;
} else {
// Graal will be compatible with all JDK versions as of 9 GA
// until a JVMCI API change is made in a 9u or later release.
}
failVersionCheck(exitOnFailure, "The VM does not support the minimum JVMCI API version required by Graal.%n" +
"Cannot read JDK9 EA build number from java.vm.version property: %s.%n", vmVersion);
}
}

View File

@ -1166,6 +1166,7 @@ void ArchDesc::buildMustCloneMap(FILE *fp_hpp, FILE *fp_cpp) {
|| strcmp(idealName,"CmpP") == 0
|| strcmp(idealName,"CmpN") == 0
|| strcmp(idealName,"CmpL") == 0
|| strcmp(idealName,"CmpUL") == 0
|| strcmp(idealName,"CmpD") == 0
|| strcmp(idealName,"CmpF") == 0
|| strcmp(idealName,"FastLock") == 0

View File

@ -748,41 +748,3 @@ bool ArrayCopyNode::modifies(intptr_t offset_lo, intptr_t offset_hi, PhaseTransf
return false;
}
// We try to replace a load from the destination of an arraycopy with
// a load from the source so the arraycopy has a chance to be
// eliminated. It's only valid if the arraycopy doesn't change the
// element that would be loaded from the source array.
bool ArrayCopyNode::can_replace_dest_load_with_src_load(intptr_t offset_lo, intptr_t offset_hi, PhaseTransform* phase) const {
assert(_kind == ArrayCopy || _kind == CopyOf || _kind == CopyOfRange, "only for real array copies");
Node* src = in(Src);
Node* dest = in(Dest);
// Check whether, assuming source and destination are the same
// array, the arraycopy modifies the element from the source we
// would load.
if ((src != dest && in(SrcPos) == in(DestPos)) || !modifies(offset_lo, offset_hi, phase, false)) {
// if not the transformation is legal
return true;
}
AllocateNode* src_alloc = AllocateNode::Ideal_allocation(src, phase);
AllocateNode* dest_alloc = AllocateNode::Ideal_allocation(dest, phase);
// Check whether source and destination can be proved to be
// different arrays
const TypeOopPtr* t_src = phase->type(src)->isa_oopptr();
const TypeOopPtr* t_dest = phase->type(dest)->isa_oopptr();
if (t_src != NULL && t_dest != NULL &&
(t_src->is_known_instance() || t_dest->is_known_instance()) &&
t_src->instance_id() != t_dest->instance_id()) {
return true;
}
if (MemNode::detect_ptr_independence(src->uncast(), src_alloc, dest->uncast(), dest_alloc, phase)) {
return true;
}
return false;
}

View File

@ -168,7 +168,6 @@ public:
static bool may_modify(const TypeOopPtr *t_oop, MemBarNode* mb, PhaseTransform *phase, ArrayCopyNode*& ac);
bool modifies(intptr_t offset_lo, intptr_t offset_hi, PhaseTransform* phase, bool must_modify) const;
bool can_replace_dest_load_with_src_load(intptr_t offset_lo, intptr_t offset_hi, PhaseTransform* phase) const;
#ifndef PRODUCT
virtual void dump_spec(outputStream *st) const;

View File

@ -181,7 +181,7 @@
"Map number of unrolls for main loop via " \
"Superword Level Parallelism analysis") \
\
diagnostic_pd(bool, PostLoopMultiversioning, \
experimental(bool, PostLoopMultiversioning, false, \
"Multi versioned post loops to eliminate range checks") \
\
notproduct(bool, TraceSuperWordLoopUnrollAnalysis, false, \

View File

@ -81,6 +81,7 @@ macro(CmpL3)
macro(CmpLTMask)
macro(CmpP)
macro(CmpU)
macro(CmpUL)
macro(CompareAndSwapB)
macro(CompareAndSwapS)
macro(CompareAndSwapI)

View File

@ -5171,6 +5171,10 @@ bool LibraryCallKit::inline_arraycopy() {
Deoptimization::Action_make_not_entrant);
assert(stopped(), "Should be stopped");
}
const TypeKlassPtr* dest_klass_t = _gvn.type(dest_klass)->is_klassptr();
const Type *toop = TypeOopPtr::make_from_klass(dest_klass_t->klass());
src = _gvn.transform(new CheckCastPPNode(control(), src, toop));
}
arraycopy_move_allocation_here(alloc, dest, saved_jvms, saved_reexecute_sp, new_idx);

View File

@ -29,6 +29,7 @@
#include "opto/connode.hpp"
#include "opto/convertnode.hpp"
#include "opto/loopnode.hpp"
#include "opto/matcher.hpp"
#include "opto/mulnode.hpp"
#include "opto/opaquenode.hpp"
#include "opto/rootnode.hpp"
@ -629,45 +630,138 @@ bool IdealLoopTree::is_range_check_if(IfNode *iff, PhaseIdealLoop *phase, Invari
// max(scale*i + offset) = scale*init + offset
BoolNode* PhaseIdealLoop::rc_predicate(IdealLoopTree *loop, Node* ctrl,
int scale, Node* offset,
Node* init, Node* limit, Node* stride,
Node* range, bool upper) {
Node* init, Node* limit, jint stride,
Node* range, bool upper, bool &overflow) {
jint con_limit = limit->is_Con() ? limit->get_int() : 0;
jint con_init = init->is_Con() ? init->get_int() : 0;
jint con_offset = offset->is_Con() ? offset->get_int() : 0;
stringStream* predString = NULL;
if (TraceLoopPredicate) {
predString = new stringStream();
predString->print("rc_predicate ");
}
Node* max_idx_expr = init;
int stride_con = stride->get_int();
if ((stride_con > 0) == (scale > 0) == upper) {
// Limit is not exact.
// Calculate exact limit here.
// Note, counted loop's test is '<' or '>'.
limit = exact_limit(loop);
max_idx_expr = new SubINode(limit, stride);
overflow = false;
Node* max_idx_expr = NULL;
const TypeInt* idx_type = TypeInt::INT;
if ((stride > 0) == (scale > 0) == upper) {
if (TraceLoopPredicate) {
predString->print(limit->is_Con() ? "(%d " : "(limit ", con_limit);
predString->print("- %d) ", stride);
}
// Check if (limit - stride) may overflow
const TypeInt* limit_type = _igvn.type(limit)->isa_int();
jint limit_lo = limit_type->_lo;
jint limit_hi = limit_type->_hi;
if ((stride > 0 && (java_subtract(limit_lo, stride) < limit_lo)) ||
(stride < 0 && (java_subtract(limit_hi, stride) > limit_hi))) {
// No overflow possible
ConINode* con_stride = _igvn.intcon(stride);
set_ctrl(con_stride, C->root());
max_idx_expr = new SubINode(limit, con_stride);
idx_type = TypeInt::make(limit_lo - stride, limit_hi - stride, limit_type->_widen);
} else {
// May overflow
overflow = true;
limit = new ConvI2LNode(limit);
register_new_node(limit, ctrl);
ConLNode* con_stride = _igvn.longcon(stride);
set_ctrl(con_stride, C->root());
max_idx_expr = new SubLNode(limit, con_stride);
}
register_new_node(max_idx_expr, ctrl);
if (TraceLoopPredicate) predString->print("(limit - stride) ");
} else {
if (TraceLoopPredicate) predString->print("init ");
if (TraceLoopPredicate) {
predString->print(init->is_Con() ? "%d " : "init ", con_init);
}
idx_type = _igvn.type(init)->isa_int();
max_idx_expr = init;
}
if (scale != 1) {
ConNode* con_scale = _igvn.intcon(scale);
set_ctrl(con_scale, C->root());
max_idx_expr = new MulINode(max_idx_expr, con_scale);
if (TraceLoopPredicate) {
predString->print("* %d ", scale);
}
// Check if (scale * max_idx_expr) may overflow
const TypeInt* scale_type = TypeInt::make(scale);
MulINode* mul = new MulINode(max_idx_expr, con_scale);
idx_type = (TypeInt*)mul->mul_ring(idx_type, scale_type);
if (overflow || TypeInt::INT->higher_equal(idx_type)) {
// May overflow
mul->destruct();
if (!overflow) {
max_idx_expr = new ConvI2LNode(max_idx_expr);
register_new_node(max_idx_expr, ctrl);
}
overflow = true;
con_scale = _igvn.longcon(scale);
set_ctrl(con_scale, C->root());
max_idx_expr = new MulLNode(max_idx_expr, con_scale);
} else {
// No overflow possible
max_idx_expr = mul;
}
register_new_node(max_idx_expr, ctrl);
if (TraceLoopPredicate) predString->print("* %d ", scale);
}
if (offset && (!offset->is_Con() || offset->get_int() != 0)){
max_idx_expr = new AddINode(max_idx_expr, offset);
if (offset && (!offset->is_Con() || con_offset != 0)){
if (TraceLoopPredicate) {
predString->print(offset->is_Con() ? "+ %d " : "+ offset", con_offset);
}
// Check if (max_idx_expr + offset) may overflow
const TypeInt* offset_type = _igvn.type(offset)->isa_int();
jint lo = java_add(idx_type->_lo, offset_type->_lo);
jint hi = java_add(idx_type->_hi, offset_type->_hi);
if (overflow || (lo > hi) ||
((idx_type->_lo & offset_type->_lo) < 0 && lo >= 0) ||
((~(idx_type->_hi | offset_type->_hi)) < 0 && hi < 0)) {
// May overflow
if (!overflow) {
max_idx_expr = new ConvI2LNode(max_idx_expr);
register_new_node(max_idx_expr, ctrl);
}
overflow = true;
offset = new ConvI2LNode(offset);
register_new_node(offset, ctrl);
max_idx_expr = new AddLNode(max_idx_expr, offset);
} else {
// No overflow possible
max_idx_expr = new AddINode(max_idx_expr, offset);
}
register_new_node(max_idx_expr, ctrl);
if (TraceLoopPredicate)
if (offset->is_Con()) predString->print("+ %d ", offset->get_int());
else predString->print("+ offset ");
}
CmpUNode* cmp = new CmpUNode(max_idx_expr, range);
CmpNode* cmp = NULL;
if (overflow) {
// Integer expressions may overflow, do long comparison
range = new ConvI2LNode(range);
register_new_node(range, ctrl);
if (!Matcher::has_match_rule(Op_CmpUL)) {
// We don't support unsigned long comparisons. Set 'max_idx_expr'
// to max_julong if < 0 to make the signed comparison fail.
ConINode* sign_pos = _igvn.intcon(BitsPerLong - 1);
set_ctrl(sign_pos, C->root());
Node* sign_bit_mask = new RShiftLNode(max_idx_expr, sign_pos);
register_new_node(sign_bit_mask, ctrl);
// OR with sign bit to set all bits to 1 if negative (otherwise no change)
max_idx_expr = new OrLNode(max_idx_expr, sign_bit_mask);
register_new_node(max_idx_expr, ctrl);
// AND with 0x7ff... to unset the sign bit
ConLNode* remove_sign_mask = _igvn.longcon(max_jlong);
set_ctrl(remove_sign_mask, C->root());
max_idx_expr = new AndLNode(max_idx_expr, remove_sign_mask);
register_new_node(max_idx_expr, ctrl);
cmp = new CmpLNode(max_idx_expr, range);
} else {
cmp = new CmpULNode(max_idx_expr, range);
}
} else {
cmp = new CmpUNode(max_idx_expr, range);
}
register_new_node(cmp, ctrl);
BoolNode* bol = new BoolNode(cmp, BoolTest::lt);
register_new_node(bol, ctrl);
@ -814,28 +908,30 @@ bool PhaseIdealLoop::loop_predication_impl(IdealLoopTree *loop) {
assert(ok, "must be index expression");
Node* init = cl->init_trip();
Node* limit = cl->limit();
Node* stride = cl->stride();
// Limit is not exact.
// Calculate exact limit here.
// Note, counted loop's test is '<' or '>'.
Node* limit = exact_limit(loop);
int stride = cl->stride()->get_int();
// Build if's for the upper and lower bound tests. The
// lower_bound test will dominate the upper bound test and all
// cloned or created nodes will use the lower bound test as
// their declared control.
ProjNode* lower_bound_proj = create_new_if_for_predicate(predicate_proj, NULL, Deoptimization::Reason_predicate, iff->Opcode());
ProjNode* upper_bound_proj = create_new_if_for_predicate(predicate_proj, NULL, Deoptimization::Reason_predicate, iff->Opcode());
assert(upper_bound_proj->in(0)->as_If()->in(0) == lower_bound_proj, "should dominate");
Node *ctrl = lower_bound_proj->in(0)->as_If()->in(0);
// Perform cloning to keep Invariance state correct since the
// late schedule will place invariant things in the loop.
Node *ctrl = predicate_proj->in(0)->as_If()->in(0);
rng = invar.clone(rng, ctrl);
if (offset && offset != zero) {
assert(invar.is_invariant(offset), "offset must be loop invariant");
offset = invar.clone(offset, ctrl);
}
// If predicate expressions may overflow in the integer range, longs are used.
bool overflow = false;
// Test the lower bound
BoolNode* lower_bound_bol = rc_predicate(loop, ctrl, scale, offset, init, limit, stride, rng, false);
BoolNode* lower_bound_bol = rc_predicate(loop, ctrl, scale, offset, init, limit, stride, rng, false, overflow);
// Negate test if necessary
bool negated = false;
if (proj->_con != predicate_proj->_con) {
@ -843,19 +939,22 @@ bool PhaseIdealLoop::loop_predication_impl(IdealLoopTree *loop) {
register_new_node(lower_bound_bol, ctrl);
negated = true;
}
ProjNode* lower_bound_proj = create_new_if_for_predicate(predicate_proj, NULL, Deoptimization::Reason_predicate, overflow ? Op_If : iff->Opcode());
IfNode* lower_bound_iff = lower_bound_proj->in(0)->as_If();
_igvn.hash_delete(lower_bound_iff);
lower_bound_iff->set_req(1, lower_bound_bol);
if (TraceLoopPredicate) tty->print_cr("lower bound check if: %s %d ", negated ? " negated" : "", lower_bound_iff->_idx);
// Test the upper bound
BoolNode* upper_bound_bol = rc_predicate(loop, lower_bound_proj, scale, offset, init, limit, stride, rng, true);
BoolNode* upper_bound_bol = rc_predicate(loop, lower_bound_proj, scale, offset, init, limit, stride, rng, true, overflow);
negated = false;
if (proj->_con != predicate_proj->_con) {
upper_bound_bol = new BoolNode(upper_bound_bol->in(1), upper_bound_bol->_test.negate());
register_new_node(upper_bound_bol, ctrl);
negated = true;
}
ProjNode* upper_bound_proj = create_new_if_for_predicate(predicate_proj, NULL, Deoptimization::Reason_predicate, overflow ? Op_If : iff->Opcode());
assert(upper_bound_proj->in(0)->as_If()->in(0) == lower_bound_proj, "should dominate");
IfNode* upper_bound_iff = upper_bound_proj->in(0)->as_If();
_igvn.hash_delete(upper_bound_iff);
upper_bound_iff->set_req(1, upper_bound_bol);

View File

@ -983,8 +983,8 @@ public:
// Construct a range check for a predicate if
BoolNode* rc_predicate(IdealLoopTree *loop, Node* ctrl,
int scale, Node* offset,
Node* init, Node* limit, Node* stride,
Node* range, bool upper);
Node* init, Node* limit, jint stride,
Node* range, bool upper, bool &overflow);
// Implementation of the loop predication to promote checks outside the loop
bool loop_predication_impl(IdealLoopTree *loop);

View File

@ -885,7 +885,7 @@ static bool skip_through_membars(Compile::AliasType* atp, const TypeInstPtr* tp,
// Is the value loaded previously stored by an arraycopy? If so return
// a load node that reads from the source array so we may be able to
// optimize out the ArrayCopy node later.
Node* LoadNode::can_see_arraycopy_value(Node* st, PhaseTransform* phase) const {
Node* LoadNode::can_see_arraycopy_value(Node* st, PhaseGVN* phase) const {
Node* ld_adr = in(MemNode::Address);
intptr_t ld_off = 0;
AllocateNode* ld_alloc = AllocateNode::Ideal_allocation(ld_adr, phase, ld_off);
@ -893,23 +893,27 @@ Node* LoadNode::can_see_arraycopy_value(Node* st, PhaseTransform* phase) const {
if (ac != NULL) {
assert(ac->is_ArrayCopy(), "what kind of node can this be?");
Node* ld = clone();
Node* mem = ac->in(TypeFunc::Memory);
Node* ctl = ac->in(0);
Node* src = ac->in(ArrayCopyNode::Src);
if (!ac->as_ArrayCopy()->is_clonebasic() && !phase->type(src)->isa_aryptr()) {
return NULL;
}
LoadNode* ld = clone()->as_Load();
Node* addp = in(MemNode::Address)->clone();
if (ac->as_ArrayCopy()->is_clonebasic()) {
assert(ld_alloc != NULL, "need an alloc");
Node* addp = in(MemNode::Address)->clone();
assert(addp->is_AddP(), "address must be addp");
assert(addp->in(AddPNode::Base) == ac->in(ArrayCopyNode::Dest)->in(AddPNode::Base), "strange pattern");
assert(addp->in(AddPNode::Address) == ac->in(ArrayCopyNode::Dest)->in(AddPNode::Address), "strange pattern");
addp->set_req(AddPNode::Base, ac->in(ArrayCopyNode::Src)->in(AddPNode::Base));
addp->set_req(AddPNode::Address, ac->in(ArrayCopyNode::Src)->in(AddPNode::Address));
ld->set_req(MemNode::Address, phase->transform(addp));
if (in(0) != NULL) {
assert(ld_alloc->in(0) != NULL, "alloc must have control");
ld->set_req(0, ld_alloc->in(0));
}
addp->set_req(AddPNode::Base, src->in(AddPNode::Base));
addp->set_req(AddPNode::Address, src->in(AddPNode::Address));
} else {
Node* src = ac->in(ArrayCopyNode::Src);
Node* addp = in(MemNode::Address)->clone();
assert(ac->as_ArrayCopy()->is_arraycopy_validated() ||
ac->as_ArrayCopy()->is_copyof_validated() ||
ac->as_ArrayCopy()->is_copyofrange_validated(), "only supported cases");
assert(addp->in(AddPNode::Base) == addp->in(AddPNode::Address), "should be");
addp->set_req(AddPNode::Base, src);
addp->set_req(AddPNode::Address, src);
@ -927,21 +931,17 @@ Node* LoadNode::can_see_arraycopy_value(Node* st, PhaseTransform* phase) const {
Node* offset = phase->transform(new AddXNode(addp->in(AddPNode::Offset), diff));
addp->set_req(AddPNode::Offset, offset);
ld->set_req(MemNode::Address, phase->transform(addp));
const TypeX *ld_offs_t = phase->type(offset)->isa_intptr_t();
if (!ac->as_ArrayCopy()->can_replace_dest_load_with_src_load(ld_offs_t->_lo, ld_offs_t->_hi, phase)) {
return NULL;
}
if (in(0) != NULL) {
assert(ac->in(0) != NULL, "alloc must have control");
ld->set_req(0, ac->in(0));
}
}
addp = phase->transform(addp);
#ifdef ASSERT
const TypePtr* adr_type = phase->type(addp)->is_ptr();
ld->_adr_type = adr_type;
#endif
ld->set_req(MemNode::Address, addp);
ld->set_req(0, ctl);
ld->set_req(MemNode::Memory, mem);
// load depends on the tests that validate the arraycopy
ld->as_Load()->_control_dependency = Pinned;
ld->_control_dependency = Pinned;
return ld;
}
return NULL;

View File

@ -270,7 +270,7 @@ protected:
const Type* load_array_final_field(const TypeKlassPtr *tkls,
ciKlass* klass) const;
Node* can_see_arraycopy_value(Node* st, PhaseTransform* phase) const;
Node* can_see_arraycopy_value(Node* st, PhaseGVN* phase) const;
// depends_only_on_test is almost always true, and needs to be almost always
// true to enable key hoisting & commoning optimizations. However, for the

View File

@ -1982,6 +1982,7 @@ void Scheduling::AddNodeToAvailableList(Node *n) {
if( last->is_MachIf() && last->in(1) == n &&
( op == Op_CmpI ||
op == Op_CmpU ||
op == Op_CmpUL ||
op == Op_CmpP ||
op == Op_CmpF ||
op == Op_CmpD ||

View File

@ -738,6 +738,60 @@ const Type *CmpLNode::sub( const Type *t1, const Type *t2 ) const {
return TypeInt::CC; // else use worst case results
}
// Simplify a CmpUL (compare 2 unsigned longs) node, based on local information.
// If both inputs are constants, compare them.
const Type* CmpULNode::sub(const Type* t1, const Type* t2) const {
assert(!t1->isa_ptr(), "obsolete usage of CmpUL");
// comparing two unsigned longs
const TypeLong* r0 = t1->is_long(); // Handy access
const TypeLong* r1 = t2->is_long();
// Current installed version
// Compare ranges for non-overlap
julong lo0 = r0->_lo;
julong hi0 = r0->_hi;
julong lo1 = r1->_lo;
julong hi1 = r1->_hi;
// If either one has both negative and positive values,
// it therefore contains both 0 and -1, and since [0..-1] is the
// full unsigned range, the type must act as an unsigned bottom.
bool bot0 = ((jlong)(lo0 ^ hi0) < 0);
bool bot1 = ((jlong)(lo1 ^ hi1) < 0);
if (bot0 || bot1) {
// All unsigned values are LE -1 and GE 0.
if (lo0 == 0 && hi0 == 0) {
return TypeInt::CC_LE; // 0 <= bot
} else if ((jlong)lo0 == -1 && (jlong)hi0 == -1) {
return TypeInt::CC_GE; // -1 >= bot
} else if (lo1 == 0 && hi1 == 0) {
return TypeInt::CC_GE; // bot >= 0
} else if ((jlong)lo1 == -1 && (jlong)hi1 == -1) {
return TypeInt::CC_LE; // bot <= -1
}
} else {
// We can use ranges of the form [lo..hi] if signs are the same.
assert(lo0 <= hi0 && lo1 <= hi1, "unsigned ranges are valid");
// results are reversed, '-' > '+' for unsigned compare
if (hi0 < lo1) {
return TypeInt::CC_LT; // smaller
} else if (lo0 > hi1) {
return TypeInt::CC_GT; // greater
} else if (hi0 == lo1 && lo0 == hi1) {
return TypeInt::CC_EQ; // Equal results
} else if (lo0 >= hi1) {
return TypeInt::CC_GE;
} else if (hi0 <= lo1) {
return TypeInt::CC_LE;
}
}
return TypeInt::CC; // else use worst case results
}
//=============================================================================
//------------------------------sub--------------------------------------------
// Simplify an CmpP (compare 2 pointers) node, based on local information.

View File

@ -198,6 +198,15 @@ public:
virtual const Type *sub( const Type *, const Type * ) const;
};
//------------------------------CmpULNode---------------------------------------
// Compare 2 unsigned long values, returning condition codes (-1, 0 or 1).
class CmpULNode : public CmpNode {
public:
CmpULNode(Node* in1, Node* in2) : CmpNode(in1, in2) { }
virtual int Opcode() const;
virtual const Type* sub(const Type*, const Type*) const;
};
//------------------------------CmpL3Node--------------------------------------
// Compare 2 long values, returning integer value (-1, 0 or 1).
class CmpL3Node : public CmpLNode {

View File

@ -2013,6 +2013,7 @@ typedef RehashableHashtable<Symbol*, mtSymbol> RehashableSymbolHashtable;
declare_c2_type(CmpPNode, CmpNode) \
declare_c2_type(CmpNNode, CmpNode) \
declare_c2_type(CmpLNode, CmpNode) \
declare_c2_type(CmpULNode, CmpNode) \
declare_c2_type(CmpL3Node, CmpLNode) \
declare_c2_type(CmpFNode, CmpNode) \
declare_c2_type(CmpF3Node, CmpFNode) \

View File

@ -0,0 +1,86 @@
/*
* Copyright (c) 2017, Red Hat, Inc. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
/**
* @test
* @bug 8181742
* @summary Loads that bypass arraycopy ends up with wrong memory state
*
* @run main/othervm -XX:-BackgroundCompilation -XX:-UseOnStackReplacement -XX:+UnlockDiagnosticVMOptions -XX:+IgnoreUnrecognizedVMOptions -XX:+StressGCM -XX:+StressLCM TestLoadBypassACWithWrongMem
*
*/
import java.util.Arrays;
public class TestLoadBypassACWithWrongMem {
static int test1(int[] src) {
int[] dst = new int[10];
System.arraycopy(src, 0, dst, 0, 10);
src[1] = 0x42;
// dst[1] is transformed to src[1], src[1] must use the
// correct memory state (not the store above).
return dst[1];
}
static int test2(int[] src) {
int[] dst = (int[])src.clone();
src[1] = 0x42;
// Same as above for clone
return dst[1];
}
static Object test5_src = null;
static int test3() {
int[] dst = new int[10];
System.arraycopy(test5_src, 0, dst, 0, 10);
((int[])test5_src)[1] = 0x42;
System.arraycopy(test5_src, 0, dst, 0, 10);
// dst[1] is transformed to test5_src[1]. test5_src is Object
// but test5_src[1] must be on the slice for int[] not
// Object+some offset.
return dst[1];
}
static public void main(String[] args) {
int[] src = new int[10];
for (int i = 0; i < 20000; i++) {
Arrays.fill(src, 0);
int res = test1(src);
if (res != 0) {
throw new RuntimeException("bad result: " + res + " != " + 0);
}
Arrays.fill(src, 0);
res = test2(src);
if (res != 0) {
throw new RuntimeException("bad result: " + res + " != " + 0);
}
Arrays.fill(src, 0);
test5_src = src;
res = test3();
if (res != 0x42) {
throw new RuntimeException("bad result: " + res + " != " + 0x42);
}
}
}
}

View File

@ -108,8 +108,8 @@ public class TestAnonymousClassUnloading {
*/
static public void main(String[] args) throws Exception {
// (1) Load an anonymous version of this class using the corresponding Unsafe method
URL classUrl = TestAnonymousClassUnloading.class.getResource(
TestAnonymousClassUnloading.class.getName().replace('.', '/') + ".class");
String rn = TestAnonymousClassUnloading.class.getSimpleName() + ".class";
URL classUrl = TestAnonymousClassUnloading.class.getResource(rn);
URLConnection connection = classUrl.openConnection();
int length = connection.getContentLength();

View File

@ -26,7 +26,7 @@
* @bug 8154763
* @summary Tests PostLoopMultiversioning with RangeCheckElimination disabled.
* @run main/othervm -XX:+IgnoreUnrecognizedVMOptions -XX:+UnlockDiagnosticVMOptions
* -XX:+PostLoopMultiversioning -XX:-RangeCheckElimination
* -XX:+UnlockExperimentalVMOptions -XX:+PostLoopMultiversioning -XX:-RangeCheckElimination
* compiler.rangechecks.TestRangeCheckEliminationDisabled
*/

View File

@ -74,7 +74,7 @@ public class ClassLoadUnloadTest {
List<String> argsList = new ArrayList<>();
Collections.addAll(argsList, args);
Collections.addAll(argsList, "-Xmn8m");
Collections.addAll(argsList, "-Dtest.classes=" + System.getProperty("test.classes","."));
Collections.addAll(argsList, "-Dtest.class.path=" + System.getProperty("test.class.path", "."));
Collections.addAll(argsList, ClassUnloadTestMain.class.getName());
return ProcessTools.createJavaProcessBuilder(argsList.toArray(new String[argsList.size()]));
}

View File

@ -31,8 +31,10 @@ import java.io.File;
import java.net.MalformedURLException;
import java.net.URL;
import java.net.URLClassLoader;
import java.nio.file.Path;
import java.nio.file.Paths;
import java.util.ArrayList;
import java.util.stream.Stream;
public class ClassUnloadCommon {
public static class TestFailure extends RuntimeException {
@ -61,14 +63,45 @@ public class ClassUnloadCommon {
System.gc();
}
/**
* Creates a class loader that loads classes from {@code ${test.class.path}}
* before delegating to the system class loader.
*/
public static ClassLoader newClassLoader() {
try {
return new URLClassLoader(new URL[] {
Paths.get(System.getProperty("test.classes",".") + File.separatorChar + "classes").toUri().toURL(),
}, null);
} catch (MalformedURLException e){
throw new RuntimeException("Unexpected URL conversion failure", e);
}
String cp = System.getProperty("test.class.path", ".");
URL[] urls = Stream.of(cp.split(File.pathSeparator))
.map(Paths::get)
.map(ClassUnloadCommon::toURL)
.toArray(URL[]::new);
return new URLClassLoader(urls) {
@Override
public Class<?> loadClass(String cn, boolean resolve)
throws ClassNotFoundException
{
synchronized (getClassLoadingLock(cn)) {
Class<?> c = findLoadedClass(cn);
if (c == null) {
try {
c = findClass(cn);
} catch (ClassNotFoundException e) {
c = getParent().loadClass(cn);
}
}
if (resolve) {
resolveClass(c);
}
return c;
}
}
};
}
static URL toURL(Path path) {
try {
return path.toUri().toURL();
} catch (MalformedURLException e) {
throw new RuntimeException(e);
}
}
}

View File

@ -432,3 +432,11 @@ b9c0b105002272d7414c8b34af9aded151f9cad6 jdk-9+174
ff293e39e83366c40a5687dacd1ccb2305ed2c1e jdk-10+12
736412a8dccee9d439044e6b1af2e7470d0a3563 jdk-9+175
5d374af9e78d02976e0e7f8dc2706f91a020f025 jdk-10+13
4d05f673cf773f1c20e8f5a879d64115d2f741d9 jdk-10+14
38cf34e2328070cc691c4f136e6dde1a44c04171 jdk-9+176
332ad9f92632f56f337b8c40edef9a95a42b26bc jdk-9+177
02a876781a3a6193140591d92db7b95ca743eac2 jdk-10+15
d109d55cf642bf2b438624e81f94c18c168f9178 jdk-10+16
0983b2dbe17ba4fed3af34e0512ca77a9845fe8a jdk-9+178
87243a3131f79e8b3903eaca6b629abc48f08ace jdk-9+179
97d6f14334cfd766f57c296a5a707c8a709aeff0 jdk-10+17

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2003, 2005, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -114,7 +114,7 @@ public class virtual_parse_stack {
real_next++;
/* put the state number from the Symbol onto the virtual stack */
vstack.push(new Integer(stack_sym.parse_state));
vstack.push(stack_sym.parse_state);
}
/*. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .*/
@ -161,7 +161,7 @@ public class virtual_parse_stack {
/** Push a state number onto the stack. */
public void push(int state_num)
{
vstack.push(new Integer(state_num));
vstack.push(state_num);
}
/*-----------------------------------------------------------*/

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -104,6 +103,6 @@ public final class ConstantDouble extends Constant implements ConstantObject {
/** @return Double object
*/
public Object getConstantValue(ConstantPool cp) {
return new Double(bytes);
return bytes;
}
}

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -103,6 +102,6 @@ public final class ConstantFloat extends Constant implements ConstantObject {
/** @return Float object
*/
public Object getConstantValue(ConstantPool cp) {
return new Float(bytes);
return bytes;
}
}

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -109,6 +108,6 @@ public final class ConstantInteger extends Constant implements ConstantObject {
/** @return Integer object
*/
public Object getConstantValue(ConstantPool cp) {
return new Integer(bytes);
return bytes;
}
}

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -101,6 +100,6 @@ public final class ConstantLong extends Constant implements ConstantObject {
/** @return Long object
*/
public Object getConstantValue(ConstantPool cp) {
return new Long(bytes);
return bytes;
}
}

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -425,7 +424,7 @@ public class JavaClass extends AccessFlags implements Cloneable, Node {
}
if(debug != null)
JavaClass.debug = new Boolean(debug).booleanValue();
JavaClass.debug = Boolean.valueOf(debug);
if(sep != null)
try {

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -72,7 +71,7 @@ public class BIPUSH extends Instruction implements ConstantPushInstruction {
b = bytes.readByte();
}
public Number getValue() { return new Integer(b); }
public Number getValue() { return Integer.valueOf(b); }
/** @return Type.BYTE
*/

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -52,7 +51,7 @@ public class DCONST extends Instruction
value = f;
}
public Number getValue() { return new Double(value); }
public Number getValue() { return Double.valueOf(value); }
/** @return Type.DOUBLE
*/

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -54,7 +53,7 @@ public class FCONST extends Instruction
value = f;
}
public Number getValue() { return new Float(value); }
public Number getValue() { return Float.valueOf(value); }
/** @return Type.FLOAT
*/

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -95,56 +94,56 @@ public class FieldGen extends FieldGenOrMethodGen {
checkType(Type.LONG);
if(l != 0L)
value = new Long(l);
value = Long.valueOf(l);
}
public void setInitValue(int i) {
checkType(Type.INT);
if(i != 0)
value = new Integer(i);
value = Integer.valueOf(i);
}
public void setInitValue(short s) {
checkType(Type.SHORT);
if(s != 0)
value = new Integer(s);
value = Integer.valueOf(s);
}
public void setInitValue(char c) {
checkType(Type.CHAR);
if(c != 0)
value = new Integer(c);
value = Integer.valueOf(c);
}
public void setInitValue(byte b) {
checkType(Type.BYTE);
if(b != 0)
value = new Integer(b);
value = Integer.valueOf(b);
}
public void setInitValue(boolean b) {
checkType(Type.BOOLEAN);
if(b)
value = new Integer(1);
value = Integer.valueOf(1);
}
public void setInitValue(float f) {
checkType(Type.FLOAT);
if(f != 0.0)
value = new Float(f);
value = Float.valueOf(f);
}
public void setInitValue(double d) {
checkType(Type.DOUBLE);
if(d != 0.0)
value = new Double(d);
value = Double.valueOf(d);
}
/** Remove any initial value.

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -50,7 +49,7 @@ public class ICONST extends Instruction
value = i;
}
public Number getValue() { return new Integer(value); }
public Number getValue() { return Integer.valueOf(value); }
/** @return Type.INT
*/

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -23,7 +22,6 @@ package com.sun.org.apache.bcel.internal.generic;
import com.sun.org.apache.bcel.internal.Constants;
import com.sun.org.apache.bcel.internal.classfile.Utility;
import com.sun.org.apache.bcel.internal.classfile.ConstantPool;
import java.io.*;
import com.sun.org.apache.bcel.internal.util.ByteSequence;
@ -165,7 +163,7 @@ public abstract class Instruction implements Cloneable, Serializable {
}
try {
obj = (Instruction)clazz.newInstance();
obj = (Instruction)clazz.getConstructor().newInstance();
if(wide && !((obj instanceof LocalVariableInstruction) ||
(obj instanceof IINC) ||

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -455,7 +454,7 @@ public class InstructionFactory
Instruction i = null;
try {
i = (Instruction)java.lang.Class.forName(name).newInstance();
i = (Instruction)java.lang.Class.forName(name).getConstructor().newInstance();
} catch(Exception e) {
throw new RuntimeException("Could not find instruction: " + name);
}

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -52,7 +51,7 @@ public class LCONST extends Instruction
value = l;
}
public Number getValue() { return new Long(value); }
public Number getValue() { return Long.valueOf(value); }
/** @return Type.LONG
*/

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -96,10 +95,10 @@ public class LDC extends CPInstruction
return ((com.sun.org.apache.bcel.internal.classfile.ConstantUtf8)c).getBytes();
case com.sun.org.apache.bcel.internal.Constants.CONSTANT_Float:
return new Float(((com.sun.org.apache.bcel.internal.classfile.ConstantFloat)c).getBytes());
return Float.valueOf(((com.sun.org.apache.bcel.internal.classfile.ConstantFloat)c).getBytes());
case com.sun.org.apache.bcel.internal.Constants.CONSTANT_Integer:
return new Integer(((com.sun.org.apache.bcel.internal.classfile.ConstantInteger)c).getBytes());
return Integer.valueOf(((com.sun.org.apache.bcel.internal.classfile.ConstantInteger)c).getBytes());
default: // Never reached
throw new RuntimeException("Unknown or invalid constant type at " + index);

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -55,10 +54,10 @@ public class LDC2_W extends CPInstruction
switch(c.getTag()) {
case com.sun.org.apache.bcel.internal.Constants.CONSTANT_Long:
return new Long(((com.sun.org.apache.bcel.internal.classfile.ConstantLong)c).getBytes());
return Long.valueOf(((com.sun.org.apache.bcel.internal.classfile.ConstantLong)c).getBytes());
case com.sun.org.apache.bcel.internal.Constants.CONSTANT_Double:
return new Double(((com.sun.org.apache.bcel.internal.classfile.ConstantDouble)c).getBytes());
return Double.valueOf(((com.sun.org.apache.bcel.internal.classfile.ConstantDouble)c).getBytes());
default: // Never reached
throw new RuntimeException("Unknown or invalid constant type at " + index);

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -69,7 +68,7 @@ public class SIPUSH extends Instruction implements ConstantPushInstruction {
b = bytes.readShort();
}
public Number getValue() { return new Integer(b); }
public Number getValue() { return Integer.valueOf(b); }
/** @return Type.SHORT
*/

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -172,7 +171,7 @@ public final class SecuritySupport {
static long getLastModified(final File f) {
return ((Long) AccessController.doPrivileged(new PrivilegedAction() {
public Object run() {
return new Long(f.lastModified());
return f.lastModified();
}
})).longValue();
}

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -375,7 +374,7 @@ public class ExsltMath extends ExsltBase
if (value != null)
{
int bits = new Double(precision).intValue();
int bits = (int)precision;
if (bits <= value.length())
value = value.substring(0, bits);

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -124,7 +123,7 @@ public class ObjectFactory {
ClassLoader cl = System.getSecurityManager()!=null ? null : findClassLoader();
try{
Class providerClass = findProviderClass(className, cl, doFallback);
Object instance = providerClass.newInstance();
Object instance = providerClass.getConstructor().newInstance();
debugPrintln(()->"created new instance of " + providerClass +
" using ClassLoader: " + cl);
return instance;

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -177,7 +176,7 @@ public final class SecuritySupport {
static long getLastModified(final File f) {
return ((Long) AccessController.doPrivileged(new PrivilegedAction() {
public Object run() {
return new Long(f.lastModified());
return f.lastModified();
}
})).longValue();
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -1005,7 +1005,7 @@ public class Parser implements Constants, ContentHandler {
if (className != null) {
try {
final Class<?> clazz = ObjectFactory.findProviderClass(className, true);
node = (SyntaxTreeNode)clazz.newInstance();
node = (SyntaxTreeNode)clazz.getDeclaredConstructor().newInstance();
node.setQName(qname);
node.setParser(this);
if (_locator != null) {

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -875,7 +874,7 @@ return newSymbol(sym.EOF);
case -21:
break;
case 21:
{ return newSymbol(sym.INT, new Long(yytext())); }
{ return newSymbol(sym.INT, Long.valueOf(yytext())); }
case -22:
break;
case 22:
@ -903,7 +902,7 @@ return newSymbol(sym.EOF);
case -28:
break;
case 28:
{ return newSymbol(sym.REAL, new Double(yytext())); }
{ return newSymbol(sym.REAL, Double.valueOf(yytext())); }
case -29:
break;
case 29:
@ -929,7 +928,7 @@ return newSymbol(sym.EOF);
case -34:
break;
case 34:
{ return newSymbol(sym.REAL, new Double(yytext())); }
{ return newSymbol(sym.REAL, Double.valueOf(yytext())); }
case -35:
break;
case 35:
@ -1057,11 +1056,11 @@ return newSymbol(sym.EOF);
case -66:
break;
case 67:
{ return newSymbol(sym.INT, new Long(yytext())); }
{ return newSymbol(sym.INT, Long.valueOf(yytext())); }
case -67:
break;
case 68:
{ return newSymbol(sym.REAL, new Double(yytext())); }
{ return newSymbol(sym.REAL, Double.valueOf(yytext())); }
case -68:
break;
case 70:

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -1342,7 +1342,7 @@ class CUP$XPathParser$actions {
case 120: // NodeTest ::= PI
{
Object RESULT = null;
RESULT = new Integer(NodeTest.PI);
RESULT = Integer.valueOf(NodeTest.PI);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(25/*NodeTest*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -1371,7 +1371,7 @@ class CUP$XPathParser$actions {
case 118: // NodeTest ::= COMMENT
{
Object RESULT = null;
RESULT = new Integer(NodeTest.COMMENT);
RESULT = Integer.valueOf(NodeTest.COMMENT);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(25/*NodeTest*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -1380,7 +1380,7 @@ class CUP$XPathParser$actions {
case 117: // NodeTest ::= TEXT
{
Object RESULT = null;
RESULT = new Integer(NodeTest.TEXT);
RESULT = Integer.valueOf(NodeTest.TEXT);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(25/*NodeTest*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -1389,7 +1389,7 @@ class CUP$XPathParser$actions {
case 116: // NodeTest ::= NODE
{
Object RESULT = null;
RESULT = new Integer(NodeTest.ANODE);
RESULT = Integer.valueOf(NodeTest.ANODE);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(25/*NodeTest*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -1815,7 +1815,7 @@ class CUP$XPathParser$actions {
case 96: // AxisName ::= SELF
{
Integer RESULT = null;
RESULT = new Integer(Axis.SELF);
RESULT = Integer.valueOf(Axis.SELF);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(40/*AxisName*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -1824,7 +1824,7 @@ class CUP$XPathParser$actions {
case 95: // AxisName ::= PRECEDINGSIBLING
{
Integer RESULT = null;
RESULT = new Integer(Axis.PRECEDINGSIBLING);
RESULT = Integer.valueOf(Axis.PRECEDINGSIBLING);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(40/*AxisName*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -1833,7 +1833,7 @@ class CUP$XPathParser$actions {
case 94: // AxisName ::= PRECEDING
{
Integer RESULT = null;
RESULT = new Integer(Axis.PRECEDING);
RESULT = Integer.valueOf(Axis.PRECEDING);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(40/*AxisName*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -1842,7 +1842,7 @@ class CUP$XPathParser$actions {
case 93: // AxisName ::= PARENT
{
Integer RESULT = null;
RESULT = new Integer(Axis.PARENT);
RESULT = Integer.valueOf(Axis.PARENT);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(40/*AxisName*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -1851,7 +1851,7 @@ class CUP$XPathParser$actions {
case 92: // AxisName ::= NAMESPACE
{
Integer RESULT = null;
RESULT = new Integer(Axis.NAMESPACE);
RESULT = Integer.valueOf(Axis.NAMESPACE);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(40/*AxisName*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -1860,7 +1860,7 @@ class CUP$XPathParser$actions {
case 91: // AxisName ::= FOLLOWINGSIBLING
{
Integer RESULT = null;
RESULT = new Integer(Axis.FOLLOWINGSIBLING);
RESULT = Integer.valueOf(Axis.FOLLOWINGSIBLING);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(40/*AxisName*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -1869,7 +1869,7 @@ class CUP$XPathParser$actions {
case 90: // AxisName ::= FOLLOWING
{
Integer RESULT = null;
RESULT = new Integer(Axis.FOLLOWING);
RESULT = Integer.valueOf(Axis.FOLLOWING);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(40/*AxisName*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -1878,7 +1878,7 @@ class CUP$XPathParser$actions {
case 89: // AxisName ::= DESCENDANTORSELF
{
Integer RESULT = null;
RESULT = new Integer(Axis.DESCENDANTORSELF);
RESULT = Integer.valueOf(Axis.DESCENDANTORSELF);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(40/*AxisName*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -1887,7 +1887,7 @@ class CUP$XPathParser$actions {
case 88: // AxisName ::= DESCENDANT
{
Integer RESULT = null;
RESULT = new Integer(Axis.DESCENDANT);
RESULT = Integer.valueOf(Axis.DESCENDANT);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(40/*AxisName*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -1896,7 +1896,7 @@ class CUP$XPathParser$actions {
case 87: // AxisName ::= CHILD
{
Integer RESULT = null;
RESULT = new Integer(Axis.CHILD);
RESULT = Integer.valueOf(Axis.CHILD);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(40/*AxisName*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -1905,7 +1905,7 @@ class CUP$XPathParser$actions {
case 86: // AxisName ::= ATTRIBUTE
{
Integer RESULT = null;
RESULT = new Integer(Axis.ATTRIBUTE);
RESULT = Integer.valueOf(Axis.ATTRIBUTE);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(40/*AxisName*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -1914,7 +1914,7 @@ class CUP$XPathParser$actions {
case 85: // AxisName ::= ANCESTORORSELF
{
Integer RESULT = null;
RESULT = new Integer(Axis.ANCESTORORSELF);
RESULT = Integer.valueOf(Axis.ANCESTORORSELF);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(40/*AxisName*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -1923,7 +1923,7 @@ class CUP$XPathParser$actions {
case 84: // AxisName ::= ANCESTOR
{
Integer RESULT = null;
RESULT = new Integer(Axis.ANCESTOR);
RESULT = Integer.valueOf(Axis.ANCESTOR);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(40/*AxisName*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -1932,7 +1932,7 @@ class CUP$XPathParser$actions {
case 83: // AxisSpecifier ::= ATSIGN
{
Integer RESULT = null;
RESULT = new Integer(Axis.ATTRIBUTE);
RESULT = Integer.valueOf(Axis.ATTRIBUTE);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(41/*AxisSpecifier*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -2697,7 +2697,7 @@ class CUP$XPathParser$actions {
case 35: // ChildOrAttributeAxisSpecifier ::= ATTRIBUTE DCOLON
{
Integer RESULT = null;
RESULT = new Integer(Axis.ATTRIBUTE);
RESULT = Integer.valueOf(Axis.ATTRIBUTE);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(42/*ChildOrAttributeAxisSpecifier*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-1)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -2706,7 +2706,7 @@ class CUP$XPathParser$actions {
case 34: // ChildOrAttributeAxisSpecifier ::= CHILD DCOLON
{
Integer RESULT = null;
RESULT = new Integer(Axis.CHILD);
RESULT = Integer.valueOf(Axis.CHILD);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(42/*ChildOrAttributeAxisSpecifier*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-1)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -2715,7 +2715,7 @@ class CUP$XPathParser$actions {
case 33: // ChildOrAttributeAxisSpecifier ::= ATSIGN
{
Integer RESULT = null;
RESULT = new Integer(Axis.ATTRIBUTE);
RESULT = Integer.valueOf(Axis.ATTRIBUTE);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(42/*ChildOrAttributeAxisSpecifier*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -2745,7 +2745,7 @@ class CUP$XPathParser$actions {
case 30: // NodeTestPattern ::= PI
{
Object RESULT = null;
RESULT = new Integer(NodeTest.PI);
RESULT = Integer.valueOf(NodeTest.PI);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(33/*NodeTestPattern*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -2754,7 +2754,7 @@ class CUP$XPathParser$actions {
case 29: // NodeTestPattern ::= COMMENT
{
Object RESULT = null;
RESULT = new Integer(NodeTest.COMMENT);
RESULT = Integer.valueOf(NodeTest.COMMENT);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(33/*NodeTestPattern*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -2763,7 +2763,7 @@ class CUP$XPathParser$actions {
case 28: // NodeTestPattern ::= TEXT
{
Object RESULT = null;
RESULT = new Integer(NodeTest.TEXT);
RESULT = Integer.valueOf(NodeTest.TEXT);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(33/*NodeTestPattern*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;
@ -2772,7 +2772,7 @@ class CUP$XPathParser$actions {
case 27: // NodeTestPattern ::= NODE
{
Object RESULT = null;
RESULT = new Integer(NodeTest.ANODE);
RESULT = Integer.valueOf(NodeTest.ANODE);
CUP$XPathParser$result = new com.sun.java_cup.internal.runtime.Symbol(33/*NodeTestPattern*/, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).left, ((com.sun.java_cup.internal.runtime.Symbol)CUP$XPathParser$stack.elementAt(CUP$XPathParser$top-0)).right, RESULT);
}
return CUP$XPathParser$result;

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -342,7 +342,7 @@ public final class XSLTC {
_elements = new HashMap<>();
_attributes = new HashMap<>();
_namespaces = new HashMap<>();
_namespaces.put("",new Integer(_nextNSType));
_namespaces.put("", _nextNSType);
_namesIndex = new Vector(128);
_namespaceIndex = new Vector(32);
_namespacePrefixes = new HashMap<>();
@ -852,7 +852,7 @@ public final class XSLTC {
_namespaces.put(namespaceURI,code);
_namespaceIndex.addElement(namespaceURI);
}
return code.intValue();
return code;
}
public int nextModeSerial() {

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -35,7 +35,7 @@ import java.io.File;
import java.io.PrintWriter;
import java.net.URL;
import java.net.URLConnection;
import java.net.URLDecoder;
import java.nio.file.Paths;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;
@ -199,7 +199,7 @@ public final class DocumentCache implements DOMCache {
// Check for a "file:" URI (courtesy of Brian Ewins)
if (timestamp == 0){ // get 0 for local URI
if ("file".equals(url.getProtocol())){
File localfile = new File(URLDecoder.decode(url.getFile()));
File localfile = Paths.get(url.toURI()).toFile();
timestamp = localfile.lastModified();
}
}

View File

@ -94,7 +94,7 @@ public class KeyIndex extends DTMAxisIteratorBase {
if (_currentDocumentNode != rootNode) {
_currentDocumentNode = rootNode;
_index = new HashMap<>();
_rootToIndexMap.put(new Integer(rootNode), _index);
_rootToIndexMap.put(rootNode, _index);
}
IntegerArray nodes = _index.get(value);
@ -178,7 +178,7 @@ public class KeyIndex extends DTMAxisIteratorBase {
int ident = _enhancedDOM.getElementById(id);
if (ident != DTM.NULL) {
Integer root = new Integer(_enhancedDOM.getDocument());
Integer root = _enhancedDOM.getDocument();
Map<String, IntegerArray> index = _rootToIndexMap.get(root);
if (index == null) {
@ -247,7 +247,7 @@ public class KeyIndex extends DTMAxisIteratorBase {
// Get the mapping table for the document containing the context node
Map<String, IntegerArray> index =
_rootToIndexMap.get(new Integer(rootHandle));
_rootToIndexMap.get(rootHandle);
// Split argument to id function into XML whitespace separated tokens
final StringTokenizer values = new StringTokenizer(string, " \n\t");
@ -298,7 +298,7 @@ public class KeyIndex extends DTMAxisIteratorBase {
// Get the mapping table for the document containing the context node
Map<String,IntegerArray> index =
_rootToIndexMap.get(new Integer(rootHandle));
_rootToIndexMap.get(rootHandle);
// Check whether the context node is present in the set of nodes
// returned by the key function
@ -701,7 +701,7 @@ public class KeyIndex extends DTMAxisIteratorBase {
IntegerArray result = null;
// Get mapping from key values/IDs to DTM nodes for this document
Map<String, IntegerArray> index = _rootToIndexMap.get(new Integer(root));
Map<String, IntegerArray> index = _rootToIndexMap.get(root);
if (!_isKeyIterator) {
// For id function, tokenize argument as whitespace separated

View File

@ -187,11 +187,11 @@ public abstract class NodeSortRecord {
translet, _last);
Double num;
try {
num = new Double(str);
num = Double.parseDouble(str);
}
// Treat number as NaN if it cannot be parsed as a double
catch (NumberFormatException e) {
num = new Double(Double.NEGATIVE_INFINITY);
num = Double.NEGATIVE_INFINITY;
}
_values[_scanned++] = num;
return(num);

View File

@ -26,6 +26,7 @@ import com.sun.org.apache.xalan.internal.xsltc.TransletException;
import com.sun.org.apache.xalan.internal.xsltc.runtime.AbstractTranslet;
import com.sun.org.apache.xml.internal.utils.LocaleUtility;
import com.sun.org.apache.xalan.internal.utils.ObjectFactory;
import java.lang.reflect.InvocationTargetException;
import java.util.Locale;
import java.text.Collator;
@ -148,10 +149,17 @@ public class NodeSortRecordFactory {
SecurityException,
TransletException {
final NodeSortRecord sortRecord =
(NodeSortRecord)_class.newInstance();
sortRecord.initialize(node, last, _dom, _sortSettings);
return sortRecord;
try {
final NodeSortRecord sortRecord;
//NodeSortRecord subclasses are generated with a public empty constructor
// refer to com.sun.org.apache.xalan.internal.xsltc.compiler.Sort::compileInit
sortRecord = (NodeSortRecord)_class.getConstructor().newInstance();
sortRecord.initialize(node, last, _dom, _sortSettings);
return sortRecord;
} catch (NoSuchMethodException | IllegalArgumentException |
InvocationTargetException ex) {
throw new InstantiationException(ex.getMessage());
}
}
public String getClassName() {

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -471,7 +471,7 @@ public final class SAXImpl extends SAX2DTM2
return 0;
}
int eType = getIdForNamespace(s);
return _nsIndex.get(new Integer(eType));
return _nsIndex.get(eType);
}
@ -672,7 +672,7 @@ public final class SAXImpl extends SAX2DTM2
for (i=0; i<nsLength; i++) {
int eType = getIdForNamespace(namespaces[i]);
Integer type = _nsIndex.get(new Integer(eType));
Integer type = _nsIndex.get(eType);
if (type != null) {
result[type] = (short)i;
}
@ -692,7 +692,7 @@ public final class SAXImpl extends SAX2DTM2
for (i = 0; i < length; i++) {
int eType = getIdForNamespace(namespaces[i]);
Integer type = _nsIndex.get(new Integer(eType));
Integer type = _nsIndex.get(eType);
result[i] = (type == null) ? -1 : type.shortValue();
}
@ -900,7 +900,7 @@ public final class SAXImpl extends SAX2DTM2
this.startElement(uri, localName, qname, attributes);
if (m_buildIdIndex) {
_node2Ids.put(node, new Integer(m_parents.peek()));
_node2Ids.put(node, m_parents.peek());
}
}
@ -979,7 +979,7 @@ public final class SAXImpl extends SAX2DTM2
throws SAXException
{
// Check if the URI already exists before pushing on stack
Integer eType = new Integer(getIdForNamespace(uri));
Integer eType = getIdForNamespace(uri);
if (_nsIndex.get(eType) == null) {
_nsIndex.put(eType, _uriCount++);
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2006, 2016, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2006, 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -155,7 +155,7 @@ public abstract class AbstractTranslet implements Translet {
* Push a new parameter frame.
*/
public final void pushParamFrame() {
paramsStack.add(pframe, new Integer(pbase));
paramsStack.add(pframe, pbase);
pbase = ++pframe;
}

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -28,6 +27,7 @@ import org.xml.sax.AttributeList;
* @author Jacek Ambroziak
* @author Santiago Pericas-Geertsen
*/
@SuppressWarnings("deprecation")
public final class Attributes implements AttributeList {
private int _element;
private DOM _document;

View File

@ -746,11 +746,11 @@ public final class BasisLibrary {
// If node-boolean comparison -> convert node to boolean
if (left instanceof Node || right instanceof Node) {
if (left instanceof Boolean) {
right = new Boolean(booleanF(right));
right = booleanF(right);
hasSimpleArgs = true;
}
if (right instanceof Boolean) {
left = new Boolean(booleanF(left));
left = booleanF(left);
hasSimpleArgs = true;
}
}

View File

@ -43,6 +43,7 @@ import java.lang.module.ModuleDescriptor;
import java.lang.module.ModuleFinder;
import java.lang.module.ModuleReference;
import java.lang.module.ModuleReader;
import java.lang.reflect.InvocationTargetException;
import java.security.AccessController;
import java.security.CodeSigner;
import java.security.CodeSource;
@ -549,7 +550,8 @@ public final class TemplatesImpl implements Templates, Serializable {
// The translet needs to keep a reference to all its auxiliary
// class to prevent the GC from collecting them
AbstractTranslet translet = (AbstractTranslet) _class[_transletIndex].newInstance();
AbstractTranslet translet = (AbstractTranslet)
_class[_transletIndex].getConstructor().newInstance();
translet.postInitialization();
translet.setTemplates(this);
translet.setServicesMechnism(_useServicesMechanism);
@ -560,13 +562,10 @@ public final class TemplatesImpl implements Templates, Serializable {
return translet;
}
catch (InstantiationException e) {
catch (InstantiationException | IllegalAccessException |
NoSuchMethodException | InvocationTargetException e) {
ErrorMsg err = new ErrorMsg(ErrorMsg.TRANSLET_OBJECT_ERR, _name);
throw new TransformerConfigurationException(err.toString());
}
catch (IllegalAccessException e) {
ErrorMsg err = new ErrorMsg(ErrorMsg.TRANSLET_OBJECT_ERR, _name);
throw new TransformerConfigurationException(err.toString());
throw new TransformerConfigurationException(err.toString(), e);
}
}

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -49,6 +48,7 @@ import org.xml.sax.helpers.XMLReaderFactory;
* @author Santiago Pericas-Geertsen
* @author G. Todd Miller
*/
@SuppressWarnings("deprecation") //org.xml.sax.helpers.XMLReaderFactory
public class TrAXFilter extends XMLFilterImpl {
private Templates _templates;
private TransformerImpl _transformer;

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -55,6 +55,7 @@ import org.xml.sax.helpers.XMLReaderFactory;
*
* Added Catalog Support for URI resolution
*/
@SuppressWarnings("deprecation") //org.xml.sax.helpers.XMLReaderFactory
public final class Util {
public static String baseName(String name) {

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -25,9 +24,7 @@ import com.sun.org.apache.xerces.internal.parsers.DOMParserImpl;
import com.sun.org.apache.xerces.internal.parsers.DTDConfiguration;
import com.sun.org.apache.xerces.internal.parsers.XIncludeAwareParserConfiguration;
import com.sun.org.apache.xerces.internal.util.XMLChar;
import com.sun.org.apache.xerces.internal.utils.ObjectFactory;
import com.sun.org.apache.xerces.internal.xni.grammars.XMLGrammarDescription;
import com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl;
import org.w3c.dom.DOMException;
import org.w3c.dom.DOMImplementation;
import org.w3c.dom.Document;
@ -345,13 +342,7 @@ public class CoreDOMImplementationImpl
* reference to the default error handler.
*/
public LSSerializer createLSSerializer() {
try {
return new com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl();
}
catch (Exception e) {}
// Fall back to Xerces' deprecated serializer if
// the Xalan based serializer is unavailable.
return new DOMSerializerImpl();
return new com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl();
}
/**

View File

@ -1473,12 +1473,12 @@ public class CoreDocumentImpl
if (nodeTable == null) {
nodeTable = new HashMap<>();
num = --nodeCounter;
nodeTable.put(node, new Integer(num));
nodeTable.put(node, num);
} else {
Integer n = (Integer) nodeTable.get(node);
if (n == null) {
num = --nodeCounter;
nodeTable.put(node, new Integer(num));
nodeTable.put(node, num);
} else {
num = n.intValue();
}

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -1831,7 +1830,7 @@ public class DOMNormalizer implements XMLDocumentHandler {
// flag to "true" which may overwrite a "false"
// value from the attribute list.
boolean specified = attr.getSpecified();
attr.setValue(attrPSVI.getSchemaNormalizedValue());
attr.setValue(attrPSVI.getSchemaValue().getNormalizedValue());
if (!specified) {
((AttrImpl) attr).setSpecified(specified);
}
@ -1972,7 +1971,7 @@ public class DOMNormalizer implements XMLDocumentHandler {
((PSVIElementNSImpl) fCurrentNode).setPSVI(elementPSVI);
}
// include element default content (if one is available)
String normalizedValue = elementPSVI.getSchemaNormalizedValue();
String normalizedValue = elementPSVI.getSchemaValue().getNormalizedValue();
if ((fConfiguration.features & DOMConfigurationImpl.DTNORMALIZATION) != 0) {
if (normalizedValue !=null)
elementNode.setTextContent(normalizedValue);

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -472,42 +472,6 @@ public class DeferredDocumentImpl
return attrNodeIndex;
}
/**
* Sets an attribute on an element node.
* @deprecated
*/
@Deprecated
public int setDeferredAttribute(int elementNodeIndex,
String attrName, String attrURI,
String attrValue, boolean specified) {
// create attribute
int attrNodeIndex = createDeferredAttribute(attrName, attrURI,
attrValue, specified);
int attrChunk = attrNodeIndex >> CHUNK_SHIFT;
int attrIndex = attrNodeIndex & CHUNK_MASK;
// set attribute's parent to element
setChunkIndex(fNodeParent, elementNodeIndex, attrChunk, attrIndex);
int elementChunk = elementNodeIndex >> CHUNK_SHIFT;
int elementIndex = elementNodeIndex & CHUNK_MASK;
// get element's last attribute
int lastAttrNodeIndex = getChunkIndex(fNodeExtra,
elementChunk, elementIndex);
if (lastAttrNodeIndex != 0) {
// add link from new attribute to last attribute
setChunkIndex(fNodePrevSib, lastAttrNodeIndex,
attrChunk, attrIndex);
}
// add link from element to new last attribute
setChunkIndex(fNodeExtra, attrNodeIndex,
elementChunk, elementIndex);
// return node index
return attrNodeIndex;
} // setDeferredAttribute(int,String,String,String,boolean):int
/** Creates an attribute in the table. */
public int createDeferredAttribute(String attrName, String attrValue,
boolean specified) {

View File

@ -1,3 +1,6 @@
/*
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
@ -108,6 +111,7 @@ public class PSVIAttrNSImpl extends AttrNSImpl implements AttributePSVI {
* @return The canonical lexical representation of the declaration's {value constraint} value.
* @see <a href="http://www.w3.org/TR/xmlschema-1/#e-schema_default>XML Schema Part 1: Structures [schema default]</a>
*/
@SuppressWarnings("deprecation")
public String getSchemaDefault() {
return fDeclaration == null ? null : fDeclaration.getConstraintValue();
}
@ -119,6 +123,7 @@ public class PSVIAttrNSImpl extends AttrNSImpl implements AttributePSVI {
* @see <a href="http://www.w3.org/TR/xmlschema-1/#e-schema_normalized_value>XML Schema Part 1: Structures [schema normalized value]</a>
* @return the normalized value of this item after validation
*/
@Deprecated
public String getSchemaNormalizedValue() {
return fValue.getNormalizedValue();
}
@ -237,6 +242,7 @@ public class PSVIAttrNSImpl extends AttrNSImpl implements AttributePSVI {
/* (non-Javadoc)
* @see com.sun.org.apache.xerces.internal.xs.ItemPSVI#getActualNormalizedValue()
*/
@Deprecated
public Object getActualNormalizedValue() {
return fValue.getActualValue();
}
@ -244,6 +250,7 @@ public class PSVIAttrNSImpl extends AttrNSImpl implements AttributePSVI {
/* (non-Javadoc)
* @see com.sun.org.apache.xerces.internal.xs.ItemPSVI#getActualNormalizedValueType()
*/
@Deprecated
public short getActualNormalizedValueType() {
return fValue.getActualValueType();
}
@ -251,6 +258,7 @@ public class PSVIAttrNSImpl extends AttrNSImpl implements AttributePSVI {
/* (non-Javadoc)
* @see com.sun.org.apache.xerces.internal.xs.ItemPSVI#getItemValueTypes()
*/
@Deprecated
public ShortList getItemValueTypes() {
return fValue.getListValueTypes();
}

View File

@ -1,3 +1,6 @@
/*
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
@ -119,6 +122,7 @@ public class PSVIElementNSImpl extends ElementNSImpl implements ElementPSVI {
* @return The canonical lexical representation of the declaration's {value constraint} value.
* @see <a href="http://www.w3.org/TR/xmlschema-1/#e-schema_default>XML Schema Part 1: Structures [schema default]</a>
*/
@SuppressWarnings("deprecation")
public String getSchemaDefault() {
return fDeclaration == null ? null : fDeclaration.getConstraintValue();
}
@ -130,6 +134,7 @@ public class PSVIElementNSImpl extends ElementNSImpl implements ElementPSVI {
* @see <a href="http://www.w3.org/TR/xmlschema-1/#e-schema_normalized_value>XML Schema Part 1: Structures [schema normalized value]</a>
* @return the normalized value of this item after validation
*/
@Deprecated
public String getSchemaNormalizedValue() {
return fValue.getNormalizedValue();
}
@ -285,6 +290,7 @@ public class PSVIElementNSImpl extends ElementNSImpl implements ElementPSVI {
/* (non-Javadoc)
* @see com.sun.org.apache.xerces.internal.xs.ItemPSVI#getActualNormalizedValue()
*/
@Deprecated
public Object getActualNormalizedValue() {
return fValue.getActualValue();
}
@ -292,6 +298,7 @@ public class PSVIElementNSImpl extends ElementNSImpl implements ElementPSVI {
/* (non-Javadoc)
* @see com.sun.org.apache.xerces.internal.xs.ItemPSVI#getActualNormalizedValueType()
*/
@Deprecated
public short getActualNormalizedValueType() {
return fValue.getActualValueType();
}
@ -299,6 +306,7 @@ public class PSVIElementNSImpl extends ElementNSImpl implements ElementPSVI {
/* (non-Javadoc)
* @see com.sun.org.apache.xerces.internal.xs.ItemPSVI#getItemValueTypes()
*/
@Deprecated
public ShortList getItemValueTypes() {
return fValue.getListValueTypes();
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -201,7 +201,7 @@ public class XML11NSDocumentScannerImpl extends XML11DocumentScannerImpl {
fAttributes.getLength() > fElementAttributeLimit){
fErrorReporter.reportError(XMLMessageFormatter.XML_DOMAIN,
"ElementAttributeLimit",
new Object[]{rawname, new Integer(fElementAttributeLimit) },
new Object[]{rawname, fElementAttributeLimit },
XMLErrorReporter.SEVERITY_FATAL_ERROR );
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -2427,11 +2427,11 @@ public class XMLEntityManager implements XMLComponent, XMLEntityResolver {
int b1 = b4[1] & 0xFF;
if (b0 == 0xFE && b1 == 0xFF) {
// UTF-16, big-endian
return new Object [] {"UTF-16BE", new Boolean(true)};
return new Object [] {"UTF-16BE", true};
}
if (b0 == 0xFF && b1 == 0xFE) {
// UTF-16, little-endian
return new Object [] {"UTF-16LE", new Boolean(false)};
return new Object [] {"UTF-16LE", false};
}
// default to UTF-8 if we don't have enough bytes to make a
@ -2456,11 +2456,11 @@ public class XMLEntityManager implements XMLComponent, XMLEntityResolver {
int b3 = b4[3] & 0xFF;
if (b0 == 0x00 && b1 == 0x00 && b2 == 0x00 && b3 == 0x3C) {
// UCS-4, big endian (1234)
return new Object [] {"ISO-10646-UCS-4", new Boolean(true)};
return new Object [] {"ISO-10646-UCS-4", true};
}
if (b0 == 0x3C && b1 == 0x00 && b2 == 0x00 && b3 == 0x00) {
// UCS-4, little endian (4321)
return new Object [] {"ISO-10646-UCS-4", new Boolean(false)};
return new Object [] {"ISO-10646-UCS-4", false};
}
if (b0 == 0x00 && b1 == 0x00 && b2 == 0x3C && b3 == 0x00) {
// UCS-4, unusual octet order (2143)
@ -2476,12 +2476,12 @@ public class XMLEntityManager implements XMLComponent, XMLEntityResolver {
// UTF-16, big-endian, no BOM
// (or could turn out to be UCS-2...
// REVISIT: What should this be?
return new Object [] {"UTF-16BE", new Boolean(true)};
return new Object [] {"UTF-16BE", true};
}
if (b0 == 0x3C && b1 == 0x00 && b2 == 0x3F && b3 == 0x00) {
// UTF-16, little-endian, no BOM
// (or could turn out to be UCS-2...
return new Object [] {"UTF-16LE", new Boolean(false)};
return new Object [] {"UTF-16LE", false};
}
if (b0 == 0x4C && b1 == 0x6F && b2 == 0xA7 && b3 == 0x94) {
// EBCDIC

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2003, 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
@ -2085,11 +2085,11 @@ public class XMLEntityScanner implements XMLLocator {
int b1 = b4[1] & 0xFF;
if (b0 == 0xFE && b1 == 0xFF) {
// UTF-16, big-endian
return new Object [] {"UTF-16BE", new Boolean(true)};
return new Object [] {"UTF-16BE", true};
}
if (b0 == 0xFF && b1 == 0xFE) {
// UTF-16, little-endian
return new Object [] {"UTF-16LE", new Boolean(false)};
return new Object [] {"UTF-16LE", false};
}
// default to UTF-8 if we don't have enough bytes to make a
@ -2114,11 +2114,11 @@ public class XMLEntityScanner implements XMLLocator {
int b3 = b4[3] & 0xFF;
if (b0 == 0x00 && b1 == 0x00 && b2 == 0x00 && b3 == 0x3C) {
// UCS-4, big endian (1234)
return new Object [] {"ISO-10646-UCS-4", new Boolean(true)};
return new Object [] {"ISO-10646-UCS-4", true};
}
if (b0 == 0x3C && b1 == 0x00 && b2 == 0x00 && b3 == 0x00) {
// UCS-4, little endian (4321)
return new Object [] {"ISO-10646-UCS-4", new Boolean(false)};
return new Object [] {"ISO-10646-UCS-4", false};
}
if (b0 == 0x00 && b1 == 0x00 && b2 == 0x3C && b3 == 0x00) {
// UCS-4, unusual octet order (2143)
@ -2134,12 +2134,12 @@ public class XMLEntityScanner implements XMLLocator {
// UTF-16, big-endian, no BOM
// (or could turn out to be UCS-2...
// REVISIT: What should this be?
return new Object [] {"UTF-16BE", new Boolean(true)};
return new Object [] {"UTF-16BE", true};
}
if (b0 == 0x3C && b1 == 0x00 && b2 == 0x3F && b3 == 0x00) {
// UTF-16, little-endian, no BOM
// (or could turn out to be UCS-2...
return new Object [] {"UTF-16LE", new Boolean(false)};
return new Object [] {"UTF-16LE", false};
}
if (b0 == 0x4C && b1 == 0x6F && b2 == 0xA7 && b3 == 0x94) {
// EBCDIC

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -108,7 +107,7 @@ public class CMAny
public String toString()
{
StringBuffer strRet = new StringBuffer();
StringBuilder strRet = new StringBuilder();
strRet.append("(");
strRet.append("##any:uri=");
strRet.append(fURI);
@ -118,7 +117,7 @@ public class CMAny
strRet.append
(
" (Pos:"
+ new Integer(fPosition).toString()
+ fPosition
+ ")"
);
}

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -101,7 +100,7 @@ public class CMLeaf
public String toString()
{
StringBuffer strRet = new StringBuffer(fElement.toString());
StringBuilder strRet = new StringBuilder(fElement.toString());
strRet.append(" (");
strRet.append(fElement.uri);
strRet.append(',');
@ -112,7 +111,7 @@ public class CMLeaf
strRet.append
(
" (Pos:"
+ new Integer(fPosition).toString()
+ fPosition
+ ")"
);
}

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -684,7 +683,7 @@ public class DFAContentModel
fTransTable[curState] = makeDefStateList();
/* Optimization(Jan, 2001) */
stateTable.put(newSet, new Integer(curState));
stateTable.put(newSet, curState);
/* Optimization(Jan, 2001) */
// We now have a new state to do so bump the count

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -96,7 +95,7 @@ public class ByteListImpl extends AbstractList implements ByteList {
public Object get(int index) {
if (index >= 0 && index < data.length) {
return new Byte(data[index]);
return data[index];
}
throw new IndexOutOfBoundsException("Index: " + index);
}

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -129,6 +128,7 @@ public class AttributePSVImpl implements AttributePSVI {
* @return The canonical lexical representation of the declaration's {value constraint} value.
* @see <a href="http://www.w3.org/TR/xmlschema-1/#e-schema_default>XML Schema Part 1: Structures [schema default]</a>
*/
@SuppressWarnings("deprecation")
public String getSchemaDefault() {
return fDeclaration == null ? null : fDeclaration.getConstraintValue();
}
@ -140,6 +140,7 @@ public class AttributePSVImpl implements AttributePSVI {
* @see <a href="http://www.w3.org/TR/xmlschema-1/#e-schema_normalized_value>XML Schema Part 1: Structures [schema normalized value]</a>
* @return the normalized value of this item after validation
*/
@Deprecated
public String getSchemaNormalizedValue() {
return fValue.getNormalizedValue();
}
@ -241,6 +242,7 @@ public class AttributePSVImpl implements AttributePSVI {
/* (non-Javadoc)
* @see com.sun.org.apache.xerces.internal.xs.ItemPSVI#getActualNormalizedValue()
*/
@Deprecated
public Object getActualNormalizedValue() {
return fValue.getActualValue();
}
@ -248,6 +250,7 @@ public class AttributePSVImpl implements AttributePSVI {
/* (non-Javadoc)
* @see com.sun.org.apache.xerces.internal.xs.ItemPSVI#getActualNormalizedValueType()
*/
@Deprecated
public short getActualNormalizedValueType() {
return fValue.getActualValueType();
}
@ -255,6 +258,7 @@ public class AttributePSVImpl implements AttributePSVI {
/* (non-Javadoc)
* @see com.sun.org.apache.xerces.internal.xs.ItemPSVI#getItemValueTypes()
*/
@Deprecated
public ShortList getItemValueTypes() {
return fValue.getListValueTypes();
}

View File

@ -1,6 +1,5 @@
/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
*/
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
@ -154,6 +153,7 @@ public class ElementPSVImpl implements ElementPSVI {
* @return The canonical lexical representation of the declaration's {value constraint} value.
* @see <a href="http://www.w3.org/TR/xmlschema-1/#e-schema_default>XML Schema Part 1: Structures [schema default]</a>
*/
@SuppressWarnings("deprecation")
public String getSchemaDefault() {
return fDeclaration == null ? null : fDeclaration.getConstraintValue();
}
@ -165,6 +165,7 @@ public class ElementPSVImpl implements ElementPSVI {
* @see <a href="http://www.w3.org/TR/xmlschema-1/#e-schema_normalized_value>XML Schema Part 1: Structures [schema normalized value]</a>
* @return the normalized value of this item after validation
*/
@Deprecated
public String getSchemaNormalizedValue() {
return fValue.getNormalizedValue();
}
@ -296,6 +297,7 @@ public class ElementPSVImpl implements ElementPSVI {
/* (non-Javadoc)
* @see com.sun.org.apache.xerces.internal.xs.ItemPSVI#getActualNormalizedValue()
*/
@Deprecated
public Object getActualNormalizedValue() {
return fValue.getActualValue();
}
@ -303,6 +305,7 @@ public class ElementPSVImpl implements ElementPSVI {
/* (non-Javadoc)
* @see com.sun.org.apache.xerces.internal.xs.ItemPSVI#getActualNormalizedValueType()
*/
@Deprecated
public short getActualNormalizedValueType() {
return fValue.getActualValueType();
}
@ -310,6 +313,7 @@ public class ElementPSVImpl implements ElementPSVI {
/* (non-Javadoc)
* @see com.sun.org.apache.xerces.internal.xs.ItemPSVI#getItemValueTypes()
*/
@Deprecated
public ShortList getItemValueTypes() {
return fValue.getListValueTypes();
}

Some files were not shown because too many files have changed in this diff Show More