mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-19 18:44:38 +02:00
Merge
This commit is contained in:
commit
9a4fe1d38e
1772 changed files with 55322 additions and 21782 deletions
4
.hgtags
4
.hgtags
|
@ -228,3 +228,7 @@ bbe43d712fe08e650808d774861b256ccb34e500 jdk8-b102
|
||||||
b5ed503c26ad38869c247c5e32debec217fd056b jdk8-b104
|
b5ed503c26ad38869c247c5e32debec217fd056b jdk8-b104
|
||||||
589f4fdc584e373a47cde0162e9eceec9165c381 jdk8-b105
|
589f4fdc584e373a47cde0162e9eceec9165c381 jdk8-b105
|
||||||
514b0b69fb9683ef52062fd962a3e0644431f64d jdk8-b106
|
514b0b69fb9683ef52062fd962a3e0644431f64d jdk8-b106
|
||||||
|
892889f445755790ae90e61775bfb59ddc6182b5 jdk8-b107
|
||||||
|
74049f7a28b48c14910106a75d9f2504169c352e jdk8-b108
|
||||||
|
af9a674e12a16da1a4bd53e4990ddb1121a21ef1 jdk8-b109
|
||||||
|
b5d2bf482a3ea1cca08c994512804ffbc73de0a1 jdk8-b110
|
||||||
|
|
|
@ -228,3 +228,7 @@ b7e64be81c8a7690703df5711f4fc2375da8a9cb jdk8-b103
|
||||||
96c1b9b7524b52c3fcefc90ffad4c767396727c8 jdk8-b104
|
96c1b9b7524b52c3fcefc90ffad4c767396727c8 jdk8-b104
|
||||||
5166118c59178b5d31001bc4058e92486ee07d9b jdk8-b105
|
5166118c59178b5d31001bc4058e92486ee07d9b jdk8-b105
|
||||||
8e7b4d9fb00fdf1334376aeac050c9bca6d1b383 jdk8-b106
|
8e7b4d9fb00fdf1334376aeac050c9bca6d1b383 jdk8-b106
|
||||||
|
0874bb4707b723d5bb108d379c557cf41529d1a7 jdk8-b107
|
||||||
|
9286a6e61291246d88af713f1ef79adeea30fe2e jdk8-b108
|
||||||
|
91f47e8da5c60de58ed195e9b57f3bf192a18f83 jdk8-b109
|
||||||
|
4faa09c7fe555de086dd9048d3c5cc92317d6f45 jdk8-b110
|
||||||
|
|
12
Makefile
12
Makefile
|
@ -404,7 +404,6 @@ COMPILER_PATH.desc = Compiler install directory
|
||||||
CACERTS_FILE.desc = Location of certificates file
|
CACERTS_FILE.desc = Location of certificates file
|
||||||
DEVTOOLS_PATH.desc = Directory containing zip and gnumake
|
DEVTOOLS_PATH.desc = Directory containing zip and gnumake
|
||||||
CUPS_HEADERS_PATH.desc = Include directory location for CUPS header files
|
CUPS_HEADERS_PATH.desc = Include directory location for CUPS header files
|
||||||
DXSDK_PATH.desc = Root directory of DirectX SDK
|
|
||||||
|
|
||||||
# Make variables to print out (description and value)
|
# Make variables to print out (description and value)
|
||||||
VARIABLE_PRINTVAL_LIST += \
|
VARIABLE_PRINTVAL_LIST += \
|
||||||
|
@ -429,17 +428,6 @@ VARIABLE_CHECKDIR_LIST += \
|
||||||
VARIABLE_CHECKFIL_LIST += \
|
VARIABLE_CHECKFIL_LIST += \
|
||||||
CACERTS_FILE
|
CACERTS_FILE
|
||||||
|
|
||||||
# Some are windows specific
|
|
||||||
ifeq ($(PLATFORM), windows)
|
|
||||||
|
|
||||||
VARIABLE_PRINTVAL_LIST += \
|
|
||||||
DXSDK_PATH
|
|
||||||
|
|
||||||
VARIABLE_CHECKDIR_LIST += \
|
|
||||||
DXSDK_PATH
|
|
||||||
|
|
||||||
endif
|
|
||||||
|
|
||||||
# For pattern rules below, so all are treated the same
|
# For pattern rules below, so all are treated the same
|
||||||
DO_PRINTVAL_LIST=$(VARIABLE_PRINTVAL_LIST:%=%.printval)
|
DO_PRINTVAL_LIST=$(VARIABLE_PRINTVAL_LIST:%=%.printval)
|
||||||
DO_CHECKDIR_LIST=$(VARIABLE_CHECKDIR_LIST:%=%.checkdir)
|
DO_CHECKDIR_LIST=$(VARIABLE_CHECKDIR_LIST:%=%.checkdir)
|
||||||
|
|
|
@ -66,7 +66,7 @@ else
|
||||||
else
|
else
|
||||||
# We are building multiple configurations.
|
# We are building multiple configurations.
|
||||||
# First, find out the valid targets
|
# First, find out the valid targets
|
||||||
# Run the makefile with an arbitraty SPEC using -p -q (quiet dry-run and dump rules) to find
|
# Run the makefile with an arbitrary SPEC using -p -q (quiet dry-run and dump rules) to find
|
||||||
# available PHONY targets. Use this list as valid targets to pass on to the repeated calls.
|
# available PHONY targets. Use this list as valid targets to pass on to the repeated calls.
|
||||||
all_phony_targets=$(filter-out $(global_targets) bundles-only, $(strip $(shell \
|
all_phony_targets=$(filter-out $(global_targets) bundles-only, $(strip $(shell \
|
||||||
$(MAKE) -p -q -f common/makefiles/Main.gmk FRC SPEC=$(firstword $(SPEC)) | \
|
$(MAKE) -p -q -f common/makefiles/Main.gmk FRC SPEC=$(firstword $(SPEC)) | \
|
||||||
|
|
|
@ -444,10 +444,6 @@
|
||||||
Install
|
Install
|
||||||
<a href="#vs2010">Visual Studio 2010</a>
|
<a href="#vs2010">Visual Studio 2010</a>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
|
||||||
Install the
|
|
||||||
<a href="#dxsdk">Microsoft DirectX SDK</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
</ul>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
|
@ -971,25 +967,6 @@
|
||||||
developer install location
|
developer install location
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
|
||||||
<td><b><code>--with-dxsdk=</code></b><i>path</i></td>
|
|
||||||
<td>
|
|
||||||
select location of the Windows Direct X SDK install
|
|
||||||
<br>
|
|
||||||
The <a name="dxsdk">Microsoft DirectX 9.0 SDK</a>
|
|
||||||
header files and libraries
|
|
||||||
from the Summer 2004 edition
|
|
||||||
are required for building OpenJDK.
|
|
||||||
This SDK can be downloaded from
|
|
||||||
<a href="http://www.microsoft.com/downloads/details.aspx?FamilyId=FD044A42-9912-42A3-9A9E-D857199F888E&displaylang=en" target="_blank">
|
|
||||||
Microsoft DirectX 9.0 SDK (Summer 2004)</a>.
|
|
||||||
If the link above becomes obsolete, the SDK can be found from
|
|
||||||
<a href="http://download.microsoft.com" target="_blank">the Microsoft Download Site</a>
|
|
||||||
(search with "DirectX 9.0 SDK Update Summer 2004").
|
|
||||||
Installation usually will set the environment variable
|
|
||||||
<code>DXSDK_DIR</code> to it's install location.
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
<tr>
|
||||||
<td><b><code>--with-freetype=</code></b><i>path</i></td>
|
<td><b><code>--with-freetype=</code></b><i>path</i></td>
|
||||||
<td>
|
<td>
|
||||||
|
|
|
@ -203,6 +203,15 @@ AC_DEFUN([BASIC_REMOVE_SYMBOLIC_LINKS],
|
||||||
fi
|
fi
|
||||||
])
|
])
|
||||||
|
|
||||||
|
# Register a --with argument but mark it as deprecated
|
||||||
|
# $1: The name of the with argument to deprecate, not including --with-
|
||||||
|
AC_DEFUN([BASIC_DEPRECATED_ARG_WITH],
|
||||||
|
[
|
||||||
|
AC_ARG_WITH($1, [AS_HELP_STRING([--with-$1],
|
||||||
|
[Deprecated. Option is kept for backwards compatibility and is ignored])],
|
||||||
|
[AC_MSG_WARN([Option --with-$1 is deprecated and will be ignored.])])
|
||||||
|
])
|
||||||
|
|
||||||
AC_DEFUN_ONCE([BASIC_INIT],
|
AC_DEFUN_ONCE([BASIC_INIT],
|
||||||
[
|
[
|
||||||
# Save the original command line. This is passed to us by the wrapper configure script.
|
# Save the original command line. This is passed to us by the wrapper configure script.
|
||||||
|
|
|
@ -211,7 +211,7 @@ AC_DEFUN([BASIC_FIXUP_EXECUTABLE_CYGWIN],
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
|
|
@ -26,10 +26,10 @@
|
||||||
|
|
||||||
# Attempt to guess a canonical system name.
|
# Attempt to guess a canonical system name.
|
||||||
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
|
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
|
||||||
# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
|
# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
|
||||||
# Free Software Foundation, Inc.
|
# 2011, 2012 Free Software Foundation, Inc.
|
||||||
|
|
||||||
timestamp='2008-01-23'
|
timestamp='2012-02-10'
|
||||||
|
|
||||||
# This file is free software; you can redistribute it and/or modify it
|
# This file is free software; you can redistribute it and/or modify it
|
||||||
# under the terms of the GNU General Public License as published by
|
# under the terms of the GNU General Public License as published by
|
||||||
|
@ -42,9 +42,7 @@ timestamp='2008-01-23'
|
||||||
# General Public License for more details.
|
# General Public License for more details.
|
||||||
#
|
#
|
||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program; if not, write to the Free Software
|
# along with this program; if not, see <http://www.gnu.org/licenses/>.
|
||||||
# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
|
|
||||||
# 02110-1301, USA.
|
|
||||||
#
|
#
|
||||||
# As a special exception to the GNU General Public License, if you
|
# As a special exception to the GNU General Public License, if you
|
||||||
# distribute this file as part of a program that contains a
|
# distribute this file as part of a program that contains a
|
||||||
|
@ -52,16 +50,16 @@ timestamp='2008-01-23'
|
||||||
# the same distribution terms that you use for the rest of that program.
|
# the same distribution terms that you use for the rest of that program.
|
||||||
|
|
||||||
|
|
||||||
# Originally written by Per Bothner <per@bothner.com>.
|
# Originally written by Per Bothner. Please send patches (context
|
||||||
# Please send patches to <config-patches@gnu.org>. Submit a context
|
# diff format) to <config-patches@gnu.org> and include a ChangeLog
|
||||||
# diff and a properly formatted ChangeLog entry.
|
# entry.
|
||||||
#
|
#
|
||||||
# This script attempts to guess a canonical system name similar to
|
# This script attempts to guess a canonical system name similar to
|
||||||
# config.sub. If it succeeds, it prints the system name on stdout, and
|
# config.sub. If it succeeds, it prints the system name on stdout, and
|
||||||
# exits with 0. Otherwise, it exits with 1.
|
# exits with 0. Otherwise, it exits with 1.
|
||||||
#
|
#
|
||||||
# The plan is that this can be called by configure scripts if you
|
# You can get the latest version of this script from:
|
||||||
# don't specify an explicit build system type.
|
# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
|
||||||
|
|
||||||
me=`echo "$0" | sed -e 's,.*/,,'`
|
me=`echo "$0" | sed -e 's,.*/,,'`
|
||||||
|
|
||||||
|
@ -81,8 +79,9 @@ version="\
|
||||||
GNU config.guess ($timestamp)
|
GNU config.guess ($timestamp)
|
||||||
|
|
||||||
Originally written by Per Bothner.
|
Originally written by Per Bothner.
|
||||||
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
|
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
|
||||||
2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
|
2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012
|
||||||
|
Free Software Foundation, Inc.
|
||||||
|
|
||||||
This is free software; see the source for copying conditions. There is NO
|
This is free software; see the source for copying conditions. There is NO
|
||||||
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
|
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
|
||||||
|
@ -169,7 +168,7 @@ UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
|
||||||
case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
||||||
*:NetBSD:*:*)
|
*:NetBSD:*:*)
|
||||||
# NetBSD (nbsd) targets should (where applicable) match one or
|
# NetBSD (nbsd) targets should (where applicable) match one or
|
||||||
# more of the tupples: *-*-netbsdelf*, *-*-netbsdaout*,
|
# more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*,
|
||||||
# *-*-netbsdecoff* and *-*-netbsd*. For targets that recently
|
# *-*-netbsdecoff* and *-*-netbsd*. For targets that recently
|
||||||
# switched to ELF, *-*-netbsd* would select the old
|
# switched to ELF, *-*-netbsd* would select the old
|
||||||
# object file format. This provides both forward
|
# object file format. This provides both forward
|
||||||
|
@ -195,7 +194,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
||||||
arm*|i386|m68k|ns32k|sh3*|sparc|vax)
|
arm*|i386|m68k|ns32k|sh3*|sparc|vax)
|
||||||
eval $set_cc_for_build
|
eval $set_cc_for_build
|
||||||
if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
|
if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
|
||||||
| grep __ELF__ >/dev/null
|
| grep -q __ELF__
|
||||||
then
|
then
|
||||||
# Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout).
|
# Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout).
|
||||||
# Return netbsd for either. FIX?
|
# Return netbsd for either. FIX?
|
||||||
|
@ -205,7 +204,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
os=netbsd
|
os=netbsd
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
# The OS release
|
# The OS release
|
||||||
|
@ -248,7 +247,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
||||||
UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
|
UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
|
||||||
;;
|
;;
|
||||||
*5.*)
|
*5.*)
|
||||||
UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'`
|
UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'`
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
# According to Compaq, /usr/sbin/psrinfo has been available on
|
# According to Compaq, /usr/sbin/psrinfo has been available on
|
||||||
|
@ -294,7 +293,10 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
||||||
# A Xn.n version is an unreleased experimental baselevel.
|
# A Xn.n version is an unreleased experimental baselevel.
|
||||||
# 1.2 uses "1.2" for uname -r.
|
# 1.2 uses "1.2" for uname -r.
|
||||||
echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
|
echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
|
||||||
exit ;;
|
# Reset EXIT trap before exiting to avoid spurious non-zero exit code.
|
||||||
|
exitcode=$?
|
||||||
|
trap '' 0
|
||||||
|
exit $exitcode ;;
|
||||||
Alpha\ *:Windows_NT*:*)
|
Alpha\ *:Windows_NT*:*)
|
||||||
# How do we know it's Interix rather than the generic POSIX subsystem?
|
# How do we know it's Interix rather than the generic POSIX subsystem?
|
||||||
# Should we change UNAME_MACHINE based on the output of uname instead
|
# Should we change UNAME_MACHINE based on the output of uname instead
|
||||||
|
@ -320,7 +322,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
||||||
echo s390-ibm-zvmoe
|
echo s390-ibm-zvmoe
|
||||||
exit ;;
|
exit ;;
|
||||||
*:OS400:*:*)
|
*:OS400:*:*)
|
||||||
echo powerpc-ibm-os400
|
echo powerpc-ibm-os400
|
||||||
exit ;;
|
exit ;;
|
||||||
arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
|
arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
|
||||||
echo arm-acorn-riscix${UNAME_RELEASE}
|
echo arm-acorn-riscix${UNAME_RELEASE}
|
||||||
|
@ -349,14 +351,33 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
||||||
case `/usr/bin/uname -p` in
|
case `/usr/bin/uname -p` in
|
||||||
sparc) echo sparc-icl-nx7; exit ;;
|
sparc) echo sparc-icl-nx7; exit ;;
|
||||||
esac ;;
|
esac ;;
|
||||||
|
s390x:SunOS:*:*)
|
||||||
|
echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
|
||||||
|
exit ;;
|
||||||
sun4H:SunOS:5.*:*)
|
sun4H:SunOS:5.*:*)
|
||||||
echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
|
echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
|
||||||
exit ;;
|
exit ;;
|
||||||
sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
|
sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
|
||||||
echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
|
echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
|
||||||
exit ;;
|
exit ;;
|
||||||
|
i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*)
|
||||||
|
echo i386-pc-auroraux${UNAME_RELEASE}
|
||||||
|
exit ;;
|
||||||
i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)
|
i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)
|
||||||
echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
|
eval $set_cc_for_build
|
||||||
|
SUN_ARCH="i386"
|
||||||
|
# If there is a compiler, see if it is configured for 64-bit objects.
|
||||||
|
# Note that the Sun cc does not turn __LP64__ into 1 like gcc does.
|
||||||
|
# This test works for both compilers.
|
||||||
|
if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
|
||||||
|
if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \
|
||||||
|
(CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
|
||||||
|
grep IS_64BIT_ARCH >/dev/null
|
||||||
|
then
|
||||||
|
SUN_ARCH="x86_64"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
|
||||||
exit ;;
|
exit ;;
|
||||||
sun4*:SunOS:6*:*)
|
sun4*:SunOS:6*:*)
|
||||||
# According to config.sub, this is the proper way to canonicalize
|
# According to config.sub, this is the proper way to canonicalize
|
||||||
|
@ -400,23 +421,23 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
|
||||||
# MiNT. But MiNT is downward compatible to TOS, so this should
|
# MiNT. But MiNT is downward compatible to TOS, so this should
|
||||||
# be no problem.
|
# be no problem.
|
||||||
atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*)
|
atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*)
|
||||||
echo m68k-atari-mint${UNAME_RELEASE}
|
echo m68k-atari-mint${UNAME_RELEASE}
|
||||||
exit ;;
|
exit ;;
|
||||||
atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*)
|
atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*)
|
||||||
echo m68k-atari-mint${UNAME_RELEASE}
|
echo m68k-atari-mint${UNAME_RELEASE}
|
||||||
exit ;;
|
exit ;;
|
||||||
*falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*)
|
*falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*)
|
||||||
echo m68k-atari-mint${UNAME_RELEASE}
|
echo m68k-atari-mint${UNAME_RELEASE}
|
||||||
exit ;;
|
exit ;;
|
||||||
milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*)
|
milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*)
|
||||||
echo m68k-milan-mint${UNAME_RELEASE}
|
echo m68k-milan-mint${UNAME_RELEASE}
|
||||||
exit ;;
|
exit ;;
|
||||||
hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*)
|
hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*)
|
||||||
echo m68k-hades-mint${UNAME_RELEASE}
|
echo m68k-hades-mint${UNAME_RELEASE}
|
||||||
exit ;;
|
exit ;;
|
||||||
*:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*)
|
*:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*)
|
||||||
echo m68k-unknown-mint${UNAME_RELEASE}
|
echo m68k-unknown-mint${UNAME_RELEASE}
|
||||||
exit ;;
|
exit ;;
|
||||||
m68k:machten:*:*)
|
m68k:machten:*:*)
|
||||||
echo m68k-apple-machten${UNAME_RELEASE}
|
echo m68k-apple-machten${UNAME_RELEASE}
|
||||||
exit ;;
|
exit ;;
|
||||||
|
@ -486,8 +507,8 @@ EOF
|
||||||
echo m88k-motorola-sysv3
|
echo m88k-motorola-sysv3
|
||||||
exit ;;
|
exit ;;
|
||||||
AViiON:dgux:*:*)
|
AViiON:dgux:*:*)
|
||||||
# DG/UX returns AViiON for all architectures
|
# DG/UX returns AViiON for all architectures
|
||||||
UNAME_PROCESSOR=`/usr/bin/uname -p`
|
UNAME_PROCESSOR=`/usr/bin/uname -p`
|
||||||
if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ]
|
if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ]
|
||||||
then
|
then
|
||||||
if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \
|
if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \
|
||||||
|
@ -500,7 +521,7 @@ EOF
|
||||||
else
|
else
|
||||||
echo i586-dg-dgux${UNAME_RELEASE}
|
echo i586-dg-dgux${UNAME_RELEASE}
|
||||||
fi
|
fi
|
||||||
exit ;;
|
exit ;;
|
||||||
M88*:DolphinOS:*:*) # DolphinOS (SVR3)
|
M88*:DolphinOS:*:*) # DolphinOS (SVR3)
|
||||||
echo m88k-dolphin-sysv3
|
echo m88k-dolphin-sysv3
|
||||||
exit ;;
|
exit ;;
|
||||||
|
@ -557,7 +578,7 @@ EOF
|
||||||
echo rs6000-ibm-aix3.2
|
echo rs6000-ibm-aix3.2
|
||||||
fi
|
fi
|
||||||
exit ;;
|
exit ;;
|
||||||
*:AIX:*:[456])
|
*:AIX:*:[4567])
|
||||||
IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
|
IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
|
||||||
if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
|
if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
|
||||||
IBM_ARCH=rs6000
|
IBM_ARCH=rs6000
|
||||||
|
@ -600,52 +621,52 @@ EOF
|
||||||
9000/[678][0-9][0-9])
|
9000/[678][0-9][0-9])
|
||||||
if [ -x /usr/bin/getconf ]; then
|
if [ -x /usr/bin/getconf ]; then
|
||||||
sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null`
|
sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null`
|
||||||
sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null`
|
sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null`
|
||||||
case "${sc_cpu_version}" in
|
case "${sc_cpu_version}" in
|
||||||
523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0
|
523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0
|
||||||
528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1
|
528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1
|
||||||
532) # CPU_PA_RISC2_0
|
532) # CPU_PA_RISC2_0
|
||||||
case "${sc_kernel_bits}" in
|
case "${sc_kernel_bits}" in
|
||||||
32) HP_ARCH="hppa2.0n" ;;
|
32) HP_ARCH="hppa2.0n" ;;
|
||||||
64) HP_ARCH="hppa2.0w" ;;
|
64) HP_ARCH="hppa2.0w" ;;
|
||||||
'') HP_ARCH="hppa2.0" ;; # HP-UX 10.20
|
'') HP_ARCH="hppa2.0" ;; # HP-UX 10.20
|
||||||
esac ;;
|
esac ;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
if [ "${HP_ARCH}" = "" ]; then
|
if [ "${HP_ARCH}" = "" ]; then
|
||||||
eval $set_cc_for_build
|
eval $set_cc_for_build
|
||||||
sed 's/^ //' << EOF >$dummy.c
|
sed 's/^ //' << EOF >$dummy.c
|
||||||
|
|
||||||
#define _HPUX_SOURCE
|
#define _HPUX_SOURCE
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|
||||||
int main ()
|
int main ()
|
||||||
{
|
{
|
||||||
#if defined(_SC_KERNEL_BITS)
|
#if defined(_SC_KERNEL_BITS)
|
||||||
long bits = sysconf(_SC_KERNEL_BITS);
|
long bits = sysconf(_SC_KERNEL_BITS);
|
||||||
#endif
|
#endif
|
||||||
long cpu = sysconf (_SC_CPU_VERSION);
|
long cpu = sysconf (_SC_CPU_VERSION);
|
||||||
|
|
||||||
switch (cpu)
|
switch (cpu)
|
||||||
{
|
{
|
||||||
case CPU_PA_RISC1_0: puts ("hppa1.0"); break;
|
case CPU_PA_RISC1_0: puts ("hppa1.0"); break;
|
||||||
case CPU_PA_RISC1_1: puts ("hppa1.1"); break;
|
case CPU_PA_RISC1_1: puts ("hppa1.1"); break;
|
||||||
case CPU_PA_RISC2_0:
|
case CPU_PA_RISC2_0:
|
||||||
#if defined(_SC_KERNEL_BITS)
|
#if defined(_SC_KERNEL_BITS)
|
||||||
switch (bits)
|
switch (bits)
|
||||||
{
|
{
|
||||||
case 64: puts ("hppa2.0w"); break;
|
case 64: puts ("hppa2.0w"); break;
|
||||||
case 32: puts ("hppa2.0n"); break;
|
case 32: puts ("hppa2.0n"); break;
|
||||||
default: puts ("hppa2.0"); break;
|
default: puts ("hppa2.0"); break;
|
||||||
} break;
|
} break;
|
||||||
#else /* !defined(_SC_KERNEL_BITS) */
|
#else /* !defined(_SC_KERNEL_BITS) */
|
||||||
puts ("hppa2.0"); break;
|
puts ("hppa2.0"); break;
|
||||||
#endif
|
#endif
|
||||||
default: puts ("hppa1.0"); break;
|
default: puts ("hppa1.0"); break;
|
||||||
}
|
}
|
||||||
exit (0);
|
exit (0);
|
||||||
}
|
}
|
||||||
EOF
|
EOF
|
||||||
(CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy`
|
(CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy`
|
||||||
test -z "$HP_ARCH" && HP_ARCH=hppa
|
test -z "$HP_ARCH" && HP_ARCH=hppa
|
||||||
|
@ -665,7 +686,7 @@ EOF
|
||||||
# => hppa64-hp-hpux11.23
|
# => hppa64-hp-hpux11.23
|
||||||
|
|
||||||
if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) |
|
if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) |
|
||||||
grep __LP64__ >/dev/null
|
grep -q __LP64__
|
||||||
then
|
then
|
||||||
HP_ARCH="hppa2.0w"
|
HP_ARCH="hppa2.0w"
|
||||||
else
|
else
|
||||||
|
@ -736,22 +757,22 @@ EOF
|
||||||
exit ;;
|
exit ;;
|
||||||
C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*)
|
C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*)
|
||||||
echo c1-convex-bsd
|
echo c1-convex-bsd
|
||||||
exit ;;
|
exit ;;
|
||||||
C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*)
|
C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*)
|
||||||
if getsysinfo -f scalar_acc
|
if getsysinfo -f scalar_acc
|
||||||
then echo c32-convex-bsd
|
then echo c32-convex-bsd
|
||||||
else echo c2-convex-bsd
|
else echo c2-convex-bsd
|
||||||
fi
|
fi
|
||||||
exit ;;
|
exit ;;
|
||||||
C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*)
|
C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*)
|
||||||
echo c34-convex-bsd
|
echo c34-convex-bsd
|
||||||
exit ;;
|
exit ;;
|
||||||
C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*)
|
C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*)
|
||||||
echo c38-convex-bsd
|
echo c38-convex-bsd
|
||||||
exit ;;
|
exit ;;
|
||||||
C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*)
|
C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*)
|
||||||
echo c4-convex-bsd
|
echo c4-convex-bsd
|
||||||
exit ;;
|
exit ;;
|
||||||
CRAY*Y-MP:*:*:*)
|
CRAY*Y-MP:*:*:*)
|
||||||
echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
|
echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
|
||||||
exit ;;
|
exit ;;
|
||||||
|
@ -775,14 +796,14 @@ EOF
|
||||||
exit ;;
|
exit ;;
|
||||||
F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*)
|
F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*)
|
||||||
FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
|
FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
|
||||||
FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
|
FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
|
||||||
FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
|
FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
|
||||||
echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
|
echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
|
||||||
exit ;;
|
exit ;;
|
||||||
5000:UNIX_System_V:4.*:*)
|
5000:UNIX_System_V:4.*:*)
|
||||||
FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
|
FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
|
||||||
FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'`
|
FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'`
|
||||||
echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
|
echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
|
||||||
exit ;;
|
exit ;;
|
||||||
i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
|
i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
|
||||||
echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE}
|
echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE}
|
||||||
|
@ -794,13 +815,12 @@ EOF
|
||||||
echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
|
echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
|
||||||
exit ;;
|
exit ;;
|
||||||
*:FreeBSD:*:*)
|
*:FreeBSD:*:*)
|
||||||
case ${UNAME_MACHINE} in
|
UNAME_PROCESSOR=`/usr/bin/uname -p`
|
||||||
pc98)
|
case ${UNAME_PROCESSOR} in
|
||||||
echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
|
|
||||||
amd64)
|
amd64)
|
||||||
echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
|
echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
|
||||||
*)
|
*)
|
||||||
echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
|
echo ${UNAME_PROCESSOR}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
|
||||||
esac
|
esac
|
||||||
exit ;;
|
exit ;;
|
||||||
i*:CYGWIN*:*)
|
i*:CYGWIN*:*)
|
||||||
|
@ -809,19 +829,22 @@ EOF
|
||||||
*:MINGW*:*)
|
*:MINGW*:*)
|
||||||
echo ${UNAME_MACHINE}-pc-mingw32
|
echo ${UNAME_MACHINE}-pc-mingw32
|
||||||
exit ;;
|
exit ;;
|
||||||
|
i*:MSYS*:*)
|
||||||
|
echo ${UNAME_MACHINE}-pc-msys
|
||||||
|
exit ;;
|
||||||
i*:windows32*:*)
|
i*:windows32*:*)
|
||||||
# uname -m includes "-pc" on this system.
|
# uname -m includes "-pc" on this system.
|
||||||
echo ${UNAME_MACHINE}-mingw32
|
echo ${UNAME_MACHINE}-mingw32
|
||||||
exit ;;
|
exit ;;
|
||||||
i*:PW*:*)
|
i*:PW*:*)
|
||||||
echo ${UNAME_MACHINE}-pc-pw32
|
echo ${UNAME_MACHINE}-pc-pw32
|
||||||
exit ;;
|
exit ;;
|
||||||
*:Interix*:[3456]*)
|
*:Interix*:*)
|
||||||
case ${UNAME_MACHINE} in
|
case ${UNAME_MACHINE} in
|
||||||
x86)
|
x86)
|
||||||
echo i586-pc-interix${UNAME_RELEASE}
|
echo i586-pc-interix${UNAME_RELEASE}
|
||||||
exit ;;
|
exit ;;
|
||||||
EM64T | authenticamd)
|
authenticamd | genuineintel | EM64T)
|
||||||
echo x86_64-unknown-interix${UNAME_RELEASE}
|
echo x86_64-unknown-interix${UNAME_RELEASE}
|
||||||
exit ;;
|
exit ;;
|
||||||
IA64)
|
IA64)
|
||||||
|
@ -831,6 +854,9 @@ EOF
|
||||||
[345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
|
[345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
|
||||||
echo i${UNAME_MACHINE}-pc-mks
|
echo i${UNAME_MACHINE}-pc-mks
|
||||||
exit ;;
|
exit ;;
|
||||||
|
8664:Windows_NT:*)
|
||||||
|
echo x86_64-pc-mks
|
||||||
|
exit ;;
|
||||||
i*:Windows_NT*:* | Pentium*:Windows_NT*:*)
|
i*:Windows_NT*:* | Pentium*:Windows_NT*:*)
|
||||||
# How do we know it's Interix rather than the generic POSIX subsystem?
|
# How do we know it's Interix rather than the generic POSIX subsystem?
|
||||||
# It also conflicts with pre-2.0 versions of AT&T UWIN. Should we
|
# It also conflicts with pre-2.0 versions of AT&T UWIN. Should we
|
||||||
|
@ -860,92 +886,13 @@ EOF
|
||||||
i*86:Minix:*:*)
|
i*86:Minix:*:*)
|
||||||
echo ${UNAME_MACHINE}-pc-minix
|
echo ${UNAME_MACHINE}-pc-minix
|
||||||
exit ;;
|
exit ;;
|
||||||
arm*:Linux:*:*)
|
aarch64:Linux:*:*)
|
||||||
eval $set_cc_for_build
|
|
||||||
if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \
|
|
||||||
| grep -q __ARM_EABI__
|
|
||||||
then
|
|
||||||
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
|
||||||
else
|
|
||||||
echo ${UNAME_MACHINE}-unknown-linux-gnueabi
|
|
||||||
fi
|
|
||||||
exit ;;
|
|
||||||
avr32*:Linux:*:*)
|
|
||||||
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
||||||
exit ;;
|
exit ;;
|
||||||
cris:Linux:*:*)
|
aarch64_be:Linux:*:*)
|
||||||
echo cris-axis-linux-gnu
|
UNAME_MACHINE=aarch64_be
|
||||||
exit ;;
|
|
||||||
crisv32:Linux:*:*)
|
|
||||||
echo crisv32-axis-linux-gnu
|
|
||||||
exit ;;
|
|
||||||
frv:Linux:*:*)
|
|
||||||
echo frv-unknown-linux-gnu
|
|
||||||
exit ;;
|
|
||||||
ia64:Linux:*:*)
|
|
||||||
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
||||||
exit ;;
|
exit ;;
|
||||||
m32r*:Linux:*:*)
|
|
||||||
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
|
||||||
exit ;;
|
|
||||||
m68*:Linux:*:*)
|
|
||||||
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
|
||||||
exit ;;
|
|
||||||
mips:Linux:*:*)
|
|
||||||
eval $set_cc_for_build
|
|
||||||
sed 's/^ //' << EOF >$dummy.c
|
|
||||||
#undef CPU
|
|
||||||
#undef mips
|
|
||||||
#undef mipsel
|
|
||||||
#if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
|
|
||||||
CPU=mipsel
|
|
||||||
#else
|
|
||||||
#if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
|
|
||||||
CPU=mips
|
|
||||||
#else
|
|
||||||
CPU=
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
EOF
|
|
||||||
eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n '
|
|
||||||
/^CPU/{
|
|
||||||
s: ::g
|
|
||||||
p
|
|
||||||
}'`"
|
|
||||||
test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
|
|
||||||
;;
|
|
||||||
mips64:Linux:*:*)
|
|
||||||
eval $set_cc_for_build
|
|
||||||
sed 's/^ //' << EOF >$dummy.c
|
|
||||||
#undef CPU
|
|
||||||
#undef mips64
|
|
||||||
#undef mips64el
|
|
||||||
#if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
|
|
||||||
CPU=mips64el
|
|
||||||
#else
|
|
||||||
#if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
|
|
||||||
CPU=mips64
|
|
||||||
#else
|
|
||||||
CPU=
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
EOF
|
|
||||||
eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n '
|
|
||||||
/^CPU/{
|
|
||||||
s: ::g
|
|
||||||
p
|
|
||||||
}'`"
|
|
||||||
test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
|
|
||||||
;;
|
|
||||||
or32:Linux:*:*)
|
|
||||||
echo or32-unknown-linux-gnu
|
|
||||||
exit ;;
|
|
||||||
ppc:Linux:*:*)
|
|
||||||
echo powerpc-unknown-linux-gnu
|
|
||||||
exit ;;
|
|
||||||
ppc64:Linux:*:*)
|
|
||||||
echo powerpc64-unknown-linux-gnu
|
|
||||||
exit ;;
|
|
||||||
alpha:Linux:*:*)
|
alpha:Linux:*:*)
|
||||||
case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
|
case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
|
||||||
EV5) UNAME_MACHINE=alphaev5 ;;
|
EV5) UNAME_MACHINE=alphaev5 ;;
|
||||||
|
@ -955,11 +902,90 @@ EOF
|
||||||
EV6) UNAME_MACHINE=alphaev6 ;;
|
EV6) UNAME_MACHINE=alphaev6 ;;
|
||||||
EV67) UNAME_MACHINE=alphaev67 ;;
|
EV67) UNAME_MACHINE=alphaev67 ;;
|
||||||
EV68*) UNAME_MACHINE=alphaev68 ;;
|
EV68*) UNAME_MACHINE=alphaev68 ;;
|
||||||
esac
|
esac
|
||||||
objdump --private-headers /bin/sh | grep ld.so.1 >/dev/null
|
objdump --private-headers /bin/sh | grep -q ld.so.1
|
||||||
if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
|
if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
|
||||||
echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
|
echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
|
||||||
exit ;;
|
exit ;;
|
||||||
|
arm*:Linux:*:*)
|
||||||
|
eval $set_cc_for_build
|
||||||
|
if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \
|
||||||
|
| grep -q __ARM_EABI__
|
||||||
|
then
|
||||||
|
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
||||||
|
else
|
||||||
|
if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \
|
||||||
|
| grep -q __ARM_PCS_VFP
|
||||||
|
then
|
||||||
|
echo ${UNAME_MACHINE}-unknown-linux-gnueabi
|
||||||
|
else
|
||||||
|
echo ${UNAME_MACHINE}-unknown-linux-gnueabihf
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
exit ;;
|
||||||
|
avr32*:Linux:*:*)
|
||||||
|
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
||||||
|
exit ;;
|
||||||
|
cris:Linux:*:*)
|
||||||
|
echo ${UNAME_MACHINE}-axis-linux-gnu
|
||||||
|
exit ;;
|
||||||
|
crisv32:Linux:*:*)
|
||||||
|
echo ${UNAME_MACHINE}-axis-linux-gnu
|
||||||
|
exit ;;
|
||||||
|
frv:Linux:*:*)
|
||||||
|
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
||||||
|
exit ;;
|
||||||
|
hexagon:Linux:*:*)
|
||||||
|
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
||||||
|
exit ;;
|
||||||
|
i*86:Linux:*:*)
|
||||||
|
LIBC=gnu
|
||||||
|
eval $set_cc_for_build
|
||||||
|
sed 's/^ //' << EOF >$dummy.c
|
||||||
|
#ifdef __dietlibc__
|
||||||
|
LIBC=dietlibc
|
||||||
|
#endif
|
||||||
|
EOF
|
||||||
|
eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'`
|
||||||
|
echo "${UNAME_MACHINE}-pc-linux-${LIBC}"
|
||||||
|
exit ;;
|
||||||
|
ia64:Linux:*:*)
|
||||||
|
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
||||||
|
exit ;;
|
||||||
|
m32r*:Linux:*:*)
|
||||||
|
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
||||||
|
exit ;;
|
||||||
|
m68*:Linux:*:*)
|
||||||
|
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
||||||
|
exit ;;
|
||||||
|
mips:Linux:*:* | mips64:Linux:*:*)
|
||||||
|
eval $set_cc_for_build
|
||||||
|
sed 's/^ //' << EOF >$dummy.c
|
||||||
|
#undef CPU
|
||||||
|
#undef ${UNAME_MACHINE}
|
||||||
|
#undef ${UNAME_MACHINE}el
|
||||||
|
#if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
|
||||||
|
CPU=${UNAME_MACHINE}el
|
||||||
|
#else
|
||||||
|
#if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
|
||||||
|
CPU=${UNAME_MACHINE}
|
||||||
|
#else
|
||||||
|
CPU=
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
EOF
|
||||||
|
eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'`
|
||||||
|
test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
|
||||||
|
;;
|
||||||
|
or32:Linux:*:*)
|
||||||
|
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
||||||
|
exit ;;
|
||||||
|
padre:Linux:*:*)
|
||||||
|
echo sparc-unknown-linux-gnu
|
||||||
|
exit ;;
|
||||||
|
parisc64:Linux:*:* | hppa64:Linux:*:*)
|
||||||
|
echo hppa64-unknown-linux-gnu
|
||||||
|
exit ;;
|
||||||
parisc:Linux:*:* | hppa:Linux:*:*)
|
parisc:Linux:*:* | hppa:Linux:*:*)
|
||||||
# Look for CPU level
|
# Look for CPU level
|
||||||
case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
|
case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
|
||||||
|
@ -968,14 +994,17 @@ EOF
|
||||||
*) echo hppa-unknown-linux-gnu ;;
|
*) echo hppa-unknown-linux-gnu ;;
|
||||||
esac
|
esac
|
||||||
exit ;;
|
exit ;;
|
||||||
parisc64:Linux:*:* | hppa64:Linux:*:*)
|
ppc64:Linux:*:*)
|
||||||
echo hppa64-unknown-linux-gnu
|
echo powerpc64-unknown-linux-gnu
|
||||||
|
exit ;;
|
||||||
|
ppc:Linux:*:*)
|
||||||
|
echo powerpc-unknown-linux-gnu
|
||||||
exit ;;
|
exit ;;
|
||||||
s390:Linux:*:* | s390x:Linux:*:*)
|
s390:Linux:*:* | s390x:Linux:*:*)
|
||||||
echo ${UNAME_MACHINE}-ibm-linux
|
echo ${UNAME_MACHINE}-ibm-linux
|
||||||
exit ;;
|
exit ;;
|
||||||
sh64*:Linux:*:*)
|
sh64*:Linux:*:*)
|
||||||
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
||||||
exit ;;
|
exit ;;
|
||||||
sh*:Linux:*:*)
|
sh*:Linux:*:*)
|
||||||
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
||||||
|
@ -983,78 +1012,18 @@ EOF
|
||||||
sparc:Linux:*:* | sparc64:Linux:*:*)
|
sparc:Linux:*:* | sparc64:Linux:*:*)
|
||||||
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
||||||
exit ;;
|
exit ;;
|
||||||
|
tile*:Linux:*:*)
|
||||||
|
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
||||||
|
exit ;;
|
||||||
vax:Linux:*:*)
|
vax:Linux:*:*)
|
||||||
echo ${UNAME_MACHINE}-dec-linux-gnu
|
echo ${UNAME_MACHINE}-dec-linux-gnu
|
||||||
exit ;;
|
exit ;;
|
||||||
x86_64:Linux:*:*)
|
x86_64:Linux:*:*)
|
||||||
echo x86_64-unknown-linux-gnu
|
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
||||||
exit ;;
|
exit ;;
|
||||||
xtensa*:Linux:*:*)
|
xtensa*:Linux:*:*)
|
||||||
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
echo ${UNAME_MACHINE}-unknown-linux-gnu
|
||||||
exit ;;
|
exit ;;
|
||||||
i*86:Linux:*:*)
|
|
||||||
# The BFD linker knows what the default object file format is, so
|
|
||||||
# first see if it will tell us. cd to the root directory to prevent
|
|
||||||
# problems with other programs or directories called `ld' in the path.
|
|
||||||
# Set LC_ALL=C to ensure ld outputs messages in English.
|
|
||||||
ld_supported_targets=`cd /; LC_ALL=C ld --help 2>&1 \
|
|
||||||
| sed -ne '/supported targets:/!d
|
|
||||||
s/[ ][ ]*/ /g
|
|
||||||
s/.*supported targets: *//
|
|
||||||
s/ .*//
|
|
||||||
p'`
|
|
||||||
case "$ld_supported_targets" in
|
|
||||||
elf32-i386)
|
|
||||||
TENTATIVE="${UNAME_MACHINE}-pc-linux-gnu"
|
|
||||||
;;
|
|
||||||
a.out-i386-linux)
|
|
||||||
echo "${UNAME_MACHINE}-pc-linux-gnuaout"
|
|
||||||
exit ;;
|
|
||||||
coff-i386)
|
|
||||||
echo "${UNAME_MACHINE}-pc-linux-gnucoff"
|
|
||||||
exit ;;
|
|
||||||
"")
|
|
||||||
# Either a pre-BFD a.out linker (linux-gnuoldld) or
|
|
||||||
# one that does not give us useful --help.
|
|
||||||
echo "${UNAME_MACHINE}-pc-linux-gnuoldld"
|
|
||||||
exit ;;
|
|
||||||
esac
|
|
||||||
# Determine whether the default compiler is a.out or elf
|
|
||||||
eval $set_cc_for_build
|
|
||||||
sed 's/^ //' << EOF >$dummy.c
|
|
||||||
#include <features.h>
|
|
||||||
#ifdef __ELF__
|
|
||||||
# ifdef __GLIBC__
|
|
||||||
# if __GLIBC__ >= 2
|
|
||||||
LIBC=gnu
|
|
||||||
# else
|
|
||||||
LIBC=gnulibc1
|
|
||||||
# endif
|
|
||||||
# else
|
|
||||||
LIBC=gnulibc1
|
|
||||||
# endif
|
|
||||||
#else
|
|
||||||
#if defined(__INTEL_COMPILER) || defined(__PGI) || defined(__SUNPRO_C) || defined(__SUNPRO_CC)
|
|
||||||
LIBC=gnu
|
|
||||||
#else
|
|
||||||
LIBC=gnuaout
|
|
||||||
#endif
|
|
||||||
#endif
|
|
||||||
#ifdef __dietlibc__
|
|
||||||
LIBC=dietlibc
|
|
||||||
#endif
|
|
||||||
EOF
|
|
||||||
eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n '
|
|
||||||
/^LIBC/{
|
|
||||||
s: ::g
|
|
||||||
p
|
|
||||||
}'`"
|
|
||||||
test x"${LIBC}" != x && {
|
|
||||||
echo "${UNAME_MACHINE}-pc-linux-${LIBC}"
|
|
||||||
exit
|
|
||||||
}
|
|
||||||
test x"${TENTATIVE}" != x && { echo "${TENTATIVE}"; exit; }
|
|
||||||
;;
|
|
||||||
i*86:DYNIX/ptx:4*:*)
|
i*86:DYNIX/ptx:4*:*)
|
||||||
# ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
|
# ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
|
||||||
# earlier versions are messed up and put the nodename in both
|
# earlier versions are messed up and put the nodename in both
|
||||||
|
@ -1062,11 +1031,11 @@ EOF
|
||||||
echo i386-sequent-sysv4
|
echo i386-sequent-sysv4
|
||||||
exit ;;
|
exit ;;
|
||||||
i*86:UNIX_SV:4.2MP:2.*)
|
i*86:UNIX_SV:4.2MP:2.*)
|
||||||
# Unixware is an offshoot of SVR4, but it has its own version
|
# Unixware is an offshoot of SVR4, but it has its own version
|
||||||
# number series starting with 2...
|
# number series starting with 2...
|
||||||
# I am not positive that other SVR4 systems won't match this,
|
# I am not positive that other SVR4 systems won't match this,
|
||||||
# I just have to hope. -- rms.
|
# I just have to hope. -- rms.
|
||||||
# Use sysv4.2uw... so that sysv4* matches it.
|
# Use sysv4.2uw... so that sysv4* matches it.
|
||||||
echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION}
|
echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION}
|
||||||
exit ;;
|
exit ;;
|
||||||
i*86:OS/2:*:*)
|
i*86:OS/2:*:*)
|
||||||
|
@ -1083,7 +1052,7 @@ EOF
|
||||||
i*86:syllable:*:*)
|
i*86:syllable:*:*)
|
||||||
echo ${UNAME_MACHINE}-pc-syllable
|
echo ${UNAME_MACHINE}-pc-syllable
|
||||||
exit ;;
|
exit ;;
|
||||||
i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*)
|
i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*)
|
||||||
echo i386-unknown-lynxos${UNAME_RELEASE}
|
echo i386-unknown-lynxos${UNAME_RELEASE}
|
||||||
exit ;;
|
exit ;;
|
||||||
i*86:*DOS:*:*)
|
i*86:*DOS:*:*)
|
||||||
|
@ -1098,7 +1067,7 @@ EOF
|
||||||
fi
|
fi
|
||||||
exit ;;
|
exit ;;
|
||||||
i*86:*:5:[678]*)
|
i*86:*:5:[678]*)
|
||||||
# UnixWare 7.x, OpenUNIX and OpenServer 6.
|
# UnixWare 7.x, OpenUNIX and OpenServer 6.
|
||||||
case `/bin/uname -X | grep "^Machine"` in
|
case `/bin/uname -X | grep "^Machine"` in
|
||||||
*486*) UNAME_MACHINE=i486 ;;
|
*486*) UNAME_MACHINE=i486 ;;
|
||||||
*Pentium) UNAME_MACHINE=i586 ;;
|
*Pentium) UNAME_MACHINE=i586 ;;
|
||||||
|
@ -1126,10 +1095,13 @@ EOF
|
||||||
exit ;;
|
exit ;;
|
||||||
pc:*:*:*)
|
pc:*:*:*)
|
||||||
# Left here for compatibility:
|
# Left here for compatibility:
|
||||||
# uname -m prints for DJGPP always 'pc', but it prints nothing about
|
# uname -m prints for DJGPP always 'pc', but it prints nothing about
|
||||||
# the processor, so we play safe by assuming i386.
|
# the processor, so we play safe by assuming i586.
|
||||||
echo i386-pc-msdosdjgpp
|
# Note: whatever this is, it MUST be the same as what config.sub
|
||||||
exit ;;
|
# prints for the "djgpp" host, or else GDB configury will decide that
|
||||||
|
# this is a cross-build.
|
||||||
|
echo i586-pc-msdosdjgpp
|
||||||
|
exit ;;
|
||||||
Intel:Mach:3*:*)
|
Intel:Mach:3*:*)
|
||||||
echo i386-pc-mach3
|
echo i386-pc-mach3
|
||||||
exit ;;
|
exit ;;
|
||||||
|
@ -1164,8 +1136,18 @@ EOF
|
||||||
/bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
|
/bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
|
||||||
&& { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
|
&& { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
|
||||||
3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
|
3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
|
||||||
/bin/uname -p 2>/dev/null | grep 86 >/dev/null \
|
/bin/uname -p 2>/dev/null | grep 86 >/dev/null \
|
||||||
&& { echo i486-ncr-sysv4; exit; } ;;
|
&& { echo i486-ncr-sysv4; exit; } ;;
|
||||||
|
NCR*:*:4.2:* | MPRAS*:*:4.2:*)
|
||||||
|
OS_REL='.3'
|
||||||
|
test -r /etc/.relid \
|
||||||
|
&& OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
|
||||||
|
/bin/uname -p 2>/dev/null | grep 86 >/dev/null \
|
||||||
|
&& { echo i486-ncr-sysv4.3${OS_REL}; exit; }
|
||||||
|
/bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
|
||||||
|
&& { echo i586-ncr-sysv4.3${OS_REL}; exit; }
|
||||||
|
/bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \
|
||||||
|
&& { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
|
||||||
m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*)
|
m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*)
|
||||||
echo m68k-unknown-lynxos${UNAME_RELEASE}
|
echo m68k-unknown-lynxos${UNAME_RELEASE}
|
||||||
exit ;;
|
exit ;;
|
||||||
|
@ -1178,7 +1160,7 @@ EOF
|
||||||
rs6000:LynxOS:2.*:*)
|
rs6000:LynxOS:2.*:*)
|
||||||
echo rs6000-unknown-lynxos${UNAME_RELEASE}
|
echo rs6000-unknown-lynxos${UNAME_RELEASE}
|
||||||
exit ;;
|
exit ;;
|
||||||
PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.0*:*)
|
PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*)
|
||||||
echo powerpc-unknown-lynxos${UNAME_RELEASE}
|
echo powerpc-unknown-lynxos${UNAME_RELEASE}
|
||||||
exit ;;
|
exit ;;
|
||||||
SM[BE]S:UNIX_SV:*:*)
|
SM[BE]S:UNIX_SV:*:*)
|
||||||
|
@ -1198,10 +1180,10 @@ EOF
|
||||||
echo ns32k-sni-sysv
|
echo ns32k-sni-sysv
|
||||||
fi
|
fi
|
||||||
exit ;;
|
exit ;;
|
||||||
PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
|
PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
|
||||||
# says <Richard.M.Bartel@ccMail.Census.GOV>
|
# says <Richard.M.Bartel@ccMail.Census.GOV>
|
||||||
echo i586-unisys-sysv4
|
echo i586-unisys-sysv4
|
||||||
exit ;;
|
exit ;;
|
||||||
*:UNIX_System_V:4*:FTX*)
|
*:UNIX_System_V:4*:FTX*)
|
||||||
# From Gerald Hewes <hewes@openmarket.com>.
|
# From Gerald Hewes <hewes@openmarket.com>.
|
||||||
# How about differentiating between stratus architectures? -djm
|
# How about differentiating between stratus architectures? -djm
|
||||||
|
@ -1227,11 +1209,11 @@ EOF
|
||||||
exit ;;
|
exit ;;
|
||||||
R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*)
|
R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*)
|
||||||
if [ -d /usr/nec ]; then
|
if [ -d /usr/nec ]; then
|
||||||
echo mips-nec-sysv${UNAME_RELEASE}
|
echo mips-nec-sysv${UNAME_RELEASE}
|
||||||
else
|
else
|
||||||
echo mips-unknown-sysv${UNAME_RELEASE}
|
echo mips-unknown-sysv${UNAME_RELEASE}
|
||||||
fi
|
fi
|
||||||
exit ;;
|
exit ;;
|
||||||
BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only.
|
BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only.
|
||||||
echo powerpc-be-beos
|
echo powerpc-be-beos
|
||||||
exit ;;
|
exit ;;
|
||||||
|
@ -1241,6 +1223,9 @@ EOF
|
||||||
BePC:BeOS:*:*) # BeOS running on Intel PC compatible.
|
BePC:BeOS:*:*) # BeOS running on Intel PC compatible.
|
||||||
echo i586-pc-beos
|
echo i586-pc-beos
|
||||||
exit ;;
|
exit ;;
|
||||||
|
BePC:Haiku:*:*) # Haiku running on Intel PC compatible.
|
||||||
|
echo i586-pc-haiku
|
||||||
|
exit ;;
|
||||||
SX-4:SUPER-UX:*:*)
|
SX-4:SUPER-UX:*:*)
|
||||||
echo sx4-nec-superux${UNAME_RELEASE}
|
echo sx4-nec-superux${UNAME_RELEASE}
|
||||||
exit ;;
|
exit ;;
|
||||||
|
@ -1267,12 +1252,17 @@ EOF
|
||||||
exit ;;
|
exit ;;
|
||||||
*:Darwin:*:*)
|
*:Darwin:*:*)
|
||||||
UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
|
UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
|
||||||
eval $set_cc_for_build
|
|
||||||
echo "int main(){}" > $dummy.c
|
|
||||||
if test "`$CC_FOR_BUILD -o $dummy $dummy.c; file $dummy | grep -c x86_64`" = 1 ; then
|
|
||||||
UNAME_PROCESSOR=x86_64
|
|
||||||
fi
|
|
||||||
case $UNAME_PROCESSOR in
|
case $UNAME_PROCESSOR in
|
||||||
|
i386)
|
||||||
|
eval $set_cc_for_build
|
||||||
|
if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
|
||||||
|
if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
|
||||||
|
(CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
|
||||||
|
grep IS_64BIT_ARCH >/dev/null
|
||||||
|
then
|
||||||
|
UNAME_PROCESSOR="x86_64"
|
||||||
|
fi
|
||||||
|
fi ;;
|
||||||
unknown) UNAME_PROCESSOR=powerpc ;;
|
unknown) UNAME_PROCESSOR=powerpc ;;
|
||||||
esac
|
esac
|
||||||
echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
|
echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
|
||||||
|
@ -1288,6 +1278,9 @@ EOF
|
||||||
*:QNX:*:4*)
|
*:QNX:*:4*)
|
||||||
echo i386-pc-qnx
|
echo i386-pc-qnx
|
||||||
exit ;;
|
exit ;;
|
||||||
|
NEO-?:NONSTOP_KERNEL:*:*)
|
||||||
|
echo neo-tandem-nsk${UNAME_RELEASE}
|
||||||
|
exit ;;
|
||||||
NSE-?:NONSTOP_KERNEL:*:*)
|
NSE-?:NONSTOP_KERNEL:*:*)
|
||||||
echo nse-tandem-nsk${UNAME_RELEASE}
|
echo nse-tandem-nsk${UNAME_RELEASE}
|
||||||
exit ;;
|
exit ;;
|
||||||
|
@ -1333,13 +1326,13 @@ EOF
|
||||||
echo pdp10-unknown-its
|
echo pdp10-unknown-its
|
||||||
exit ;;
|
exit ;;
|
||||||
SEI:*:*:SEIUX)
|
SEI:*:*:SEIUX)
|
||||||
echo mips-sei-seiux${UNAME_RELEASE}
|
echo mips-sei-seiux${UNAME_RELEASE}
|
||||||
exit ;;
|
exit ;;
|
||||||
*:DragonFly:*:*)
|
*:DragonFly:*:*)
|
||||||
echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
|
echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
|
||||||
exit ;;
|
exit ;;
|
||||||
*:*VMS:*:*)
|
*:*VMS:*:*)
|
||||||
UNAME_MACHINE=`(uname -p) 2>/dev/null`
|
UNAME_MACHINE=`(uname -p) 2>/dev/null`
|
||||||
case "${UNAME_MACHINE}" in
|
case "${UNAME_MACHINE}" in
|
||||||
A*) echo alpha-dec-vms ; exit ;;
|
A*) echo alpha-dec-vms ; exit ;;
|
||||||
I*) echo ia64-dec-vms ; exit ;;
|
I*) echo ia64-dec-vms ; exit ;;
|
||||||
|
@ -1354,6 +1347,12 @@ EOF
|
||||||
i*86:rdos:*:*)
|
i*86:rdos:*:*)
|
||||||
echo ${UNAME_MACHINE}-pc-rdos
|
echo ${UNAME_MACHINE}-pc-rdos
|
||||||
exit ;;
|
exit ;;
|
||||||
|
i*86:AROS:*:*)
|
||||||
|
echo ${UNAME_MACHINE}-pc-aros
|
||||||
|
exit ;;
|
||||||
|
x86_64:VMkernel:*:*)
|
||||||
|
echo ${UNAME_MACHINE}-unknown-esx
|
||||||
|
exit ;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
#echo '(No uname command or uname output not recognized.)' 1>&2
|
#echo '(No uname command or uname output not recognized.)' 1>&2
|
||||||
|
@ -1376,11 +1375,11 @@ main ()
|
||||||
#include <sys/param.h>
|
#include <sys/param.h>
|
||||||
printf ("m68k-sony-newsos%s\n",
|
printf ("m68k-sony-newsos%s\n",
|
||||||
#ifdef NEWSOS4
|
#ifdef NEWSOS4
|
||||||
"4"
|
"4"
|
||||||
#else
|
#else
|
||||||
""
|
""
|
||||||
#endif
|
#endif
|
||||||
); exit (0);
|
); exit (0);
|
||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
5
common/autoconf/configure
vendored
5
common/autoconf/configure
vendored
|
@ -219,9 +219,4 @@ else
|
||||||
echo configure exiting with result code $conf_result_code
|
echo configure exiting with result code $conf_result_code
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Move the log file to the output root, if this was successfully created
|
|
||||||
if test -d "$OUTPUT_ROOT"; then
|
|
||||||
mv -f config.log "$OUTPUT_ROOT" 2> /dev/null
|
|
||||||
fi
|
|
||||||
|
|
||||||
exit $conf_result_code
|
exit $conf_result_code
|
||||||
|
|
|
@ -232,9 +232,15 @@ CUSTOM_LATE_HOOK
|
||||||
# We're messing a bit with internal autoconf variables to put the config.status
|
# We're messing a bit with internal autoconf variables to put the config.status
|
||||||
# in the output directory instead of the current directory.
|
# in the output directory instead of the current directory.
|
||||||
CONFIG_STATUS="$OUTPUT_ROOT/config.status"
|
CONFIG_STATUS="$OUTPUT_ROOT/config.status"
|
||||||
|
|
||||||
# Create the actual output files. Now the main work of configure is done.
|
# Create the actual output files. Now the main work of configure is done.
|
||||||
AC_OUTPUT
|
AC_OUTPUT
|
||||||
|
|
||||||
|
# Try to move the config.log file to the output directory.
|
||||||
|
if test -e ./config.log; then
|
||||||
|
$MV -f ./config.log "$OUTPUT_ROOT/config.log" 2> /dev/null
|
||||||
|
fi
|
||||||
|
|
||||||
# Make the compare script executable
|
# Make the compare script executable
|
||||||
$CHMOD +x $OUTPUT_ROOT/compare.sh
|
$CHMOD +x $OUTPUT_ROOT/compare.sh
|
||||||
|
|
||||||
|
|
|
@ -709,7 +709,6 @@ STATIC_LIBRARY
|
||||||
SHARED_LIBRARY
|
SHARED_LIBRARY
|
||||||
OBJ_SUFFIX
|
OBJ_SUFFIX
|
||||||
COMPILER_NAME
|
COMPILER_NAME
|
||||||
TARGET_BITS_FLAG
|
|
||||||
JT_HOME
|
JT_HOME
|
||||||
JTREGEXE
|
JTREGEXE
|
||||||
LIPO
|
LIPO
|
||||||
|
@ -766,8 +765,6 @@ BUILD_LD
|
||||||
BUILD_CXX
|
BUILD_CXX
|
||||||
BUILD_CC
|
BUILD_CC
|
||||||
MSVCR_DLL
|
MSVCR_DLL
|
||||||
DXSDK_INCLUDE_PATH
|
|
||||||
DXSDK_LIB_PATH
|
|
||||||
VS_PATH
|
VS_PATH
|
||||||
VS_LIB
|
VS_LIB
|
||||||
VS_INCLUDE
|
VS_INCLUDE
|
||||||
|
@ -1019,8 +1016,8 @@ with_cacerts_file
|
||||||
enable_unlimited_crypto
|
enable_unlimited_crypto
|
||||||
with_milestone
|
with_milestone
|
||||||
with_update_version
|
with_update_version
|
||||||
with_build_number
|
|
||||||
with_user_release_suffix
|
with_user_release_suffix
|
||||||
|
with_build_number
|
||||||
with_boot_jdk
|
with_boot_jdk
|
||||||
with_boot_jdk_jvmargs
|
with_boot_jdk_jvmargs
|
||||||
with_add_source_root
|
with_add_source_root
|
||||||
|
@ -1031,6 +1028,7 @@ with_override_corba
|
||||||
with_override_jaxp
|
with_override_jaxp
|
||||||
with_override_jaxws
|
with_override_jaxws
|
||||||
with_override_hotspot
|
with_override_hotspot
|
||||||
|
with_override_nashorn
|
||||||
with_override_jdk
|
with_override_jdk
|
||||||
with_import_hotspot
|
with_import_hotspot
|
||||||
with_msvcr_dll
|
with_msvcr_dll
|
||||||
|
@ -1757,10 +1755,10 @@ Optional Packages:
|
||||||
--with-cacerts-file specify alternative cacerts file
|
--with-cacerts-file specify alternative cacerts file
|
||||||
--with-milestone Set milestone value for build [internal]
|
--with-milestone Set milestone value for build [internal]
|
||||||
--with-update-version Set update version value for build [b00]
|
--with-update-version Set update version value for build [b00]
|
||||||
--with-build-number Set build number value for build [b00]
|
|
||||||
--with-user-release-suffix
|
--with-user-release-suffix
|
||||||
Add a custom string to the version string if build
|
Add a custom string to the version string if build
|
||||||
number isn't set.[username_builddateb00]
|
number isn't set.[username_builddateb00]
|
||||||
|
--with-build-number Set build number value for build [b00]
|
||||||
--with-boot-jdk path to Boot JDK (used to bootstrap build) [probed]
|
--with-boot-jdk path to Boot JDK (used to bootstrap build) [probed]
|
||||||
--with-boot-jdk-jvmargs specify JVM arguments to be passed to all
|
--with-boot-jdk-jvmargs specify JVM arguments to be passed to all
|
||||||
invocations of the Boot JDK, overriding the default
|
invocations of the Boot JDK, overriding the default
|
||||||
|
@ -1784,17 +1782,19 @@ Optional Packages:
|
||||||
--with-override-jaxp use this jaxp dir for the build
|
--with-override-jaxp use this jaxp dir for the build
|
||||||
--with-override-jaxws use this jaxws dir for the build
|
--with-override-jaxws use this jaxws dir for the build
|
||||||
--with-override-hotspot use this hotspot dir for the build
|
--with-override-hotspot use this hotspot dir for the build
|
||||||
|
--with-override-nashorn use this nashorn dir for the build
|
||||||
--with-override-jdk use this jdk dir for the build
|
--with-override-jdk use this jdk dir for the build
|
||||||
--with-import-hotspot import hotspot binaries from this jdk image or
|
--with-import-hotspot import hotspot binaries from this jdk image or
|
||||||
hotspot build dist dir instead of building from
|
hotspot build dist dir instead of building from
|
||||||
source
|
source
|
||||||
--with-msvcr-dll copy this msvcr100.dll into the built JDK (Windows
|
--with-msvcr-dll copy this msvcr100.dll into the built JDK (Windows
|
||||||
only) [probed]
|
only) [probed]
|
||||||
--with-dxsdk the DirectX SDK (Windows only) [probed]
|
--with-dxsdk Deprecated. Option is kept for backwards
|
||||||
--with-dxsdk-lib the DirectX SDK lib directory (Windows only)
|
compatibility and is ignored
|
||||||
[probed]
|
--with-dxsdk-lib Deprecated. Option is kept for backwards
|
||||||
--with-dxsdk-include the DirectX SDK include directory (Windows only)
|
compatibility and is ignored
|
||||||
[probed]
|
--with-dxsdk-include Deprecated. Option is kept for backwards
|
||||||
|
compatibility and is ignored
|
||||||
--with-jtreg Regression Test Harness [probed]
|
--with-jtreg Regression Test Harness [probed]
|
||||||
--with-extra-cflags extra flags to be used when compiling jdk c-files
|
--with-extra-cflags extra flags to be used when compiling jdk c-files
|
||||||
--with-extra-cxxflags extra flags to be used when compiling jdk c++-files
|
--with-extra-cxxflags extra flags to be used when compiling jdk c++-files
|
||||||
|
@ -3144,6 +3144,10 @@ ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
# Register a --with argument but mark it as deprecated
|
||||||
|
# $1: The name of the with argument to deprecate, not including --with-
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Test that variable $1 denoting a program is not empty. If empty, exit with an error.
|
# Test that variable $1 denoting a program is not empty. If empty, exit with an error.
|
||||||
|
@ -3805,10 +3809,6 @@ fi
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Setup the DXSDK paths
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -3818,7 +3818,7 @@ fi
|
||||||
#CUSTOM_AUTOCONF_INCLUDE
|
#CUSTOM_AUTOCONF_INCLUDE
|
||||||
|
|
||||||
# Do not change or remove the following line, it is needed for consistency checks:
|
# Do not change or remove the following line, it is needed for consistency checks:
|
||||||
DATE_WHEN_GENERATED=1378914658
|
DATE_WHEN_GENERATED=1381162713
|
||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
#
|
#
|
||||||
|
@ -8352,7 +8352,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -8709,7 +8709,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -9063,7 +9063,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -9422,7 +9422,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -9775,7 +9775,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -10935,7 +10935,7 @@ BUILD_HEADLESS="BUILD_HEADLESS:=true"
|
||||||
|
|
||||||
if test "x$SUPPORT_HEADFUL" = xyes; then
|
if test "x$SUPPORT_HEADFUL" = xyes; then
|
||||||
# We are building both headful and headless.
|
# We are building both headful and headless.
|
||||||
headful_msg="inlude support for both headful and headless"
|
headful_msg="include support for both headful and headless"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "x$SUPPORT_HEADFUL" = xno; then
|
if test "x$SUPPORT_HEADFUL" = xno; then
|
||||||
|
@ -11048,6 +11048,18 @@ elif test "x$with_update_version" != x; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
# Check whether --with-user-release-suffix was given.
|
||||||
|
if test "${with_user_release_suffix+set}" = set; then :
|
||||||
|
withval=$with_user_release_suffix;
|
||||||
|
fi
|
||||||
|
|
||||||
|
if test "x$with_user_release_suffix" = xyes; then
|
||||||
|
as_fn_error $? "Release suffix must have a value" "$LINENO" 5
|
||||||
|
elif test "x$with_user_release_suffix" != x; then
|
||||||
|
USER_RELEASE_SUFFIX="$with_user_release_suffix"
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
# Check whether --with-build-number was given.
|
# Check whether --with-build-number was given.
|
||||||
if test "${with_build_number+set}" = set; then :
|
if test "${with_build_number+set}" = set; then :
|
||||||
withval=$with_build_number;
|
withval=$with_build_number;
|
||||||
|
@ -11058,28 +11070,17 @@ if test "x$with_build_number" = xyes; then
|
||||||
elif test "x$with_build_number" != x; then
|
elif test "x$with_build_number" != x; then
|
||||||
JDK_BUILD_NUMBER="$with_build_number"
|
JDK_BUILD_NUMBER="$with_build_number"
|
||||||
fi
|
fi
|
||||||
|
# Define default USER_RELEASE_SUFFIX if BUILD_NUMBER and USER_RELEASE_SUFFIX are not set
|
||||||
if test "x$JDK_BUILD_NUMBER" = x; then
|
if test "x$JDK_BUILD_NUMBER" = x; then
|
||||||
JDK_BUILD_NUMBER=b00
|
JDK_BUILD_NUMBER=b00
|
||||||
|
if test "x$USER_RELEASE_SUFFIX" = x; then
|
||||||
|
BUILD_DATE=`date '+%Y_%m_%d_%H_%M'`
|
||||||
|
# Avoid [:alnum:] since it depends on the locale.
|
||||||
|
CLEAN_USERNAME=`echo "$USER" | $TR -d -c 'abcdefghijklmnopqrstuvqxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'`
|
||||||
|
USER_RELEASE_SUFFIX=`echo "${CLEAN_USERNAME}_${BUILD_DATE}" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
# Check whether --with-user-release-suffix was given.
|
|
||||||
if test "${with_user_release_suffix+set}" = set; then :
|
|
||||||
withval=$with_user_release_suffix;
|
|
||||||
fi
|
|
||||||
|
|
||||||
if test "x$with_user_release_suffix" = xyes; then
|
|
||||||
as_fn_error $? "Release suffix must have a value" "$LINENO" 5
|
|
||||||
elif test "x$with_user_release_suffix" != x; then
|
|
||||||
USER_RELEASE_SUFFIX="$with_user_release_suffix"
|
|
||||||
else
|
|
||||||
BUILD_DATE=`date '+%Y_%m_%d_%H_%M'`
|
|
||||||
# Avoid [:alnum:] since it depends on the locale.
|
|
||||||
CLEAN_USERNAME=`echo "$USER" | $TR -d -c 'abcdefghijklmnopqrstuvqxyz0123456789'`
|
|
||||||
USER_RELEASE_SUFFIX=`echo "${CLEAN_USERNAME}_${BUILD_DATE}" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
# Now set the JDK version, milestone, build number etc.
|
# Now set the JDK version, milestone, build number etc.
|
||||||
|
|
||||||
|
|
||||||
|
@ -11095,6 +11096,7 @@ fi
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
COPYRIGHT_YEAR=`date +'%Y'`
|
COPYRIGHT_YEAR=`date +'%Y'`
|
||||||
|
|
||||||
|
|
||||||
|
@ -16102,6 +16104,10 @@ if test "x$with_add_source_root" != x; then
|
||||||
test -f $with_add_source_root/hotspot/make/Makefile; then
|
test -f $with_add_source_root/hotspot/make/Makefile; then
|
||||||
as_fn_error $? "Your add source root seems to contain a full hotspot repo! An add source root should only contain additional sources." "$LINENO" 5
|
as_fn_error $? "Your add source root seems to contain a full hotspot repo! An add source root should only contain additional sources." "$LINENO" 5
|
||||||
fi
|
fi
|
||||||
|
if test -f $with_add_source_root/nashorn/makefiles/Makefile || \
|
||||||
|
test -f $with_add_source_root/nashorn/make/Makefile; then
|
||||||
|
as_fn_error $? "Your add source root seems to contain a full nashorn repo! An add source root should only contain additional sources." "$LINENO" 5
|
||||||
|
fi
|
||||||
if test -f $with_add_source_root/jdk/makefiles/Makefile || \
|
if test -f $with_add_source_root/jdk/makefiles/Makefile || \
|
||||||
test -f $with_add_source_root/jdk/make/Makefile; then
|
test -f $with_add_source_root/jdk/make/Makefile; then
|
||||||
as_fn_error $? "Your add source root seems to contain a full JDK repo! An add source root should only contain additional sources." "$LINENO" 5
|
as_fn_error $? "Your add source root seems to contain a full JDK repo! An add source root should only contain additional sources." "$LINENO" 5
|
||||||
|
@ -16137,6 +16143,10 @@ if test "x$with_override_source_root" != x; then
|
||||||
test -f $with_override_source_root/hotspot/make/Makefile; then
|
test -f $with_override_source_root/hotspot/make/Makefile; then
|
||||||
as_fn_error $? "Your override source root seems to contain a full hotspot repo! An override source root should only contain sources that override." "$LINENO" 5
|
as_fn_error $? "Your override source root seems to contain a full hotspot repo! An override source root should only contain sources that override." "$LINENO" 5
|
||||||
fi
|
fi
|
||||||
|
if test -f $with_override_source_root/nashorn/makefiles/Makefile || \
|
||||||
|
test -f $with_override_source_root/nashorn/make/Makefile; then
|
||||||
|
as_fn_error $? "Your override source root seems to contain a full nashorn repo! An override source root should only contain sources that override." "$LINENO" 5
|
||||||
|
fi
|
||||||
if test -f $with_override_source_root/jdk/makefiles/Makefile || \
|
if test -f $with_override_source_root/jdk/makefiles/Makefile || \
|
||||||
test -f $with_override_source_root/jdk/make/Makefile; then
|
test -f $with_override_source_root/jdk/make/Makefile; then
|
||||||
as_fn_error $? "Your override source root seems to contain a full JDK repo! An override source root should only contain sources that override." "$LINENO" 5
|
as_fn_error $? "Your override source root seems to contain a full JDK repo! An override source root should only contain sources that override." "$LINENO" 5
|
||||||
|
@ -16199,6 +16209,13 @@ fi
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
# Check whether --with-override-nashorn was given.
|
||||||
|
if test "${with_override_nashorn+set}" = set; then :
|
||||||
|
withval=$with_override_nashorn;
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Check whether --with-override-jdk was given.
|
# Check whether --with-override-jdk was given.
|
||||||
if test "${with_override_jdk+set}" = set; then :
|
if test "${with_override_jdk+set}" = set; then :
|
||||||
withval=$with_override_jdk;
|
withval=$with_override_jdk;
|
||||||
|
@ -16276,7 +16293,7 @@ if test "x$with_override_nashorn" != x; then
|
||||||
cd "$with_override_nashorn"
|
cd "$with_override_nashorn"
|
||||||
NASHORN_TOPDIR="`pwd`"
|
NASHORN_TOPDIR="`pwd`"
|
||||||
cd "$CURDIR"
|
cd "$CURDIR"
|
||||||
if ! test -f $NASHORN_TOPDIR/makefiles/BuildNashorn.gmk; then
|
if ! test -f $NASHORN_TOPDIR/makefiles/Makefile; then
|
||||||
as_fn_error $? "You have to override nashorn with a full nashorn repo!" "$LINENO" 5
|
as_fn_error $? "You have to override nashorn with a full nashorn repo!" "$LINENO" 5
|
||||||
fi
|
fi
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if nashorn should be overridden" >&5
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if nashorn should be overridden" >&5
|
||||||
|
@ -17086,7 +17103,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -17586,437 +17603,29 @@ $as_echo "$as_me: The path of MSVCR_DLL, which resolves as \"$path\", is invalid
|
||||||
|
|
||||||
# Check whether --with-dxsdk was given.
|
# Check whether --with-dxsdk was given.
|
||||||
if test "${with_dxsdk+set}" = set; then :
|
if test "${with_dxsdk+set}" = set; then :
|
||||||
withval=$with_dxsdk;
|
withval=$with_dxsdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&5
|
||||||
|
$as_echo "$as_me: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&2;}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Check whether --with-dxsdk-lib was given.
|
# Check whether --with-dxsdk-lib was given.
|
||||||
if test "${with_dxsdk_lib+set}" = set; then :
|
if test "${with_dxsdk_lib+set}" = set; then :
|
||||||
withval=$with_dxsdk_lib;
|
withval=$with_dxsdk_lib; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&5
|
||||||
|
$as_echo "$as_me: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&2;}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Check whether --with-dxsdk-include was given.
|
# Check whether --with-dxsdk-include was given.
|
||||||
if test "${with_dxsdk_include+set}" = set; then :
|
if test "${with_dxsdk_include+set}" = set; then :
|
||||||
withval=$with_dxsdk_include;
|
withval=$with_dxsdk_include; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&5
|
||||||
|
$as_echo "$as_me: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&2;}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for DirectX SDK" >&5
|
|
||||||
$as_echo_n "checking for DirectX SDK... " >&6; }
|
|
||||||
|
|
||||||
if test "x$with_dxsdk" != x; then
|
|
||||||
dxsdk_path="$with_dxsdk"
|
|
||||||
elif test "x$DXSDK_DIR" != x; then
|
|
||||||
dxsdk_path="$DXSDK_DIR"
|
|
||||||
elif test -d "C:/DXSDK"; then
|
|
||||||
dxsdk_path="C:/DXSDK"
|
|
||||||
else
|
|
||||||
as_fn_error $? "Could not find the DirectX SDK" "$LINENO" 5
|
|
||||||
fi
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dxsdk_path" >&5
|
|
||||||
$as_echo "$dxsdk_path" >&6; }
|
|
||||||
|
|
||||||
if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
|
|
||||||
|
|
||||||
# Input might be given as Windows format, start by converting to
|
|
||||||
# unix format.
|
|
||||||
path="$dxsdk_path"
|
|
||||||
new_path=`$CYGPATH -u "$path"`
|
|
||||||
|
|
||||||
# Cygwin tries to hide some aspects of the Windows file system, such that binaries are
|
|
||||||
# named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
|
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
|
||||||
#
|
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
|
||||||
if test "x$test_shortpath" = x; then
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: The path of dxsdk_path, which resolves as \"$path\", is invalid." >&5
|
|
||||||
$as_echo "$as_me: The path of dxsdk_path, which resolves as \"$path\", is invalid." >&6;}
|
|
||||||
as_fn_error $? "Cannot locate the the path of dxsdk_path" "$LINENO" 5
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Call helper function which possibly converts this using DOS-style short mode.
|
|
||||||
# If so, the updated path is stored in $new_path.
|
|
||||||
|
|
||||||
input_path="$new_path"
|
|
||||||
# Check if we need to convert this using DOS-style short mode. If the path
|
|
||||||
# contains just simple characters, use it. Otherwise (spaces, weird characters),
|
|
||||||
# take no chances and rewrite it.
|
|
||||||
# Note: m4 eats our [], so we need to use [ and ] instead.
|
|
||||||
has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
|
|
||||||
if test "x$has_forbidden_chars" != x; then
|
|
||||||
# Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
|
|
||||||
shortmode_path=`$CYGPATH -s -m -a "$input_path"`
|
|
||||||
path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
|
|
||||||
if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
|
|
||||||
# Going to short mode and back again did indeed matter. Since short mode is
|
|
||||||
# case insensitive, let's make it lowercase to improve readability.
|
|
||||||
shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
|
|
||||||
# Now convert it back to Unix-stile (cygpath)
|
|
||||||
input_path=`$CYGPATH -u "$shortmode_path"`
|
|
||||||
new_path="$input_path"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
|
|
||||||
if test "x$test_cygdrive_prefix" = x; then
|
|
||||||
# As a simple fix, exclude /usr/bin since it's not a real path.
|
|
||||||
if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
|
|
||||||
# The path is in a Cygwin special directory (e.g. /home). We need this converted to
|
|
||||||
# a path prefixed by /cygdrive for fixpath to work.
|
|
||||||
new_path="$CYGWIN_ROOT_PATH$input_path"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
if test "x$path" != "x$new_path"; then
|
|
||||||
dxsdk_path="$new_path"
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting dxsdk_path to \"$new_path\"" >&5
|
|
||||||
$as_echo "$as_me: Rewriting dxsdk_path to \"$new_path\"" >&6;}
|
|
||||||
fi
|
|
||||||
|
|
||||||
elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
|
|
||||||
|
|
||||||
path="$dxsdk_path"
|
|
||||||
has_colon=`$ECHO $path | $GREP ^.:`
|
|
||||||
new_path="$path"
|
|
||||||
if test "x$has_colon" = x; then
|
|
||||||
# Not in mixed or Windows style, start by that.
|
|
||||||
new_path=`cmd //c echo $path`
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
input_path="$new_path"
|
|
||||||
# Check if we need to convert this using DOS-style short mode. If the path
|
|
||||||
# contains just simple characters, use it. Otherwise (spaces, weird characters),
|
|
||||||
# take no chances and rewrite it.
|
|
||||||
# Note: m4 eats our [], so we need to use [ and ] instead.
|
|
||||||
has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
|
|
||||||
if test "x$has_forbidden_chars" != x; then
|
|
||||||
# Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
|
|
||||||
new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
windows_path="$new_path"
|
|
||||||
if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
|
|
||||||
unix_path=`$CYGPATH -u "$windows_path"`
|
|
||||||
new_path="$unix_path"
|
|
||||||
elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
|
|
||||||
unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
|
|
||||||
new_path="$unix_path"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if test "x$path" != "x$new_path"; then
|
|
||||||
dxsdk_path="$new_path"
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting dxsdk_path to \"$new_path\"" >&5
|
|
||||||
$as_echo "$as_me: Rewriting dxsdk_path to \"$new_path\"" >&6;}
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Save the first 10 bytes of this path to the storage, so fixpath can work.
|
|
||||||
all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
|
|
||||||
|
|
||||||
else
|
|
||||||
# We're on a posix platform. Hooray! :)
|
|
||||||
path="$dxsdk_path"
|
|
||||||
has_space=`$ECHO "$path" | $GREP " "`
|
|
||||||
if test "x$has_space" != x; then
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: The path of dxsdk_path, which resolves as \"$path\", is invalid." >&5
|
|
||||||
$as_echo "$as_me: The path of dxsdk_path, which resolves as \"$path\", is invalid." >&6;}
|
|
||||||
as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Use eval to expand a potential ~
|
|
||||||
eval path="$path"
|
|
||||||
if test ! -f "$path" && test ! -d "$path"; then
|
|
||||||
as_fn_error $? "The path of dxsdk_path, which resolves as \"$path\", is not found." "$LINENO" 5
|
|
||||||
fi
|
|
||||||
|
|
||||||
dxsdk_path="`cd "$path"; $THEPWDCMD -L`"
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for DirectX SDK lib dir" >&5
|
|
||||||
$as_echo_n "checking for DirectX SDK lib dir... " >&6; }
|
|
||||||
if test "x$with_dxsdk_lib" != x; then
|
|
||||||
DXSDK_LIB_PATH="$with_dxsdk_lib"
|
|
||||||
elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then
|
|
||||||
DXSDK_LIB_PATH="$dxsdk_path/Lib/x64"
|
|
||||||
else
|
|
||||||
DXSDK_LIB_PATH="$dxsdk_path/Lib"
|
|
||||||
fi
|
|
||||||
# dsound.lib is linked to in jsoundds
|
|
||||||
if test ! -f "$DXSDK_LIB_PATH/dsound.lib"; then
|
|
||||||
as_fn_error $? "Invalid DirectX SDK lib dir" "$LINENO" 5
|
|
||||||
fi
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DXSDK_LIB_PATH" >&5
|
|
||||||
$as_echo "$DXSDK_LIB_PATH" >&6; }
|
|
||||||
|
|
||||||
if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
|
|
||||||
|
|
||||||
# Input might be given as Windows format, start by converting to
|
|
||||||
# unix format.
|
|
||||||
path="$DXSDK_LIB_PATH"
|
|
||||||
new_path=`$CYGPATH -u "$path"`
|
|
||||||
|
|
||||||
# Cygwin tries to hide some aspects of the Windows file system, such that binaries are
|
|
||||||
# named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
|
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
|
||||||
#
|
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
|
||||||
if test "x$test_shortpath" = x; then
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: The path of DXSDK_LIB_PATH, which resolves as \"$path\", is invalid." >&5
|
|
||||||
$as_echo "$as_me: The path of DXSDK_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
|
|
||||||
as_fn_error $? "Cannot locate the the path of DXSDK_LIB_PATH" "$LINENO" 5
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Call helper function which possibly converts this using DOS-style short mode.
|
|
||||||
# If so, the updated path is stored in $new_path.
|
|
||||||
|
|
||||||
input_path="$new_path"
|
|
||||||
# Check if we need to convert this using DOS-style short mode. If the path
|
|
||||||
# contains just simple characters, use it. Otherwise (spaces, weird characters),
|
|
||||||
# take no chances and rewrite it.
|
|
||||||
# Note: m4 eats our [], so we need to use [ and ] instead.
|
|
||||||
has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
|
|
||||||
if test "x$has_forbidden_chars" != x; then
|
|
||||||
# Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
|
|
||||||
shortmode_path=`$CYGPATH -s -m -a "$input_path"`
|
|
||||||
path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
|
|
||||||
if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
|
|
||||||
# Going to short mode and back again did indeed matter. Since short mode is
|
|
||||||
# case insensitive, let's make it lowercase to improve readability.
|
|
||||||
shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
|
|
||||||
# Now convert it back to Unix-stile (cygpath)
|
|
||||||
input_path=`$CYGPATH -u "$shortmode_path"`
|
|
||||||
new_path="$input_path"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
|
|
||||||
if test "x$test_cygdrive_prefix" = x; then
|
|
||||||
# As a simple fix, exclude /usr/bin since it's not a real path.
|
|
||||||
if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
|
|
||||||
# The path is in a Cygwin special directory (e.g. /home). We need this converted to
|
|
||||||
# a path prefixed by /cygdrive for fixpath to work.
|
|
||||||
new_path="$CYGWIN_ROOT_PATH$input_path"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
if test "x$path" != "x$new_path"; then
|
|
||||||
DXSDK_LIB_PATH="$new_path"
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DXSDK_LIB_PATH to \"$new_path\"" >&5
|
|
||||||
$as_echo "$as_me: Rewriting DXSDK_LIB_PATH to \"$new_path\"" >&6;}
|
|
||||||
fi
|
|
||||||
|
|
||||||
elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
|
|
||||||
|
|
||||||
path="$DXSDK_LIB_PATH"
|
|
||||||
has_colon=`$ECHO $path | $GREP ^.:`
|
|
||||||
new_path="$path"
|
|
||||||
if test "x$has_colon" = x; then
|
|
||||||
# Not in mixed or Windows style, start by that.
|
|
||||||
new_path=`cmd //c echo $path`
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
input_path="$new_path"
|
|
||||||
# Check if we need to convert this using DOS-style short mode. If the path
|
|
||||||
# contains just simple characters, use it. Otherwise (spaces, weird characters),
|
|
||||||
# take no chances and rewrite it.
|
|
||||||
# Note: m4 eats our [], so we need to use [ and ] instead.
|
|
||||||
has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
|
|
||||||
if test "x$has_forbidden_chars" != x; then
|
|
||||||
# Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
|
|
||||||
new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
windows_path="$new_path"
|
|
||||||
if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
|
|
||||||
unix_path=`$CYGPATH -u "$windows_path"`
|
|
||||||
new_path="$unix_path"
|
|
||||||
elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
|
|
||||||
unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
|
|
||||||
new_path="$unix_path"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if test "x$path" != "x$new_path"; then
|
|
||||||
DXSDK_LIB_PATH="$new_path"
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DXSDK_LIB_PATH to \"$new_path\"" >&5
|
|
||||||
$as_echo "$as_me: Rewriting DXSDK_LIB_PATH to \"$new_path\"" >&6;}
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Save the first 10 bytes of this path to the storage, so fixpath can work.
|
|
||||||
all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
|
|
||||||
|
|
||||||
else
|
|
||||||
# We're on a posix platform. Hooray! :)
|
|
||||||
path="$DXSDK_LIB_PATH"
|
|
||||||
has_space=`$ECHO "$path" | $GREP " "`
|
|
||||||
if test "x$has_space" != x; then
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: The path of DXSDK_LIB_PATH, which resolves as \"$path\", is invalid." >&5
|
|
||||||
$as_echo "$as_me: The path of DXSDK_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
|
|
||||||
as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Use eval to expand a potential ~
|
|
||||||
eval path="$path"
|
|
||||||
if test ! -f "$path" && test ! -d "$path"; then
|
|
||||||
as_fn_error $? "The path of DXSDK_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
|
|
||||||
fi
|
|
||||||
|
|
||||||
DXSDK_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for DirectX SDK include dir" >&5
|
|
||||||
$as_echo_n "checking for DirectX SDK include dir... " >&6; }
|
|
||||||
if test "x$with_dxsdk_include" != x; then
|
|
||||||
DXSDK_INCLUDE_PATH="$with_dxsdk_include"
|
|
||||||
else
|
|
||||||
DXSDK_INCLUDE_PATH="$dxsdk_path/Include"
|
|
||||||
fi
|
|
||||||
# dsound.h is included in jsoundds
|
|
||||||
if test ! -f "$DXSDK_INCLUDE_PATH/dsound.h"; then
|
|
||||||
as_fn_error $? "Invalid DirectX SDK lib dir" "$LINENO" 5
|
|
||||||
fi
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DXSDK_INCLUDE_PATH" >&5
|
|
||||||
$as_echo "$DXSDK_INCLUDE_PATH" >&6; }
|
|
||||||
|
|
||||||
if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
|
|
||||||
|
|
||||||
# Input might be given as Windows format, start by converting to
|
|
||||||
# unix format.
|
|
||||||
path="$DXSDK_INCLUDE_PATH"
|
|
||||||
new_path=`$CYGPATH -u "$path"`
|
|
||||||
|
|
||||||
# Cygwin tries to hide some aspects of the Windows file system, such that binaries are
|
|
||||||
# named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
|
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
|
||||||
#
|
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
|
||||||
if test "x$test_shortpath" = x; then
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: The path of DXSDK_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
|
|
||||||
$as_echo "$as_me: The path of DXSDK_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
|
|
||||||
as_fn_error $? "Cannot locate the the path of DXSDK_INCLUDE_PATH" "$LINENO" 5
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Call helper function which possibly converts this using DOS-style short mode.
|
|
||||||
# If so, the updated path is stored in $new_path.
|
|
||||||
|
|
||||||
input_path="$new_path"
|
|
||||||
# Check if we need to convert this using DOS-style short mode. If the path
|
|
||||||
# contains just simple characters, use it. Otherwise (spaces, weird characters),
|
|
||||||
# take no chances and rewrite it.
|
|
||||||
# Note: m4 eats our [], so we need to use [ and ] instead.
|
|
||||||
has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
|
|
||||||
if test "x$has_forbidden_chars" != x; then
|
|
||||||
# Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
|
|
||||||
shortmode_path=`$CYGPATH -s -m -a "$input_path"`
|
|
||||||
path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
|
|
||||||
if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
|
|
||||||
# Going to short mode and back again did indeed matter. Since short mode is
|
|
||||||
# case insensitive, let's make it lowercase to improve readability.
|
|
||||||
shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
|
|
||||||
# Now convert it back to Unix-stile (cygpath)
|
|
||||||
input_path=`$CYGPATH -u "$shortmode_path"`
|
|
||||||
new_path="$input_path"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
|
|
||||||
if test "x$test_cygdrive_prefix" = x; then
|
|
||||||
# As a simple fix, exclude /usr/bin since it's not a real path.
|
|
||||||
if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
|
|
||||||
# The path is in a Cygwin special directory (e.g. /home). We need this converted to
|
|
||||||
# a path prefixed by /cygdrive for fixpath to work.
|
|
||||||
new_path="$CYGWIN_ROOT_PATH$input_path"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
if test "x$path" != "x$new_path"; then
|
|
||||||
DXSDK_INCLUDE_PATH="$new_path"
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DXSDK_INCLUDE_PATH to \"$new_path\"" >&5
|
|
||||||
$as_echo "$as_me: Rewriting DXSDK_INCLUDE_PATH to \"$new_path\"" >&6;}
|
|
||||||
fi
|
|
||||||
|
|
||||||
elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
|
|
||||||
|
|
||||||
path="$DXSDK_INCLUDE_PATH"
|
|
||||||
has_colon=`$ECHO $path | $GREP ^.:`
|
|
||||||
new_path="$path"
|
|
||||||
if test "x$has_colon" = x; then
|
|
||||||
# Not in mixed or Windows style, start by that.
|
|
||||||
new_path=`cmd //c echo $path`
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
input_path="$new_path"
|
|
||||||
# Check if we need to convert this using DOS-style short mode. If the path
|
|
||||||
# contains just simple characters, use it. Otherwise (spaces, weird characters),
|
|
||||||
# take no chances and rewrite it.
|
|
||||||
# Note: m4 eats our [], so we need to use [ and ] instead.
|
|
||||||
has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
|
|
||||||
if test "x$has_forbidden_chars" != x; then
|
|
||||||
# Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
|
|
||||||
new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
windows_path="$new_path"
|
|
||||||
if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
|
|
||||||
unix_path=`$CYGPATH -u "$windows_path"`
|
|
||||||
new_path="$unix_path"
|
|
||||||
elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
|
|
||||||
unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
|
|
||||||
new_path="$unix_path"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if test "x$path" != "x$new_path"; then
|
|
||||||
DXSDK_INCLUDE_PATH="$new_path"
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DXSDK_INCLUDE_PATH to \"$new_path\"" >&5
|
|
||||||
$as_echo "$as_me: Rewriting DXSDK_INCLUDE_PATH to \"$new_path\"" >&6;}
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Save the first 10 bytes of this path to the storage, so fixpath can work.
|
|
||||||
all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
|
|
||||||
|
|
||||||
else
|
|
||||||
# We're on a posix platform. Hooray! :)
|
|
||||||
path="$DXSDK_INCLUDE_PATH"
|
|
||||||
has_space=`$ECHO "$path" | $GREP " "`
|
|
||||||
if test "x$has_space" != x; then
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: The path of DXSDK_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
|
|
||||||
$as_echo "$as_me: The path of DXSDK_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
|
|
||||||
as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Use eval to expand a potential ~
|
|
||||||
eval path="$path"
|
|
||||||
if test ! -f "$path" && test ! -d "$path"; then
|
|
||||||
as_fn_error $? "The path of DXSDK_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
|
|
||||||
fi
|
|
||||||
|
|
||||||
DXSDK_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
LDFLAGS_JDK="$LDFLAGS_JDK -libpath:$DXSDK_LIB_PATH"
|
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
@ -18140,7 +17749,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -18451,7 +18060,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -18757,7 +18366,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -19350,7 +18959,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -19786,7 +19395,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -20922,7 +20531,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -21358,7 +20967,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -22259,7 +21868,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -22640,7 +22249,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -22987,7 +22596,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -23324,7 +22933,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -23645,7 +23254,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -24020,7 +23629,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -24326,7 +23935,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -24737,7 +24346,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -25137,7 +24746,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -25466,7 +25075,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -25778,7 +25387,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -26084,7 +25693,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -26390,7 +25999,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -26696,7 +26305,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -27055,7 +26664,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -27415,7 +27024,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -27788,7 +27397,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -28159,7 +27768,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -28468,7 +28077,7 @@ $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, wh
|
||||||
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
# the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
|
||||||
# "foo.exe" is OK but "foo" is an error.
|
# "foo.exe" is OK but "foo" is an error.
|
||||||
#
|
#
|
||||||
# This test is therefore slightly more accurate than "test -f" to check for file precense.
|
# This test is therefore slightly more accurate than "test -f" to check for file presence.
|
||||||
# It is also a way to make sure we got the proper file name for the real test later on.
|
# It is also a way to make sure we got the proper file name for the real test later on.
|
||||||
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
|
||||||
if test "x$test_shortpath" = x; then
|
if test "x$test_shortpath" = x; then
|
||||||
|
@ -28830,35 +28439,41 @@ done
|
||||||
if test "x$OPENJDK_TARGET_OS" = xsolaris; then
|
if test "x$OPENJDK_TARGET_OS" = xsolaris; then
|
||||||
# Always specify -m flags on Solaris
|
# Always specify -m flags on Solaris
|
||||||
|
|
||||||
# keep track of c/cxx flags that we added outselves...
|
# When we add flags to the "official" CFLAGS etc, we need to
|
||||||
# to prevent emitting warning...
|
# keep track of these additions in ADDED_CFLAGS etc. These
|
||||||
TARGET_BITS_FLAG="-m${OPENJDK_TARGET_CPU_BITS}"
|
# will later be checked to make sure only controlled additions
|
||||||
|
# have been made to CFLAGS etc.
|
||||||
|
ADDED_CFLAGS=" -m${OPENJDK_TARGET_CPU_BITS}"
|
||||||
|
ADDED_CXXFLAGS=" -m${OPENJDK_TARGET_CPU_BITS}"
|
||||||
|
ADDED_LDFLAGS=" -m${OPENJDK_TARGET_CPU_BITS}"
|
||||||
|
|
||||||
|
CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
|
||||||
|
CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
|
||||||
|
LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
|
||||||
|
|
||||||
CFLAGS="${CFLAGS} ${TARGET_BITS_FLAG}"
|
CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
|
||||||
CXXFLAGS="${CXXFLAGS} ${TARGET_BITS_FLAG}"
|
CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
|
||||||
LDFLAGS="${LDFLAGS} ${TARGET_BITS_FLAG}"
|
LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
|
||||||
|
|
||||||
CFLAGS_JDK="${CFLAGS_JDK} ${TARGET_BITS_FLAG}"
|
|
||||||
CXXFLAGS_JDK="${CXXFLAGS_JDK} ${TARGET_BITS_FLAG}"
|
|
||||||
LDFLAGS_JDK="${LDFLAGS_JDK} ${TARGET_BITS_FLAG}"
|
|
||||||
|
|
||||||
elif test "x$COMPILE_TYPE" = xreduced; then
|
elif test "x$COMPILE_TYPE" = xreduced; then
|
||||||
if test "x$OPENJDK_TARGET_OS" != xwindows; then
|
if test "x$OPENJDK_TARGET_OS" != xwindows; then
|
||||||
# Specify -m if running reduced on other Posix platforms
|
# Specify -m if running reduced on other Posix platforms
|
||||||
|
|
||||||
# keep track of c/cxx flags that we added outselves...
|
# When we add flags to the "official" CFLAGS etc, we need to
|
||||||
# to prevent emitting warning...
|
# keep track of these additions in ADDED_CFLAGS etc. These
|
||||||
TARGET_BITS_FLAG="-m${OPENJDK_TARGET_CPU_BITS}"
|
# will later be checked to make sure only controlled additions
|
||||||
|
# have been made to CFLAGS etc.
|
||||||
|
ADDED_CFLAGS=" -m${OPENJDK_TARGET_CPU_BITS}"
|
||||||
|
ADDED_CXXFLAGS=" -m${OPENJDK_TARGET_CPU_BITS}"
|
||||||
|
ADDED_LDFLAGS=" -m${OPENJDK_TARGET_CPU_BITS}"
|
||||||
|
|
||||||
|
CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
|
||||||
|
CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
|
||||||
|
LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
|
||||||
|
|
||||||
CFLAGS="${CFLAGS} ${TARGET_BITS_FLAG}"
|
CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
|
||||||
CXXFLAGS="${CXXFLAGS} ${TARGET_BITS_FLAG}"
|
CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
|
||||||
LDFLAGS="${LDFLAGS} ${TARGET_BITS_FLAG}"
|
LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
|
||||||
|
|
||||||
CFLAGS_JDK="${CFLAGS_JDK} ${TARGET_BITS_FLAG}"
|
|
||||||
CXXFLAGS_JDK="${CXXFLAGS_JDK} ${TARGET_BITS_FLAG}"
|
|
||||||
LDFLAGS_JDK="${LDFLAGS_JDK} ${TARGET_BITS_FLAG}"
|
|
||||||
|
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
@ -33618,6 +33233,7 @@ fi
|
||||||
# We're messing a bit with internal autoconf variables to put the config.status
|
# We're messing a bit with internal autoconf variables to put the config.status
|
||||||
# in the output directory instead of the current directory.
|
# in the output directory instead of the current directory.
|
||||||
CONFIG_STATUS="$OUTPUT_ROOT/config.status"
|
CONFIG_STATUS="$OUTPUT_ROOT/config.status"
|
||||||
|
|
||||||
# Create the actual output files. Now the main work of configure is done.
|
# Create the actual output files. Now the main work of configure is done.
|
||||||
cat >confcache <<\_ACEOF
|
cat >confcache <<\_ACEOF
|
||||||
# This file is a shell script that caches the results of configure
|
# This file is a shell script that caches the results of configure
|
||||||
|
@ -34899,6 +34515,11 @@ $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
# Try to move the config.log file to the output directory.
|
||||||
|
if test -e ./config.log; then
|
||||||
|
$MV -f ./config.log "$OUTPUT_ROOT/config.log" 2> /dev/null
|
||||||
|
fi
|
||||||
|
|
||||||
# Make the compare script executable
|
# Make the compare script executable
|
||||||
$CHMOD +x $OUTPUT_ROOT/compare.sh
|
$CHMOD +x $OUTPUT_ROOT/compare.sh
|
||||||
|
|
||||||
|
|
|
@ -316,7 +316,7 @@ BUILD_HEADLESS="BUILD_HEADLESS:=true"
|
||||||
|
|
||||||
if test "x$SUPPORT_HEADFUL" = xyes; then
|
if test "x$SUPPORT_HEADFUL" = xyes; then
|
||||||
# We are building both headful and headless.
|
# We are building both headful and headless.
|
||||||
headful_msg="inlude support for both headful and headless"
|
headful_msg="include support for both headful and headless"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "x$SUPPORT_HEADFUL" = xno; then
|
if test "x$SUPPORT_HEADFUL" = xno; then
|
||||||
|
@ -426,6 +426,14 @@ elif test "x$with_update_version" != x; then
|
||||||
JDK_UPDATE_VERSION="$with_update_version"
|
JDK_UPDATE_VERSION="$with_update_version"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
AC_ARG_WITH(user-release-suffix, [AS_HELP_STRING([--with-user-release-suffix],
|
||||||
|
[Add a custom string to the version string if build number isn't set.@<:@username_builddateb00@:>@])])
|
||||||
|
if test "x$with_user_release_suffix" = xyes; then
|
||||||
|
AC_MSG_ERROR([Release suffix must have a value])
|
||||||
|
elif test "x$with_user_release_suffix" != x; then
|
||||||
|
USER_RELEASE_SUFFIX="$with_user_release_suffix"
|
||||||
|
fi
|
||||||
|
|
||||||
AC_ARG_WITH(build-number, [AS_HELP_STRING([--with-build-number],
|
AC_ARG_WITH(build-number, [AS_HELP_STRING([--with-build-number],
|
||||||
[Set build number value for build @<:@b00@:>@])])
|
[Set build number value for build @<:@b00@:>@])])
|
||||||
if test "x$with_build_number" = xyes; then
|
if test "x$with_build_number" = xyes; then
|
||||||
|
@ -433,25 +441,19 @@ if test "x$with_build_number" = xyes; then
|
||||||
elif test "x$with_build_number" != x; then
|
elif test "x$with_build_number" != x; then
|
||||||
JDK_BUILD_NUMBER="$with_build_number"
|
JDK_BUILD_NUMBER="$with_build_number"
|
||||||
fi
|
fi
|
||||||
|
# Define default USER_RELEASE_SUFFIX if BUILD_NUMBER and USER_RELEASE_SUFFIX are not set
|
||||||
if test "x$JDK_BUILD_NUMBER" = x; then
|
if test "x$JDK_BUILD_NUMBER" = x; then
|
||||||
JDK_BUILD_NUMBER=b00
|
JDK_BUILD_NUMBER=b00
|
||||||
|
if test "x$USER_RELEASE_SUFFIX" = x; then
|
||||||
|
BUILD_DATE=`date '+%Y_%m_%d_%H_%M'`
|
||||||
|
# Avoid [:alnum:] since it depends on the locale.
|
||||||
|
CLEAN_USERNAME=`echo "$USER" | $TR -d -c 'abcdefghijklmnopqrstuvqxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'`
|
||||||
|
USER_RELEASE_SUFFIX=`echo "${CLEAN_USERNAME}_${BUILD_DATE}" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
AC_ARG_WITH(user-release-suffix, [AS_HELP_STRING([--with-user-release-suffix],
|
|
||||||
[Add a custom string to the version string if build number isn't set.@<:@username_builddateb00@:>@])])
|
|
||||||
if test "x$with_user_release_suffix" = xyes; then
|
|
||||||
AC_MSG_ERROR([Release suffix must have a value])
|
|
||||||
elif test "x$with_user_release_suffix" != x; then
|
|
||||||
USER_RELEASE_SUFFIX="$with_user_release_suffix"
|
|
||||||
else
|
|
||||||
BUILD_DATE=`date '+%Y_%m_%d_%H_%M'`
|
|
||||||
# Avoid [:alnum:] since it depends on the locale.
|
|
||||||
CLEAN_USERNAME=`echo "$USER" | $TR -d -c 'abcdefghijklmnopqrstuvqxyz0123456789'`
|
|
||||||
USER_RELEASE_SUFFIX=`echo "${CLEAN_USERNAME}_${BUILD_DATE}" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
|
|
||||||
fi
|
|
||||||
AC_SUBST(USER_RELEASE_SUFFIX)
|
|
||||||
|
|
||||||
# Now set the JDK version, milestone, build number etc.
|
# Now set the JDK version, milestone, build number etc.
|
||||||
|
AC_SUBST(USER_RELEASE_SUFFIX)
|
||||||
AC_SUBST(JDK_MAJOR_VERSION)
|
AC_SUBST(JDK_MAJOR_VERSION)
|
||||||
AC_SUBST(JDK_MINOR_VERSION)
|
AC_SUBST(JDK_MINOR_VERSION)
|
||||||
AC_SUBST(JDK_MICRO_VERSION)
|
AC_SUBST(JDK_MICRO_VERSION)
|
||||||
|
|
|
@ -422,18 +422,21 @@ AC_SUBST(OS_VERSION_MICRO)
|
||||||
# Add -mX to various FLAGS variables.
|
# Add -mX to various FLAGS variables.
|
||||||
AC_DEFUN([PLATFORM_SET_COMPILER_TARGET_BITS_FLAGS],
|
AC_DEFUN([PLATFORM_SET_COMPILER_TARGET_BITS_FLAGS],
|
||||||
[
|
[
|
||||||
# keep track of c/cxx flags that we added outselves...
|
# When we add flags to the "official" CFLAGS etc, we need to
|
||||||
# to prevent emitting warning...
|
# keep track of these additions in ADDED_CFLAGS etc. These
|
||||||
TARGET_BITS_FLAG="-m${OPENJDK_TARGET_CPU_BITS}"
|
# will later be checked to make sure only controlled additions
|
||||||
AC_SUBST(TARGET_BITS_FLAG)
|
# have been made to CFLAGS etc.
|
||||||
|
ADDED_CFLAGS=" -m${OPENJDK_TARGET_CPU_BITS}"
|
||||||
|
ADDED_CXXFLAGS=" -m${OPENJDK_TARGET_CPU_BITS}"
|
||||||
|
ADDED_LDFLAGS=" -m${OPENJDK_TARGET_CPU_BITS}"
|
||||||
|
|
||||||
CFLAGS="${CFLAGS} ${TARGET_BITS_FLAG}"
|
CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
|
||||||
CXXFLAGS="${CXXFLAGS} ${TARGET_BITS_FLAG}"
|
CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
|
||||||
LDFLAGS="${LDFLAGS} ${TARGET_BITS_FLAG}"
|
LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
|
||||||
|
|
||||||
CFLAGS_JDK="${CFLAGS_JDK} ${TARGET_BITS_FLAG}"
|
CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
|
||||||
CXXFLAGS_JDK="${CXXFLAGS_JDK} ${TARGET_BITS_FLAG}"
|
CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
|
||||||
LDFLAGS_JDK="${LDFLAGS_JDK} ${TARGET_BITS_FLAG}"
|
LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
|
||||||
])
|
])
|
||||||
|
|
||||||
AC_DEFUN_ONCE([PLATFORM_SETUP_OPENJDK_TARGET_BITS],
|
AC_DEFUN_ONCE([PLATFORM_SETUP_OPENJDK_TARGET_BITS],
|
||||||
|
|
|
@ -101,6 +101,10 @@ if test "x$with_add_source_root" != x; then
|
||||||
test -f $with_add_source_root/hotspot/make/Makefile; then
|
test -f $with_add_source_root/hotspot/make/Makefile; then
|
||||||
AC_MSG_ERROR([Your add source root seems to contain a full hotspot repo! An add source root should only contain additional sources.])
|
AC_MSG_ERROR([Your add source root seems to contain a full hotspot repo! An add source root should only contain additional sources.])
|
||||||
fi
|
fi
|
||||||
|
if test -f $with_add_source_root/nashorn/makefiles/Makefile || \
|
||||||
|
test -f $with_add_source_root/nashorn/make/Makefile; then
|
||||||
|
AC_MSG_ERROR([Your add source root seems to contain a full nashorn repo! An add source root should only contain additional sources.])
|
||||||
|
fi
|
||||||
if test -f $with_add_source_root/jdk/makefiles/Makefile || \
|
if test -f $with_add_source_root/jdk/makefiles/Makefile || \
|
||||||
test -f $with_add_source_root/jdk/make/Makefile; then
|
test -f $with_add_source_root/jdk/make/Makefile; then
|
||||||
AC_MSG_ERROR([Your add source root seems to contain a full JDK repo! An add source root should only contain additional sources.])
|
AC_MSG_ERROR([Your add source root seems to contain a full JDK repo! An add source root should only contain additional sources.])
|
||||||
|
@ -136,6 +140,10 @@ if test "x$with_override_source_root" != x; then
|
||||||
test -f $with_override_source_root/hotspot/make/Makefile; then
|
test -f $with_override_source_root/hotspot/make/Makefile; then
|
||||||
AC_MSG_ERROR([Your override source root seems to contain a full hotspot repo! An override source root should only contain sources that override.])
|
AC_MSG_ERROR([Your override source root seems to contain a full hotspot repo! An override source root should only contain sources that override.])
|
||||||
fi
|
fi
|
||||||
|
if test -f $with_override_source_root/nashorn/makefiles/Makefile || \
|
||||||
|
test -f $with_override_source_root/nashorn/make/Makefile; then
|
||||||
|
AC_MSG_ERROR([Your override source root seems to contain a full nashorn repo! An override source root should only contain sources that override.])
|
||||||
|
fi
|
||||||
if test -f $with_override_source_root/jdk/makefiles/Makefile || \
|
if test -f $with_override_source_root/jdk/makefiles/Makefile || \
|
||||||
test -f $with_override_source_root/jdk/make/Makefile; then
|
test -f $with_override_source_root/jdk/make/Makefile; then
|
||||||
AC_MSG_ERROR([Your override source root seems to contain a full JDK repo! An override source root should only contain sources that override.])
|
AC_MSG_ERROR([Your override source root seems to contain a full JDK repo! An override source root should only contain sources that override.])
|
||||||
|
@ -177,6 +185,9 @@ AC_ARG_WITH(override-jaxws, [AS_HELP_STRING([--with-override-jaxws],
|
||||||
AC_ARG_WITH(override-hotspot, [AS_HELP_STRING([--with-override-hotspot],
|
AC_ARG_WITH(override-hotspot, [AS_HELP_STRING([--with-override-hotspot],
|
||||||
[use this hotspot dir for the build])])
|
[use this hotspot dir for the build])])
|
||||||
|
|
||||||
|
AC_ARG_WITH(override-nashorn, [AS_HELP_STRING([--with-override-nashorn],
|
||||||
|
[use this nashorn dir for the build])])
|
||||||
|
|
||||||
AC_ARG_WITH(override-jdk, [AS_HELP_STRING([--with-override-jdk],
|
AC_ARG_WITH(override-jdk, [AS_HELP_STRING([--with-override-jdk],
|
||||||
[use this jdk dir for the build])])
|
[use this jdk dir for the build])])
|
||||||
|
|
||||||
|
@ -241,7 +252,7 @@ if test "x$with_override_nashorn" != x; then
|
||||||
cd "$with_override_nashorn"
|
cd "$with_override_nashorn"
|
||||||
NASHORN_TOPDIR="`pwd`"
|
NASHORN_TOPDIR="`pwd`"
|
||||||
cd "$CURDIR"
|
cd "$CURDIR"
|
||||||
if ! test -f $NASHORN_TOPDIR/makefiles/BuildNashorn.gmk; then
|
if ! test -f $NASHORN_TOPDIR/makefiles/Makefile; then
|
||||||
AC_MSG_ERROR([You have to override nashorn with a full nashorn repo!])
|
AC_MSG_ERROR([You have to override nashorn with a full nashorn repo!])
|
||||||
fi
|
fi
|
||||||
AC_MSG_CHECKING([if nashorn should be overridden])
|
AC_MSG_CHECKING([if nashorn should be overridden])
|
||||||
|
|
|
@ -161,6 +161,7 @@ JDK_RC_PLATFORM_NAME:=@JDK_RC_PLATFORM_NAME@
|
||||||
COMPANY_NAME:=@COMPANY_NAME@
|
COMPANY_NAME:=@COMPANY_NAME@
|
||||||
MACOSX_BUNDLE_NAME_BASE=@MACOSX_BUNDLE_NAME_BASE@
|
MACOSX_BUNDLE_NAME_BASE=@MACOSX_BUNDLE_NAME_BASE@
|
||||||
MACOSX_BUNDLE_ID_BASE=@MACOSX_BUNDLE_ID_BASE@
|
MACOSX_BUNDLE_ID_BASE=@MACOSX_BUNDLE_ID_BASE@
|
||||||
|
USER_RELEASE_SUFFIX=@USER_RELEASE_SUFFIX@
|
||||||
|
|
||||||
# Different version strings generated from the above information.
|
# Different version strings generated from the above information.
|
||||||
JDK_VERSION:=@JDK_VERSION@
|
JDK_VERSION:=@JDK_VERSION@
|
||||||
|
@ -173,8 +174,8 @@ ifeq ($(MILESTONE),)
|
||||||
else
|
else
|
||||||
RELEASE=$(JDK_VERSION)-$(MILESTONE)$(BUILD_VARIANT_RELEASE)
|
RELEASE=$(JDK_VERSION)-$(MILESTONE)$(BUILD_VARIANT_RELEASE)
|
||||||
endif
|
endif
|
||||||
ifeq ($(JDK_BUILD_NUMBER),b00)
|
|
||||||
USER_RELEASE_SUFFIX=@USER_RELEASE_SUFFIX@
|
ifneq ($(USER_RELEASE_SUFFIX),)
|
||||||
FULL_VERSION=$(RELEASE)-$(USER_RELEASE_SUFFIX)-$(JDK_BUILD_NUMBER)
|
FULL_VERSION=$(RELEASE)-$(USER_RELEASE_SUFFIX)-$(JDK_BUILD_NUMBER)
|
||||||
else
|
else
|
||||||
FULL_VERSION=$(RELEASE)-$(JDK_BUILD_NUMBER)
|
FULL_VERSION=$(RELEASE)-$(JDK_BUILD_NUMBER)
|
||||||
|
@ -291,10 +292,6 @@ X_CFLAGS:=@X_CFLAGS@
|
||||||
X_LIBS:=@X_LIBS@
|
X_LIBS:=@X_LIBS@
|
||||||
OPENWIN_HOME:=@OPENWIN_HOME@
|
OPENWIN_HOME:=@OPENWIN_HOME@
|
||||||
|
|
||||||
# DirectX SDK
|
|
||||||
DXSDK_LIB_PATH=@DXSDK_LIB_PATH@
|
|
||||||
DXSDK_INCLUDE_PATH=@DXSDK_INCLUDE_PATH@
|
|
||||||
|
|
||||||
# The lowest required version of macosx to enforce compatiblity for
|
# The lowest required version of macosx to enforce compatiblity for
|
||||||
MACOSX_VERSION_MIN=@MACOSX_VERSION_MIN@
|
MACOSX_VERSION_MIN=@MACOSX_VERSION_MIN@
|
||||||
|
|
||||||
|
@ -304,7 +301,6 @@ MACOSX_VERSION_MIN=@MACOSX_VERSION_MIN@
|
||||||
COMPILER_TYPE:=@COMPILER_TYPE@
|
COMPILER_TYPE:=@COMPILER_TYPE@
|
||||||
COMPILER_NAME:=@COMPILER_NAME@
|
COMPILER_NAME:=@COMPILER_NAME@
|
||||||
|
|
||||||
TARGET_BITS_FLAG=@TARGET_BITS_FLAG@
|
|
||||||
COMPILER_SUPPORTS_TARGET_BITS_FLAG=@COMPILER_SUPPORTS_TARGET_BITS_FLAG@
|
COMPILER_SUPPORTS_TARGET_BITS_FLAG=@COMPILER_SUPPORTS_TARGET_BITS_FLAG@
|
||||||
|
|
||||||
CC_OUT_OPTION:=@CC_OUT_OPTION@
|
CC_OUT_OPTION:=@CC_OUT_OPTION@
|
||||||
|
|
|
@ -176,7 +176,9 @@ AC_DEFUN([TOOLCHAIN_SETUP_PATHS],
|
||||||
[
|
[
|
||||||
if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
|
if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
|
||||||
TOOLCHAIN_SETUP_VISUAL_STUDIO_ENV
|
TOOLCHAIN_SETUP_VISUAL_STUDIO_ENV
|
||||||
TOOLCHAIN_SETUP_DXSDK
|
BASIC_DEPRECATED_ARG_WITH([dxsdk])
|
||||||
|
BASIC_DEPRECATED_ARG_WITH([dxsdk-lib])
|
||||||
|
BASIC_DEPRECATED_ARG_WITH([dxsdk-include])
|
||||||
fi
|
fi
|
||||||
|
|
||||||
AC_SUBST(MSVCR_DLL)
|
AC_SUBST(MSVCR_DLL)
|
||||||
|
|
|
@ -277,61 +277,3 @@ AC_DEFUN([TOOLCHAIN_SETUP_VISUAL_STUDIO_ENV],
|
||||||
AC_MSG_RESULT([$MSVCR_DLL])
|
AC_MSG_RESULT([$MSVCR_DLL])
|
||||||
BASIC_FIXUP_PATH(MSVCR_DLL)
|
BASIC_FIXUP_PATH(MSVCR_DLL)
|
||||||
])
|
])
|
||||||
|
|
||||||
|
|
||||||
# Setup the DXSDK paths
|
|
||||||
AC_DEFUN([TOOLCHAIN_SETUP_DXSDK],
|
|
||||||
[
|
|
||||||
AC_ARG_WITH(dxsdk, [AS_HELP_STRING([--with-dxsdk],
|
|
||||||
[the DirectX SDK (Windows only) @<:@probed@:>@])])
|
|
||||||
AC_ARG_WITH(dxsdk-lib, [AS_HELP_STRING([--with-dxsdk-lib],
|
|
||||||
[the DirectX SDK lib directory (Windows only) @<:@probed@:>@])])
|
|
||||||
AC_ARG_WITH(dxsdk-include, [AS_HELP_STRING([--with-dxsdk-include],
|
|
||||||
[the DirectX SDK include directory (Windows only) @<:@probed@:>@])])
|
|
||||||
|
|
||||||
AC_MSG_CHECKING([for DirectX SDK])
|
|
||||||
|
|
||||||
if test "x$with_dxsdk" != x; then
|
|
||||||
dxsdk_path="$with_dxsdk"
|
|
||||||
elif test "x$DXSDK_DIR" != x; then
|
|
||||||
dxsdk_path="$DXSDK_DIR"
|
|
||||||
elif test -d "C:/DXSDK"; then
|
|
||||||
dxsdk_path="C:/DXSDK"
|
|
||||||
else
|
|
||||||
AC_MSG_ERROR([Could not find the DirectX SDK])
|
|
||||||
fi
|
|
||||||
AC_MSG_RESULT([$dxsdk_path])
|
|
||||||
BASIC_FIXUP_PATH(dxsdk_path)
|
|
||||||
|
|
||||||
AC_MSG_CHECKING([for DirectX SDK lib dir])
|
|
||||||
if test "x$with_dxsdk_lib" != x; then
|
|
||||||
DXSDK_LIB_PATH="$with_dxsdk_lib"
|
|
||||||
elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then
|
|
||||||
DXSDK_LIB_PATH="$dxsdk_path/Lib/x64"
|
|
||||||
else
|
|
||||||
DXSDK_LIB_PATH="$dxsdk_path/Lib"
|
|
||||||
fi
|
|
||||||
# dsound.lib is linked to in jsoundds
|
|
||||||
if test ! -f "$DXSDK_LIB_PATH/dsound.lib"; then
|
|
||||||
AC_MSG_ERROR([Invalid DirectX SDK lib dir])
|
|
||||||
fi
|
|
||||||
AC_MSG_RESULT([$DXSDK_LIB_PATH])
|
|
||||||
BASIC_FIXUP_PATH(DXSDK_LIB_PATH)
|
|
||||||
|
|
||||||
AC_MSG_CHECKING([for DirectX SDK include dir])
|
|
||||||
if test "x$with_dxsdk_include" != x; then
|
|
||||||
DXSDK_INCLUDE_PATH="$with_dxsdk_include"
|
|
||||||
else
|
|
||||||
DXSDK_INCLUDE_PATH="$dxsdk_path/Include"
|
|
||||||
fi
|
|
||||||
# dsound.h is included in jsoundds
|
|
||||||
if test ! -f "$DXSDK_INCLUDE_PATH/dsound.h"; then
|
|
||||||
AC_MSG_ERROR([Invalid DirectX SDK lib dir])
|
|
||||||
fi
|
|
||||||
AC_MSG_RESULT([$DXSDK_INCLUDE_PATH])
|
|
||||||
BASIC_FIXUP_PATH(DXSDK_INCLUDE_PATH)
|
|
||||||
|
|
||||||
AC_SUBST(DXSDK_LIB_PATH)
|
|
||||||
AC_SUBST(DXSDK_INCLUDE_PATH)
|
|
||||||
LDFLAGS_JDK="$LDFLAGS_JDK -libpath:$DXSDK_LIB_PATH"
|
|
||||||
])
|
|
||||||
|
|
|
@ -76,13 +76,13 @@ diff_text() {
|
||||||
TMP=1
|
TMP=1
|
||||||
|
|
||||||
if [[ "$THIS_FILE" = *"META-INF/MANIFEST.MF" ]]; then
|
if [[ "$THIS_FILE" = *"META-INF/MANIFEST.MF" ]]; then
|
||||||
TMP=$(LANG=C $DIFF $OTHER_FILE $THIS_FILE | \
|
TMP=$(LC_ALL=C $DIFF $OTHER_FILE $THIS_FILE | \
|
||||||
$GREP '^[<>]' | \
|
$GREP '^[<>]' | \
|
||||||
$SED -e '/[<>] Ant-Version: Apache Ant .*/d' \
|
$SED -e '/[<>] Ant-Version: Apache Ant .*/d' \
|
||||||
-e '/[<>] Created-By: .* (Oracle Corporation).*/d')
|
-e '/[<>] Created-By: .* (Oracle Corporation).*/d')
|
||||||
fi
|
fi
|
||||||
if test "x$SUFFIX" = "xjava"; then
|
if test "x$SUFFIX" = "xjava"; then
|
||||||
TMP=$(LANG=C $DIFF $OTHER_FILE $THIS_FILE | \
|
TMP=$(LC_ALL=C $DIFF $OTHER_FILE $THIS_FILE | \
|
||||||
$GREP '^[<>]' | \
|
$GREP '^[<>]' | \
|
||||||
$SED -e '/[<>] \* from.*\.idl/d' \
|
$SED -e '/[<>] \* from.*\.idl/d' \
|
||||||
-e '/[<>] \*.*[0-9]\{4\}_[0-9]\{2\}_[0-9]\{2\}_[0-9]\{2\}_[0-9]\{2\}-b[0-9]\{2\}.*/d' \
|
-e '/[<>] \*.*[0-9]\{4\}_[0-9]\{2\}_[0-9]\{2\}_[0-9]\{2\}_[0-9]\{2\}-b[0-9]\{2\}.*/d' \
|
||||||
|
@ -121,8 +121,8 @@ diff_text() {
|
||||||
# | $SED -e '/^#/d' -e '/^$/d' \
|
# | $SED -e '/^#/d' -e '/^$/d' \
|
||||||
# -e :a -e '/\\$/N; s/\\\n//; ta' \
|
# -e :a -e '/\\$/N; s/\\\n//; ta' \
|
||||||
# -e 's/^[ \t]*//;s/[ \t]*$//' \
|
# -e 's/^[ \t]*//;s/[ \t]*$//' \
|
||||||
# -e 's/\\=/=/' | LANG=C $SORT > $OTHER_FILE.cleaned
|
# -e 's/\\=/=/' | LC_ALL=C $SORT > $OTHER_FILE.cleaned
|
||||||
TMP=$(LANG=C $DIFF $OTHER_FILE.cleaned $THIS_FILE)
|
TMP=$(LC_ALL=C $DIFF $OTHER_FILE.cleaned $THIS_FILE)
|
||||||
fi
|
fi
|
||||||
if test -n "$TMP"; then
|
if test -n "$TMP"; then
|
||||||
echo Files $OTHER_FILE and $THIS_FILE differ
|
echo Files $OTHER_FILE and $THIS_FILE differ
|
||||||
|
@ -410,11 +410,11 @@ compare_zip_file() {
|
||||||
CONTENTS_DIFF_FILE=$WORK_DIR/$ZIP_FILE.diff
|
CONTENTS_DIFF_FILE=$WORK_DIR/$ZIP_FILE.diff
|
||||||
# On solaris, there is no -q option.
|
# On solaris, there is no -q option.
|
||||||
if [ "$OPENJDK_TARGET_OS" = "solaris" ]; then
|
if [ "$OPENJDK_TARGET_OS" = "solaris" ]; then
|
||||||
LANG=C $DIFF -r $OTHER_UNZIPDIR $THIS_UNZIPDIR \
|
LC_ALL=C $DIFF -r $OTHER_UNZIPDIR $THIS_UNZIPDIR \
|
||||||
| $GREP -v -e "^<" -e "^>" -e "^Common subdirectories:" \
|
| $GREP -v -e "^<" -e "^>" -e "^Common subdirectories:" \
|
||||||
> $CONTENTS_DIFF_FILE
|
> $CONTENTS_DIFF_FILE
|
||||||
else
|
else
|
||||||
LANG=C $DIFF -rq $OTHER_UNZIPDIR $THIS_UNZIPDIR > $CONTENTS_DIFF_FILE
|
LC_ALL=C $DIFF -rq $OTHER_UNZIPDIR $THIS_UNZIPDIR > $CONTENTS_DIFF_FILE
|
||||||
fi
|
fi
|
||||||
|
|
||||||
ONLY_OTHER=$($GREP "^Only in $OTHER_UNZIPDIR" $CONTENTS_DIFF_FILE)
|
ONLY_OTHER=$($GREP "^Only in $OTHER_UNZIPDIR" $CONTENTS_DIFF_FILE)
|
||||||
|
@ -459,11 +459,11 @@ compare_zip_file() {
|
||||||
if [ -n "$SHOW_DIFFS" ]; then
|
if [ -n "$SHOW_DIFFS" ]; then
|
||||||
for i in $(cat $WORK_DIR/$ZIP_FILE.difflist) ; do
|
for i in $(cat $WORK_DIR/$ZIP_FILE.difflist) ; do
|
||||||
if [ -f "${OTHER_UNZIPDIR}/$i.javap" ]; then
|
if [ -f "${OTHER_UNZIPDIR}/$i.javap" ]; then
|
||||||
LANG=C $DIFF ${OTHER_UNZIPDIR}/$i.javap ${THIS_UNZIPDIR}/$i.javap
|
LC_ALL=C $DIFF ${OTHER_UNZIPDIR}/$i.javap ${THIS_UNZIPDIR}/$i.javap
|
||||||
elif [ -f "${OTHER_UNZIPDIR}/$i.cleaned" ]; then
|
elif [ -f "${OTHER_UNZIPDIR}/$i.cleaned" ]; then
|
||||||
LANG=C $DIFF ${OTHER_UNZIPDIR}/$i.cleaned ${THIS_UNZIPDIR}/$i
|
LC_ALL=C $DIFF ${OTHER_UNZIPDIR}/$i.cleaned ${THIS_UNZIPDIR}/$i
|
||||||
else
|
else
|
||||||
LANG=C $DIFF ${OTHER_UNZIPDIR}/$i ${THIS_UNZIPDIR}/$i
|
LC_ALL=C $DIFF ${OTHER_UNZIPDIR}/$i ${THIS_UNZIPDIR}/$i
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
@ -703,7 +703,7 @@ compare_bin_file() {
|
||||||
$NM -a $ORIG_THIS_FILE 2> /dev/null | $GREP -v $NAME | $AWK '{print $2, $3, $4, $5}' | $SYM_SORT_CMD > $WORK_FILE_BASE.symbols.this
|
$NM -a $ORIG_THIS_FILE 2> /dev/null | $GREP -v $NAME | $AWK '{print $2, $3, $4, $5}' | $SYM_SORT_CMD > $WORK_FILE_BASE.symbols.this
|
||||||
fi
|
fi
|
||||||
|
|
||||||
LANG=C $DIFF $WORK_FILE_BASE.symbols.other $WORK_FILE_BASE.symbols.this > $WORK_FILE_BASE.symbols.diff
|
LC_ALL=C $DIFF $WORK_FILE_BASE.symbols.other $WORK_FILE_BASE.symbols.this > $WORK_FILE_BASE.symbols.diff
|
||||||
if [ -s $WORK_FILE_BASE.symbols.diff ]; then
|
if [ -s $WORK_FILE_BASE.symbols.diff ]; then
|
||||||
SYM_MSG=" diff "
|
SYM_MSG=" diff "
|
||||||
if [[ "$ACCEPTED_SYM_DIFF" != *"$BIN_FILE"* ]]; then
|
if [[ "$ACCEPTED_SYM_DIFF" != *"$BIN_FILE"* ]]; then
|
||||||
|
@ -732,8 +732,8 @@ compare_bin_file() {
|
||||||
(cd $FILE_WORK_DIR && $CP $THIS_FILE . && $LDD_CMD $NAME 2</dev/null | $AWK '{ print $1;}' | $SORT | $TEE $WORK_FILE_BASE.deps.this | $UNIQ > $WORK_FILE_BASE.deps.this.uniq)
|
(cd $FILE_WORK_DIR && $CP $THIS_FILE . && $LDD_CMD $NAME 2</dev/null | $AWK '{ print $1;}' | $SORT | $TEE $WORK_FILE_BASE.deps.this | $UNIQ > $WORK_FILE_BASE.deps.this.uniq)
|
||||||
(cd $FILE_WORK_DIR && $RM -f $NAME)
|
(cd $FILE_WORK_DIR && $RM -f $NAME)
|
||||||
|
|
||||||
LANG=C $DIFF $WORK_FILE_BASE.deps.other $WORK_FILE_BASE.deps.this > $WORK_FILE_BASE.deps.diff
|
LC_ALL=C $DIFF $WORK_FILE_BASE.deps.other $WORK_FILE_BASE.deps.this > $WORK_FILE_BASE.deps.diff
|
||||||
LANG=C $DIFF $WORK_FILE_BASE.deps.other.uniq $WORK_FILE_BASE.deps.this.uniq > $WORK_FILE_BASE.deps.diff.uniq
|
LC_ALL=C $DIFF $WORK_FILE_BASE.deps.other.uniq $WORK_FILE_BASE.deps.this.uniq > $WORK_FILE_BASE.deps.diff.uniq
|
||||||
|
|
||||||
if [ -s $WORK_FILE_BASE.deps.diff ]; then
|
if [ -s $WORK_FILE_BASE.deps.diff ]; then
|
||||||
if [ -s $WORK_FILE_BASE.deps.diff.uniq ]; then
|
if [ -s $WORK_FILE_BASE.deps.diff.uniq ]; then
|
||||||
|
@ -768,7 +768,7 @@ compare_bin_file() {
|
||||||
if [ -n "$FULLDUMP_CMD" ] && [ -z "$SKIP_FULLDUMP_DIFF" ]; then
|
if [ -n "$FULLDUMP_CMD" ] && [ -z "$SKIP_FULLDUMP_DIFF" ]; then
|
||||||
$FULLDUMP_CMD $OTHER_FILE > $WORK_FILE_BASE.fulldump.other 2>&1
|
$FULLDUMP_CMD $OTHER_FILE > $WORK_FILE_BASE.fulldump.other 2>&1
|
||||||
$FULLDUMP_CMD $THIS_FILE > $WORK_FILE_BASE.fulldump.this 2>&1
|
$FULLDUMP_CMD $THIS_FILE > $WORK_FILE_BASE.fulldump.this 2>&1
|
||||||
LANG=C $DIFF $WORK_FILE_BASE.fulldump.other $WORK_FILE_BASE.fulldump.this > $WORK_FILE_BASE.fulldump.diff
|
LC_ALL=C $DIFF $WORK_FILE_BASE.fulldump.other $WORK_FILE_BASE.fulldump.this > $WORK_FILE_BASE.fulldump.diff
|
||||||
|
|
||||||
if [ -s $WORK_FILE_BASE.fulldump.diff ]; then
|
if [ -s $WORK_FILE_BASE.fulldump.diff ]; then
|
||||||
ELF_DIFF_SIZE=$(ls -n $WORK_FILE_BASE.fulldump.diff | awk '{print $5}')
|
ELF_DIFF_SIZE=$(ls -n $WORK_FILE_BASE.fulldump.diff | awk '{print $5}')
|
||||||
|
@ -802,7 +802,7 @@ compare_bin_file() {
|
||||||
$DIS_CMD $OTHER_FILE | $GREP -v $NAME | $DIS_DIFF_FILTER > $WORK_FILE_BASE.dis.other 2>&1
|
$DIS_CMD $OTHER_FILE | $GREP -v $NAME | $DIS_DIFF_FILTER > $WORK_FILE_BASE.dis.other 2>&1
|
||||||
$DIS_CMD $THIS_FILE | $GREP -v $NAME | $DIS_DIFF_FILTER > $WORK_FILE_BASE.dis.this 2>&1
|
$DIS_CMD $THIS_FILE | $GREP -v $NAME | $DIS_DIFF_FILTER > $WORK_FILE_BASE.dis.this 2>&1
|
||||||
|
|
||||||
LANG=C $DIFF $WORK_FILE_BASE.dis.other $WORK_FILE_BASE.dis.this > $WORK_FILE_BASE.dis.diff
|
LC_ALL=C $DIFF $WORK_FILE_BASE.dis.other $WORK_FILE_BASE.dis.this > $WORK_FILE_BASE.dis.diff
|
||||||
|
|
||||||
if [ -s $WORK_FILE_BASE.dis.diff ]; then
|
if [ -s $WORK_FILE_BASE.dis.diff ]; then
|
||||||
DIS_DIFF_SIZE=$(ls -n $WORK_FILE_BASE.dis.diff | awk '{print $5}')
|
DIS_DIFF_SIZE=$(ls -n $WORK_FILE_BASE.dis.diff | awk '{print $5}')
|
||||||
|
|
|
@ -47,7 +47,7 @@ python=""
|
||||||
bpython=""
|
bpython=""
|
||||||
|
|
||||||
if [ "#!" = "$has_hash_bang" ] ; then
|
if [ "#!" = "$has_hash_bang" ] ; then
|
||||||
python="`head -n 1 ${whichhg} | cut -b 3-`"
|
python="`head -n 1 ${whichhg} | cut -b 3- | sed -e 's/^[ \t]*//;s/[ \t]*$//'`"
|
||||||
bpython="`basename "$python"`"
|
bpython="`basename "$python"`"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
|
@ -159,7 +159,7 @@ define SetupArchive
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
# Utility macros, to make the shell script receipt somewhat easier to dechipher.
|
# Utility macros, to make the shell script receipt somewhat easier to decipher.
|
||||||
|
|
||||||
# The capture contents macro finds all files (matching the patterns, typically
|
# The capture contents macro finds all files (matching the patterns, typically
|
||||||
# .class and .prp) that are newer than the jar-file, ie the new content to be put into the jar.
|
# .class and .prp) that are newer than the jar-file, ie the new content to be put into the jar.
|
||||||
|
@ -520,7 +520,7 @@ define SetupJavaCompilation
|
||||||
# Using plain javac to batch compile everything.
|
# Using plain javac to batch compile everything.
|
||||||
$1 := $$($1_ALL_COPY_TARGETS) $$($1_ALL_COPY_CLEAN_TARGETS) $$($1_BIN)/_the.batch
|
$1 := $$($1_ALL_COPY_TARGETS) $$($1_ALL_COPY_CLEAN_TARGETS) $$($1_BIN)/_the.batch
|
||||||
|
|
||||||
# When buliding in batch, put headers in a temp dir to filter out those that actually
|
# When building in batch, put headers in a temp dir to filter out those that actually
|
||||||
# changed before copying them to the real header dir.
|
# changed before copying them to the real header dir.
|
||||||
ifneq (,$$($1_HEADERS))
|
ifneq (,$$($1_HEADERS))
|
||||||
$1_HEADERS_ARG := -h $$($1_HEADERS).tmp
|
$1_HEADERS_ARG := -h $$($1_HEADERS).tmp
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
#
|
#
|
||||||
# Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved.
|
# Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
#
|
#
|
||||||
# This code is free software; you can redistribute it and/or modify it
|
# This code is free software; you can redistribute it and/or modify it
|
||||||
|
@ -200,13 +200,8 @@ $(JPRT_ARCHIVE_BUNDLE): bundles
|
||||||
$(RM) $@
|
$(RM) $@
|
||||||
$(CP) $(BUILD_OUTPUT)/bundles/$(JDK_IMAGE_SUBDIR).zip $@
|
$(CP) $(BUILD_OUTPUT)/bundles/$(JDK_IMAGE_SUBDIR).zip $@
|
||||||
|
|
||||||
ifeq ($(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_BITS),solaris-64)
|
SRC_JDK_IMAGE_DIR := $(JDK_IMAGE_DIR)
|
||||||
SRC_JDK_IMAGE_DIR := $(JDK_OVERLAY_IMAGE_DIR)
|
SRC_JRE_IMAGE_DIR := $(JRE_IMAGE_DIR)
|
||||||
SRC_JRE_IMAGE_DIR := $(JRE_OVERLAY_IMAGE_DIR)
|
|
||||||
else
|
|
||||||
SRC_JDK_IMAGE_DIR := $(JDK_IMAGE_DIR)
|
|
||||||
SRC_JRE_IMAGE_DIR := $(JRE_IMAGE_DIR)
|
|
||||||
endif
|
|
||||||
SRC_JDK_BUNDLE_DIR := $(JDK_BUNDLE_DIR)
|
SRC_JDK_BUNDLE_DIR := $(JDK_BUNDLE_DIR)
|
||||||
SRC_JRE_BUNDLE_DIR := $(JRE_BUNDLE_DIR)
|
SRC_JRE_BUNDLE_DIR := $(JRE_BUNDLE_DIR)
|
||||||
|
|
||||||
|
@ -215,10 +210,10 @@ bundles: all bundles-only
|
||||||
bundles-only: start-make
|
bundles-only: start-make
|
||||||
@$(call TargetEnter)
|
@$(call TargetEnter)
|
||||||
$(MKDIR) -p $(BUILD_OUTPUT)/bundles
|
$(MKDIR) -p $(BUILD_OUTPUT)/bundles
|
||||||
$(CD) $(SRC_JDK_IMAGE_DIR) && $(ZIP) -q -r $(BUILD_OUTPUT)/bundles/$(JDK_IMAGE_SUBDIR).zip .
|
$(CD) $(SRC_JDK_IMAGE_DIR) && $(ZIP) -y -q -r $(BUILD_OUTPUT)/bundles/$(JDK_IMAGE_SUBDIR).zip .
|
||||||
$(CD) $(SRC_JRE_IMAGE_DIR) && $(ZIP) -q -r $(BUILD_OUTPUT)/bundles/$(JRE_IMAGE_SUBDIR).zip .
|
$(CD) $(SRC_JRE_IMAGE_DIR) && $(ZIP) -y -q -r $(BUILD_OUTPUT)/bundles/$(JRE_IMAGE_SUBDIR).zip .
|
||||||
if [ -d $(BUILD_OUTPUT)/install/bundles ] ; then \
|
if [ -d $(BUILD_OUTPUT)/install/bundles ] ; then \
|
||||||
$(CD) $(BUILD_OUTPUT)/install/bundles && $(ZIP) -q -r $(JPRT_ARCHIVE_INSTALL_BUNDLE) . ; \
|
$(CD) $(BUILD_OUTPUT)/install/bundles && $(ZIP) -y -q -r $(JPRT_ARCHIVE_INSTALL_BUNDLE) . ; \
|
||||||
fi
|
fi
|
||||||
@$(call TargetExit)
|
@$(call TargetExit)
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
#
|
#
|
||||||
# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
|
# Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
#
|
#
|
||||||
# This code is free software; you can redistribute it and/or modify it
|
# This code is free software; you can redistribute it and/or modify it
|
||||||
|
@ -68,10 +68,6 @@ default: jdk
|
||||||
all: images docs
|
all: images docs
|
||||||
@$(call CheckIfMakeAtEnd)
|
@$(call CheckIfMakeAtEnd)
|
||||||
|
|
||||||
ifeq ($(OPENJDK_TARGET_OS)-$(OPENJDK_TARGET_CPU_BITS),solaris-64)
|
|
||||||
all: overlay-images
|
|
||||||
endif
|
|
||||||
|
|
||||||
# Setup a rule for SPEC file that fails if executed. This check makes sure the configuration
|
# Setup a rule for SPEC file that fails if executed. This check makes sure the configuration
|
||||||
# is up to date after changes to configure
|
# is up to date after changes to configure
|
||||||
$(SPEC): $(wildcard $(SRC_ROOT)/common/autoconf/*)
|
$(SPEC): $(wildcard $(SRC_ROOT)/common/autoconf/*)
|
||||||
|
|
|
@ -229,3 +229,6 @@ d411c60a8c2fe8fdc572af907775e90f7eefd513 jdk8-b104
|
||||||
4e38de7c767e34104fa147b5b346d9fe6b731279 jdk8-b105
|
4e38de7c767e34104fa147b5b346d9fe6b731279 jdk8-b105
|
||||||
2e3a056c84a71eba78945c18b05397858ffd7ad0 jdk8-b106
|
2e3a056c84a71eba78945c18b05397858ffd7ad0 jdk8-b106
|
||||||
23fc34133152692b725db4bd617b4c8dfd6ccb05 jdk8-b107
|
23fc34133152692b725db4bd617b4c8dfd6ccb05 jdk8-b107
|
||||||
|
a4bb3b4500164748a9c33b2283cfda76d89f25ab jdk8-b108
|
||||||
|
428428cf5e06163322144cfb5367e1faa86acf20 jdk8-b109
|
||||||
|
3d2b7ce93c5c2e3db748f29c3d29620a8b3b748a jdk8-b110
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
#
|
#
|
||||||
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
|
# Copyright (c) 2006, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
#
|
#
|
||||||
# This code is free software; you can redistribute it and/or modify it
|
# This code is free software; you can redistribute it and/or modify it
|
||||||
|
@ -39,8 +39,8 @@ jprt.build.targets= \
|
||||||
solaris_x64_5.10-{product|fastdebug}, \
|
solaris_x64_5.10-{product|fastdebug}, \
|
||||||
linux_i586_2.6-{product|fastdebug}, \
|
linux_i586_2.6-{product|fastdebug}, \
|
||||||
linux_x64_2.6-{product|fastdebug}, \
|
linux_x64_2.6-{product|fastdebug}, \
|
||||||
windows_i586_5.1-{product|fastdebug}, \
|
windows_i586_6.1-{product|fastdebug}, \
|
||||||
windows_x64_5.2-{product|fastdebug}
|
windows_x64_6.1-{product|fastdebug}
|
||||||
|
|
||||||
# Directories to be excluded from the source bundles
|
# Directories to be excluded from the source bundles
|
||||||
jprt.bundle.exclude.src.dirs=build dist webrev
|
jprt.bundle.exclude.src.dirs=build dist webrev
|
||||||
|
|
|
@ -32,6 +32,7 @@ import java.net.SocketException;
|
||||||
import java.net.ServerSocket;
|
import java.net.ServerSocket;
|
||||||
import java.nio.channels.SocketChannel;
|
import java.nio.channels.SocketChannel;
|
||||||
import java.nio.channels.ServerSocketChannel;
|
import java.nio.channels.ServerSocketChannel;
|
||||||
|
import java.security.PrivilegedAction;
|
||||||
|
|
||||||
import com.sun.corba.se.pept.transport.Acceptor;
|
import com.sun.corba.se.pept.transport.Acceptor;
|
||||||
|
|
||||||
|
@ -44,6 +45,22 @@ public class DefaultSocketFactoryImpl
|
||||||
implements ORBSocketFactory
|
implements ORBSocketFactory
|
||||||
{
|
{
|
||||||
private ORB orb;
|
private ORB orb;
|
||||||
|
private static final boolean keepAlive;
|
||||||
|
|
||||||
|
static {
|
||||||
|
keepAlive = java.security.AccessController.doPrivileged(
|
||||||
|
new PrivilegedAction<Boolean>() {
|
||||||
|
@Override
|
||||||
|
public Boolean run () {
|
||||||
|
String value =
|
||||||
|
System.getProperty("com.sun.CORBA.transport.enableTcpKeepAlive");
|
||||||
|
if (value != null)
|
||||||
|
return new Boolean(!"false".equalsIgnoreCase(value));
|
||||||
|
|
||||||
|
return Boolean.FALSE;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
public void setORB(ORB orb)
|
public void setORB(ORB orb)
|
||||||
{
|
{
|
||||||
|
@ -85,6 +102,9 @@ public class DefaultSocketFactoryImpl
|
||||||
// Disable Nagle's algorithm (i.e., always send immediately).
|
// Disable Nagle's algorithm (i.e., always send immediately).
|
||||||
socket.setTcpNoDelay(true);
|
socket.setTcpNoDelay(true);
|
||||||
|
|
||||||
|
if (keepAlive)
|
||||||
|
socket.setKeepAlive(true);
|
||||||
|
|
||||||
return socket;
|
return socket;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -95,6 +115,8 @@ public class DefaultSocketFactoryImpl
|
||||||
{
|
{
|
||||||
// Disable Nagle's algorithm (i.e., always send immediately).
|
// Disable Nagle's algorithm (i.e., always send immediately).
|
||||||
socket.setTcpNoDelay(true);
|
socket.setTcpNoDelay(true);
|
||||||
|
if (keepAlive)
|
||||||
|
socket.setKeepAlive(true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -375,3 +375,11 @@ acac3bde66b2c22791c257a8d99611d6d08c6713 jdk8-b105
|
||||||
18b4798adbc42c6fa16f5ecb7d5cd3ca130754bf hs25-b48
|
18b4798adbc42c6fa16f5ecb7d5cd3ca130754bf hs25-b48
|
||||||
aed585cafc0d9655726af6d1e1081d1c94cb3b5c jdk8-b106
|
aed585cafc0d9655726af6d1e1081d1c94cb3b5c jdk8-b106
|
||||||
50794d8ac11c9579b41dec4de23b808fef9f34a1 hs25-b49
|
50794d8ac11c9579b41dec4de23b808fef9f34a1 hs25-b49
|
||||||
|
5b7f90aab3ad25a25b75b7b2bb18d5ae23d8231c jdk8-b107
|
||||||
|
a09fe9d1e016c285307507a5793bc4fa6215e9c9 hs25-b50
|
||||||
|
85072013aad46050a362d10ab78e963121c8014c jdk8-b108
|
||||||
|
566db1b0e6efca31f181456e54c8911d0192410d hs25-b51
|
||||||
|
c81dd5393a5e333df7cb1f6621f5897ada6522b5 jdk8-b109
|
||||||
|
58043478c26d4e8bf48700acea5f97aba8b417d4 hs25-b52
|
||||||
|
6209b0ed51c086d4127bac0e086c8f326d1764d7 jdk8-b110
|
||||||
|
562a3d356de67670b4172b82aca2d30743449e04 hs25-b53
|
||||||
|
|
|
@ -29,6 +29,7 @@
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
|
#include <stdlib.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <limits.h>
|
#include <limits.h>
|
||||||
|
|
||||||
|
@ -80,7 +81,7 @@ JNIEXPORT void JNICALL Java_sun_jvm_hotspot_debugger_linux_LinuxDebuggerLocal_in
|
||||||
(JNIEnv *env, jclass cls) {
|
(JNIEnv *env, jclass cls) {
|
||||||
jclass listClass;
|
jclass listClass;
|
||||||
|
|
||||||
if (init_libproc(getenv("LIBSAPROC_DEBUG")) != true) {
|
if (init_libproc(getenv("LIBSAPROC_DEBUG") != NULL) != true) {
|
||||||
THROW_NEW_DEBUGGER_EXCEPTION("can't initialize libproc");
|
THROW_NEW_DEBUGGER_EXCEPTION("can't initialize libproc");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
|
@ -698,29 +698,58 @@ err:
|
||||||
|
|
||||||
// read segments of a shared object
|
// read segments of a shared object
|
||||||
static bool read_lib_segments(struct ps_prochandle* ph, int lib_fd, ELF_EHDR* lib_ehdr, uintptr_t lib_base) {
|
static bool read_lib_segments(struct ps_prochandle* ph, int lib_fd, ELF_EHDR* lib_ehdr, uintptr_t lib_base) {
|
||||||
int i = 0;
|
int i = 0;
|
||||||
ELF_PHDR* phbuf;
|
ELF_PHDR* phbuf;
|
||||||
ELF_PHDR* lib_php = NULL;
|
ELF_PHDR* lib_php = NULL;
|
||||||
|
|
||||||
if ((phbuf = read_program_header_table(lib_fd, lib_ehdr)) == NULL)
|
int page_size=sysconf(_SC_PAGE_SIZE);
|
||||||
return false;
|
|
||||||
|
|
||||||
// we want to process only PT_LOAD segments that are not writable.
|
if ((phbuf = read_program_header_table(lib_fd, lib_ehdr)) == NULL) {
|
||||||
// i.e., text segments. The read/write/exec (data) segments would
|
return false;
|
||||||
// have been already added from core file segments.
|
}
|
||||||
for (lib_php = phbuf, i = 0; i < lib_ehdr->e_phnum; i++) {
|
|
||||||
if ((lib_php->p_type == PT_LOAD) && !(lib_php->p_flags & PF_W) && (lib_php->p_filesz != 0)) {
|
// we want to process only PT_LOAD segments that are not writable.
|
||||||
if (add_map_info(ph, lib_fd, lib_php->p_offset, lib_php->p_vaddr + lib_base, lib_php->p_filesz) == NULL)
|
// i.e., text segments. The read/write/exec (data) segments would
|
||||||
goto err;
|
// have been already added from core file segments.
|
||||||
|
for (lib_php = phbuf, i = 0; i < lib_ehdr->e_phnum; i++) {
|
||||||
|
if ((lib_php->p_type == PT_LOAD) && !(lib_php->p_flags & PF_W) && (lib_php->p_filesz != 0)) {
|
||||||
|
|
||||||
|
uintptr_t target_vaddr = lib_php->p_vaddr + lib_base;
|
||||||
|
map_info *existing_map = core_lookup(ph, target_vaddr);
|
||||||
|
|
||||||
|
if (existing_map == NULL){
|
||||||
|
if (add_map_info(ph, lib_fd, lib_php->p_offset,
|
||||||
|
target_vaddr, lib_php->p_filesz) == NULL) {
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if ((existing_map->memsz != page_size) &&
|
||||||
|
(existing_map->fd != lib_fd) &&
|
||||||
|
(existing_map->memsz != lib_php->p_filesz)){
|
||||||
|
|
||||||
|
print_debug("address conflict @ 0x%lx (size = %ld, flags = %d\n)",
|
||||||
|
target_vaddr, lib_php->p_filesz, lib_php->p_flags);
|
||||||
|
goto err;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* replace PT_LOAD segment with library segment */
|
||||||
|
print_debug("overwrote with new address mapping (memsz %ld -> %ld)\n",
|
||||||
|
existing_map->memsz, lib_php->p_filesz);
|
||||||
|
|
||||||
|
existing_map->fd = lib_fd;
|
||||||
|
existing_map->offset = lib_php->p_offset;
|
||||||
|
existing_map->memsz = lib_php->p_filesz;
|
||||||
}
|
}
|
||||||
lib_php++;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
free(phbuf);
|
lib_php++;
|
||||||
return true;
|
}
|
||||||
|
|
||||||
|
free(phbuf);
|
||||||
|
return true;
|
||||||
err:
|
err:
|
||||||
free(phbuf);
|
free(phbuf);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
// process segments from interpreter (ld.so or ld-linux.so)
|
// process segments from interpreter (ld.so or ld-linux.so)
|
||||||
|
|
|
@ -27,6 +27,8 @@
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
|
#include <sys/types.h>
|
||||||
|
#include <sys/wait.h>
|
||||||
#include <sys/ptrace.h>
|
#include <sys/ptrace.h>
|
||||||
#include "libproc_impl.h"
|
#include "libproc_impl.h"
|
||||||
|
|
||||||
|
|
|
@ -25,6 +25,7 @@
|
||||||
#include "salibelf.h"
|
#include "salibelf.h"
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
extern void print_debug(const char*,...);
|
extern void print_debug(const char*,...);
|
||||||
|
|
||||||
|
|
|
@ -305,7 +305,7 @@ static struct symtab* build_symtab_from_build_id(Elf64_Nhdr *note)
|
||||||
|
|
||||||
unsigned char *bytes
|
unsigned char *bytes
|
||||||
= (unsigned char*)(note+1) + note->n_namesz;
|
= (unsigned char*)(note+1) + note->n_namesz;
|
||||||
unsigned char *filename
|
char *filename
|
||||||
= (build_id_to_debug_filename (note->n_descsz, bytes));
|
= (build_id_to_debug_filename (note->n_descsz, bytes));
|
||||||
|
|
||||||
fd = pathmap_open(filename);
|
fd = pathmap_open(filename);
|
||||||
|
|
|
@ -1213,6 +1213,7 @@ public class CommandProcessor {
|
||||||
}
|
}
|
||||||
HotSpotTypeDataBase db = (HotSpotTypeDataBase)agent.getTypeDataBase();
|
HotSpotTypeDataBase db = (HotSpotTypeDataBase)agent.getTypeDataBase();
|
||||||
if (t.countTokens() == 1) {
|
if (t.countTokens() == 1) {
|
||||||
|
String name = t.nextToken();
|
||||||
out.println("intConstant " + name + " " + db.lookupIntConstant(name));
|
out.println("intConstant " + name + " " + db.lookupIntConstant(name));
|
||||||
} else if (t.countTokens() == 0) {
|
} else if (t.countTokens() == 0) {
|
||||||
Iterator i = db.getIntConstants();
|
Iterator i = db.getIntConstants();
|
||||||
|
@ -1235,6 +1236,7 @@ public class CommandProcessor {
|
||||||
}
|
}
|
||||||
HotSpotTypeDataBase db = (HotSpotTypeDataBase)agent.getTypeDataBase();
|
HotSpotTypeDataBase db = (HotSpotTypeDataBase)agent.getTypeDataBase();
|
||||||
if (t.countTokens() == 1) {
|
if (t.countTokens() == 1) {
|
||||||
|
String name = t.nextToken();
|
||||||
out.println("longConstant " + name + " " + db.lookupLongConstant(name));
|
out.println("longConstant " + name + " " + db.lookupLongConstant(name));
|
||||||
} else if (t.countTokens() == 0) {
|
} else if (t.countTokens() == 0) {
|
||||||
Iterator i = db.getLongConstants();
|
Iterator i = db.getLongConstants();
|
||||||
|
|
|
@ -81,7 +81,7 @@ class BsdAddress implements Address {
|
||||||
|
|
||||||
public Address getCompKlassAddressAt(long offset)
|
public Address getCompKlassAddressAt(long offset)
|
||||||
throws UnalignedAddressException, UnmappedAddressException {
|
throws UnalignedAddressException, UnmappedAddressException {
|
||||||
return debugger.readCompOopAddress(addr + offset);
|
return debugger.readCompKlassAddress(addr + offset);
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
|
|
|
@ -134,15 +134,13 @@ public class VM {
|
||||||
private String type;
|
private String type;
|
||||||
private String name;
|
private String name;
|
||||||
private Address addr;
|
private Address addr;
|
||||||
private String kind;
|
private int flags;
|
||||||
private int origin;
|
|
||||||
|
|
||||||
private Flag(String type, String name, Address addr, String kind, int origin) {
|
private Flag(String type, String name, Address addr, int flags) {
|
||||||
this.type = type;
|
this.type = type;
|
||||||
this.name = name;
|
this.name = name;
|
||||||
this.addr = addr;
|
this.addr = addr;
|
||||||
this.kind = kind;
|
this.flags = flags;
|
||||||
this.origin = origin;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getType() {
|
public String getType() {
|
||||||
|
@ -157,12 +155,8 @@ public class VM {
|
||||||
return addr;
|
return addr;
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getKind() {
|
|
||||||
return kind;
|
|
||||||
}
|
|
||||||
|
|
||||||
public int getOrigin() {
|
public int getOrigin() {
|
||||||
return origin;
|
return flags & 0xF; // XXX can we get the mask bits from somewhere?
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isBool() {
|
public boolean isBool() {
|
||||||
|
@ -173,8 +167,7 @@ public class VM {
|
||||||
if (Assert.ASSERTS_ENABLED) {
|
if (Assert.ASSERTS_ENABLED) {
|
||||||
Assert.that(isBool(), "not a bool flag!");
|
Assert.that(isBool(), "not a bool flag!");
|
||||||
}
|
}
|
||||||
return addr.getCIntegerAt(0, boolType.getSize(), boolType.isUnsigned())
|
return addr.getCIntegerAt(0, boolType.getSize(), boolType.isUnsigned()) != 0;
|
||||||
!= 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isIntx() {
|
public boolean isIntx() {
|
||||||
|
@ -792,7 +785,7 @@ public class VM {
|
||||||
|
|
||||||
public boolean isCompressedKlassPointersEnabled() {
|
public boolean isCompressedKlassPointersEnabled() {
|
||||||
if (compressedKlassPointersEnabled == null) {
|
if (compressedKlassPointersEnabled == null) {
|
||||||
Flag flag = getCommandLineFlag("UseCompressedKlassPointers");
|
Flag flag = getCommandLineFlag("UseCompressedClassPointers");
|
||||||
compressedKlassPointersEnabled = (flag == null) ? Boolean.FALSE:
|
compressedKlassPointersEnabled = (flag == null) ? Boolean.FALSE:
|
||||||
(flag.getBool()? Boolean.TRUE: Boolean.FALSE);
|
(flag.getBool()? Boolean.TRUE: Boolean.FALSE);
|
||||||
}
|
}
|
||||||
|
@ -843,11 +836,10 @@ public class VM {
|
||||||
|
|
||||||
Address flagAddr = flagType.getAddressField("flags").getValue();
|
Address flagAddr = flagType.getAddressField("flags").getValue();
|
||||||
|
|
||||||
AddressField typeFld = flagType.getAddressField("type");
|
AddressField typeFld = flagType.getAddressField("_type");
|
||||||
AddressField nameFld = flagType.getAddressField("name");
|
AddressField nameFld = flagType.getAddressField("_name");
|
||||||
AddressField addrFld = flagType.getAddressField("addr");
|
AddressField addrFld = flagType.getAddressField("_addr");
|
||||||
AddressField kindFld = flagType.getAddressField("kind");
|
CIntField flagsFld = new CIntField(flagType.getCIntegerField("_flags"), 0);
|
||||||
CIntField originFld = new CIntField(flagType.getCIntegerField("origin"), 0);
|
|
||||||
|
|
||||||
long flagSize = flagType.getSize(); // sizeof(Flag)
|
long flagSize = flagType.getSize(); // sizeof(Flag)
|
||||||
|
|
||||||
|
@ -856,9 +848,8 @@ public class VM {
|
||||||
String type = CStringUtilities.getString(typeFld.getValue(flagAddr));
|
String type = CStringUtilities.getString(typeFld.getValue(flagAddr));
|
||||||
String name = CStringUtilities.getString(nameFld.getValue(flagAddr));
|
String name = CStringUtilities.getString(nameFld.getValue(flagAddr));
|
||||||
Address addr = addrFld.getValue(flagAddr);
|
Address addr = addrFld.getValue(flagAddr);
|
||||||
String kind = CStringUtilities.getString(kindFld.getValue(flagAddr));
|
int flags = (int)flagsFld.getValue(flagAddr);
|
||||||
int origin = (int)originFld.getValue(flagAddr);
|
commandLineFlags[f] = new Flag(type, name, addr, flags);
|
||||||
commandLineFlags[f] = new Flag(type, name, addr, kind, origin);
|
|
||||||
flagAddr = flagAddr.addOffsetTo(flagSize);
|
flagAddr = flagAddr.addOffsetTo(flagSize);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -66,18 +66,18 @@ public class HeapSummary extends Tool {
|
||||||
printGCAlgorithm(flagMap);
|
printGCAlgorithm(flagMap);
|
||||||
System.out.println();
|
System.out.println();
|
||||||
System.out.println("Heap Configuration:");
|
System.out.println("Heap Configuration:");
|
||||||
printValue("MinHeapFreeRatio = ", getFlagValue("MinHeapFreeRatio", flagMap));
|
printValue("MinHeapFreeRatio = ", getFlagValue("MinHeapFreeRatio", flagMap));
|
||||||
printValue("MaxHeapFreeRatio = ", getFlagValue("MaxHeapFreeRatio", flagMap));
|
printValue("MaxHeapFreeRatio = ", getFlagValue("MaxHeapFreeRatio", flagMap));
|
||||||
printValMB("MaxHeapSize = ", getFlagValue("MaxHeapSize", flagMap));
|
printValMB("MaxHeapSize = ", getFlagValue("MaxHeapSize", flagMap));
|
||||||
printValMB("NewSize = ", getFlagValue("NewSize", flagMap));
|
printValMB("NewSize = ", getFlagValue("NewSize", flagMap));
|
||||||
printValMB("MaxNewSize = ", getFlagValue("MaxNewSize", flagMap));
|
printValMB("MaxNewSize = ", getFlagValue("MaxNewSize", flagMap));
|
||||||
printValMB("OldSize = ", getFlagValue("OldSize", flagMap));
|
printValMB("OldSize = ", getFlagValue("OldSize", flagMap));
|
||||||
printValue("NewRatio = ", getFlagValue("NewRatio", flagMap));
|
printValue("NewRatio = ", getFlagValue("NewRatio", flagMap));
|
||||||
printValue("SurvivorRatio = ", getFlagValue("SurvivorRatio", flagMap));
|
printValue("SurvivorRatio = ", getFlagValue("SurvivorRatio", flagMap));
|
||||||
printValMB("MetaspaceSize = ", getFlagValue("MetaspaceSize", flagMap));
|
printValMB("MetaspaceSize = ", getFlagValue("MetaspaceSize", flagMap));
|
||||||
printValMB("ClassMetaspaceSize = ", getFlagValue("ClassMetaspaceSize", flagMap));
|
printValMB("CompressedClassSpaceSize = ", getFlagValue("CompressedClassSpaceSize", flagMap));
|
||||||
printValMB("MaxMetaspaceSize = ", getFlagValue("MaxMetaspaceSize", flagMap));
|
printValMB("MaxMetaspaceSize = ", getFlagValue("MaxMetaspaceSize", flagMap));
|
||||||
printValMB("G1HeapRegionSize = ", HeapRegion.grainBytes());
|
printValMB("G1HeapRegionSize = ", HeapRegion.grainBytes());
|
||||||
|
|
||||||
System.out.println();
|
System.out.println();
|
||||||
System.out.println("Heap Usage:");
|
System.out.println("Heap Usage:");
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
#
|
#
|
||||||
# Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
|
# Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
#
|
#
|
||||||
# This code is free software; you can redistribute it and/or modify it
|
# This code is free software; you can redistribute it and/or modify it
|
||||||
|
@ -59,5 +59,5 @@ CFLAGS$(HOTSPARC_GENERIC) += $(OPT_CFLAGS/BYFILE)
|
||||||
MAPFILE = $(GAMMADIR)/make/bsd/makefiles/mapfile-vers-debug
|
MAPFILE = $(GAMMADIR)/make/bsd/makefiles/mapfile-vers-debug
|
||||||
|
|
||||||
VERSION = fastdebug
|
VERSION = fastdebug
|
||||||
SYSDEFS += -DASSERT
|
SYSDEFS += -DASSERT -DCHECK_UNHANDLED_OOPS
|
||||||
PICFLAGS = DEFAULT
|
PICFLAGS = DEFAULT
|
||||||
|
|
|
@ -80,7 +80,7 @@ ifeq ($(SPEC),)
|
||||||
HOSTCC = $(CC)
|
HOSTCC = $(CC)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
AS = $(CC) -c -x assembler-with-cpp
|
AS = $(CC) -c
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
|
||||||
|
@ -247,7 +247,7 @@ endif
|
||||||
|
|
||||||
ifeq ($(USE_CLANG), true)
|
ifeq ($(USE_CLANG), true)
|
||||||
# However we need to clean the code up before we can unrestrictedly enable this option with Clang
|
# However we need to clean the code up before we can unrestrictedly enable this option with Clang
|
||||||
WARNINGS_ARE_ERRORS += -Wno-unused-value -Wno-logical-op-parentheses -Wno-parentheses-equality -Wno-parentheses
|
WARNINGS_ARE_ERRORS += -Wno-logical-op-parentheses -Wno-parentheses-equality -Wno-parentheses
|
||||||
WARNINGS_ARE_ERRORS += -Wno-switch -Wno-tautological-compare
|
WARNINGS_ARE_ERRORS += -Wno-switch -Wno-tautological-compare
|
||||||
# Not yet supported by clang in Xcode 4.6.2
|
# Not yet supported by clang in Xcode 4.6.2
|
||||||
# WARNINGS_ARE_ERRORS += -Wno-tautological-constant-out-of-range-compare
|
# WARNINGS_ARE_ERRORS += -Wno-tautological-constant-out-of-range-compare
|
||||||
|
@ -262,7 +262,7 @@ ifeq "$(shell expr \( $(CC_VER_MAJOR) \> 4 \) \| \( \( $(CC_VER_MAJOR) = 4 \) \&
|
||||||
# conversions which might affect the values. Only enable it in earlier versions.
|
# conversions which might affect the values. Only enable it in earlier versions.
|
||||||
WARNING_FLAGS = -Wunused-function
|
WARNING_FLAGS = -Wunused-function
|
||||||
ifeq ($(USE_CLANG),)
|
ifeq ($(USE_CLANG),)
|
||||||
WARNINGS_FLAGS += -Wconversion
|
WARNING_FLAGS += -Wconversion
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
@ -347,6 +347,13 @@ ifeq ($(OS_VENDOR), Darwin)
|
||||||
LDFLAGS += -mmacosx-version-min=$(MACOSX_VERSION_MIN)
|
LDFLAGS += -mmacosx-version-min=$(MACOSX_VERSION_MIN)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
|
||||||
|
#------------------------------------------------------------------------
|
||||||
|
# Assembler flags
|
||||||
|
|
||||||
|
# Enforce prerpocessing of .s files
|
||||||
|
ASFLAGS += -x assembler-with-cpp
|
||||||
|
|
||||||
#------------------------------------------------------------------------
|
#------------------------------------------------------------------------
|
||||||
# Linker flags
|
# Linker flags
|
||||||
|
|
||||||
|
|
|
@ -88,7 +88,7 @@ ifeq ($(INCLUDE_ALL_GCS), false)
|
||||||
g1ErgoVerbose.cpp g1GCPhaseTimes.cpp g1HRPrinter.cpp g1HotCardCache.cpp g1Log.cpp \
|
g1ErgoVerbose.cpp g1GCPhaseTimes.cpp g1HRPrinter.cpp g1HotCardCache.cpp g1Log.cpp \
|
||||||
g1MMUTracker.cpp g1MarkSweep.cpp g1MemoryPool.cpp g1MonitoringSupport.cpp \
|
g1MMUTracker.cpp g1MarkSweep.cpp g1MemoryPool.cpp g1MonitoringSupport.cpp \
|
||||||
g1RemSet.cpp g1RemSetSummary.cpp g1SATBCardTableModRefBS.cpp g1_globals.cpp heapRegion.cpp \
|
g1RemSet.cpp g1RemSetSummary.cpp g1SATBCardTableModRefBS.cpp g1_globals.cpp heapRegion.cpp \
|
||||||
heapRegionRemSet.cpp heapRegionSeq.cpp heapRegionSet.cpp heapRegionSets.cpp \
|
g1BiasedArray.cpp heapRegionRemSet.cpp heapRegionSeq.cpp heapRegionSet.cpp heapRegionSets.cpp \
|
||||||
ptrQueue.cpp satbQueue.cpp sparsePRT.cpp survRateGroup.cpp vm_operations_g1.cpp \
|
ptrQueue.cpp satbQueue.cpp sparsePRT.cpp survRateGroup.cpp vm_operations_g1.cpp \
|
||||||
adjoiningGenerations.cpp adjoiningVirtualSpaces.cpp asPSOldGen.cpp asPSYoungGen.cpp \
|
adjoiningGenerations.cpp adjoiningVirtualSpaces.cpp asPSOldGen.cpp asPSYoungGen.cpp \
|
||||||
cardTableExtension.cpp gcTaskManager.cpp gcTaskThread.cpp objectStartArray.cpp \
|
cardTableExtension.cpp gcTaskManager.cpp gcTaskThread.cpp objectStartArray.cpp \
|
||||||
|
@ -99,7 +99,7 @@ ifeq ($(INCLUDE_ALL_GCS), false)
|
||||||
psTasks.cpp psVirtualspace.cpp psYoungGen.cpp vmPSOperations.cpp asParNewGeneration.cpp \
|
psTasks.cpp psVirtualspace.cpp psYoungGen.cpp vmPSOperations.cpp asParNewGeneration.cpp \
|
||||||
parCardTableModRefBS.cpp parGCAllocBuffer.cpp parNewGeneration.cpp mutableSpace.cpp \
|
parCardTableModRefBS.cpp parGCAllocBuffer.cpp parNewGeneration.cpp mutableSpace.cpp \
|
||||||
gSpaceCounters.cpp allocationStats.cpp spaceCounters.cpp gcAdaptivePolicyCounters.cpp \
|
gSpaceCounters.cpp allocationStats.cpp spaceCounters.cpp gcAdaptivePolicyCounters.cpp \
|
||||||
mutableNUMASpace.cpp immutableSpace.cpp yieldingWorkGroup.cpp
|
mutableNUMASpace.cpp immutableSpace.cpp yieldingWorkGroup.cpp hSpaceCounters.cpp
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(INCLUDE_NMT), false)
|
ifeq ($(INCLUDE_NMT), false)
|
||||||
|
|
|
@ -35,7 +35,7 @@ HOTSPOT_VM_COPYRIGHT=Copyright 2013
|
||||||
|
|
||||||
HS_MAJOR_VER=25
|
HS_MAJOR_VER=25
|
||||||
HS_MINOR_VER=0
|
HS_MINOR_VER=0
|
||||||
HS_BUILD_NUMBER=49
|
HS_BUILD_NUMBER=53
|
||||||
|
|
||||||
JDK_MAJOR_VER=1
|
JDK_MAJOR_VER=1
|
||||||
JDK_MINOR_VER=8
|
JDK_MINOR_VER=8
|
||||||
|
|
|
@ -120,13 +120,13 @@ jprt.my.macosx.x64.jdk7=macosx_x64_10.7
|
||||||
jprt.my.macosx.x64.jdk7u8=${jprt.my.macosx.x64.jdk7}
|
jprt.my.macosx.x64.jdk7u8=${jprt.my.macosx.x64.jdk7}
|
||||||
jprt.my.macosx.x64=${jprt.my.macosx.x64.${jprt.tools.default.release}}
|
jprt.my.macosx.x64=${jprt.my.macosx.x64.${jprt.tools.default.release}}
|
||||||
|
|
||||||
jprt.my.windows.i586.jdk8=windows_i586_5.1
|
jprt.my.windows.i586.jdk8=windows_i586_6.1
|
||||||
jprt.my.windows.i586.jdk7=windows_i586_5.1
|
jprt.my.windows.i586.jdk7=windows_i586_6.1
|
||||||
jprt.my.windows.i586.jdk7u8=${jprt.my.windows.i586.jdk7}
|
jprt.my.windows.i586.jdk7u8=${jprt.my.windows.i586.jdk7}
|
||||||
jprt.my.windows.i586=${jprt.my.windows.i586.${jprt.tools.default.release}}
|
jprt.my.windows.i586=${jprt.my.windows.i586.${jprt.tools.default.release}}
|
||||||
|
|
||||||
jprt.my.windows.x64.jdk8=windows_x64_5.2
|
jprt.my.windows.x64.jdk8=windows_x64_6.1
|
||||||
jprt.my.windows.x64.jdk7=windows_x64_5.2
|
jprt.my.windows.x64.jdk7=windows_x64_6.1
|
||||||
jprt.my.windows.x64.jdk7u8=${jprt.my.windows.x64.jdk7}
|
jprt.my.windows.x64.jdk7u8=${jprt.my.windows.x64.jdk7}
|
||||||
jprt.my.windows.x64=${jprt.my.windows.x64.${jprt.tools.default.release}}
|
jprt.my.windows.x64=${jprt.my.windows.x64.${jprt.tools.default.release}}
|
||||||
|
|
||||||
|
|
|
@ -59,5 +59,5 @@ CFLAGS$(HOTSPARC_GENERIC) += $(OPT_CFLAGS/BYFILE)
|
||||||
MAPFILE = $(GAMMADIR)/make/linux/makefiles/mapfile-vers-debug
|
MAPFILE = $(GAMMADIR)/make/linux/makefiles/mapfile-vers-debug
|
||||||
|
|
||||||
VERSION = optimized
|
VERSION = optimized
|
||||||
SYSDEFS += -DASSERT
|
SYSDEFS += -DASSERT -DCHECK_UNHANDLED_OOPS
|
||||||
PICFLAGS = DEFAULT
|
PICFLAGS = DEFAULT
|
||||||
|
|
|
@ -208,7 +208,7 @@ WARNINGS_ARE_ERRORS = -Werror
|
||||||
|
|
||||||
ifeq ($(USE_CLANG), true)
|
ifeq ($(USE_CLANG), true)
|
||||||
# However we need to clean the code up before we can unrestrictedly enable this option with Clang
|
# However we need to clean the code up before we can unrestrictedly enable this option with Clang
|
||||||
WARNINGS_ARE_ERRORS += -Wno-unused-value -Wno-logical-op-parentheses -Wno-parentheses-equality -Wno-parentheses
|
WARNINGS_ARE_ERRORS += -Wno-logical-op-parentheses -Wno-parentheses-equality -Wno-parentheses
|
||||||
WARNINGS_ARE_ERRORS += -Wno-switch -Wno-tautological-constant-out-of-range-compare -Wno-tautological-compare
|
WARNINGS_ARE_ERRORS += -Wno-switch -Wno-tautological-constant-out-of-range-compare -Wno-tautological-compare
|
||||||
WARNINGS_ARE_ERRORS += -Wno-delete-non-virtual-dtor -Wno-deprecated -Wno-format -Wno-dynamic-class-memaccess
|
WARNINGS_ARE_ERRORS += -Wno-delete-non-virtual-dtor -Wno-deprecated -Wno-format -Wno-dynamic-class-memaccess
|
||||||
WARNINGS_ARE_ERRORS += -Wno-return-type -Wno-empty-body
|
WARNINGS_ARE_ERRORS += -Wno-return-type -Wno-empty-body
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
#
|
#
|
||||||
# Copyright (c) 2005, 2012, Oracle and/or its affiliates. All rights reserved.
|
# Copyright (c) 2005, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
#
|
#
|
||||||
# This code is free software; you can redistribute it and/or modify it
|
# This code is free software; you can redistribute it and/or modify it
|
||||||
|
@ -38,7 +38,7 @@ default:: $(BUILD_PCH_FILE) $(AOUT) checkAndBuildSA
|
||||||
!include ../local.make
|
!include ../local.make
|
||||||
!include compile.make
|
!include compile.make
|
||||||
|
|
||||||
CXX_FLAGS=$(CXX_FLAGS) $(FASTDEBUG_OPT_OPTION)
|
CXX_FLAGS=$(CXX_FLAGS) $(FASTDEBUG_OPT_OPTION) /D "CHECK_UNHANDLED_OOPS"
|
||||||
|
|
||||||
!include $(WorkSpace)/make/windows/makefiles/vm.make
|
!include $(WorkSpace)/make/windows/makefiles/vm.make
|
||||||
!include local.make
|
!include local.make
|
||||||
|
|
|
@ -105,7 +105,7 @@ bool LIR_Assembler::is_single_instruction(LIR_Op* op) {
|
||||||
if (src->is_address() && !src->is_stack() && (src->type() == T_OBJECT || src->type() == T_ARRAY)) return false;
|
if (src->is_address() && !src->is_stack() && (src->type() == T_OBJECT || src->type() == T_ARRAY)) return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
if (src->is_address() && !src->is_stack() && src->type() == T_ADDRESS &&
|
if (src->is_address() && !src->is_stack() && src->type() == T_ADDRESS &&
|
||||||
src->as_address_ptr()->disp() == oopDesc::klass_offset_in_bytes()) return false;
|
src->as_address_ptr()->disp() == oopDesc::klass_offset_in_bytes()) return false;
|
||||||
}
|
}
|
||||||
|
@ -963,7 +963,7 @@ int LIR_Assembler::load(Register base, int offset, LIR_Opr to_reg, BasicType typ
|
||||||
case T_METADATA: __ ld_ptr(base, offset, to_reg->as_register()); break;
|
case T_METADATA: __ ld_ptr(base, offset, to_reg->as_register()); break;
|
||||||
case T_ADDRESS:
|
case T_ADDRESS:
|
||||||
#ifdef _LP64
|
#ifdef _LP64
|
||||||
if (offset == oopDesc::klass_offset_in_bytes() && UseCompressedKlassPointers) {
|
if (offset == oopDesc::klass_offset_in_bytes() && UseCompressedClassPointers) {
|
||||||
__ lduw(base, offset, to_reg->as_register());
|
__ lduw(base, offset, to_reg->as_register());
|
||||||
__ decode_klass_not_null(to_reg->as_register());
|
__ decode_klass_not_null(to_reg->as_register());
|
||||||
} else
|
} else
|
||||||
|
@ -2208,7 +2208,7 @@ void LIR_Assembler::emit_arraycopy(LIR_OpArrayCopy* op) {
|
||||||
// We don't know the array types are compatible
|
// We don't know the array types are compatible
|
||||||
if (basic_type != T_OBJECT) {
|
if (basic_type != T_OBJECT) {
|
||||||
// Simple test for basic type arrays
|
// Simple test for basic type arrays
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
// We don't need decode because we just need to compare
|
// We don't need decode because we just need to compare
|
||||||
__ lduw(src, oopDesc::klass_offset_in_bytes(), tmp);
|
__ lduw(src, oopDesc::klass_offset_in_bytes(), tmp);
|
||||||
__ lduw(dst, oopDesc::klass_offset_in_bytes(), tmp2);
|
__ lduw(dst, oopDesc::klass_offset_in_bytes(), tmp2);
|
||||||
|
@ -2342,7 +2342,7 @@ void LIR_Assembler::emit_arraycopy(LIR_OpArrayCopy* op) {
|
||||||
// but not necessarily exactly of type default_type.
|
// but not necessarily exactly of type default_type.
|
||||||
Label known_ok, halt;
|
Label known_ok, halt;
|
||||||
metadata2reg(op->expected_type()->constant_encoding(), tmp);
|
metadata2reg(op->expected_type()->constant_encoding(), tmp);
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
// tmp holds the default type. It currently comes uncompressed after the
|
// tmp holds the default type. It currently comes uncompressed after the
|
||||||
// load of a constant, so encode it.
|
// load of a constant, so encode it.
|
||||||
__ encode_klass_not_null(tmp);
|
__ encode_klass_not_null(tmp);
|
||||||
|
|
|
@ -186,7 +186,7 @@ void C1_MacroAssembler::initialize_header(Register obj, Register klass, Register
|
||||||
set((intx)markOopDesc::prototype(), t1);
|
set((intx)markOopDesc::prototype(), t1);
|
||||||
}
|
}
|
||||||
st_ptr(t1, obj, oopDesc::mark_offset_in_bytes());
|
st_ptr(t1, obj, oopDesc::mark_offset_in_bytes());
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
// Save klass
|
// Save klass
|
||||||
mov(klass, t1);
|
mov(klass, t1);
|
||||||
encode_klass_not_null(t1);
|
encode_klass_not_null(t1);
|
||||||
|
@ -196,7 +196,7 @@ void C1_MacroAssembler::initialize_header(Register obj, Register klass, Register
|
||||||
}
|
}
|
||||||
if (len->is_valid()) {
|
if (len->is_valid()) {
|
||||||
st(len, obj, arrayOopDesc::length_offset_in_bytes());
|
st(len, obj, arrayOopDesc::length_offset_in_bytes());
|
||||||
} else if (UseCompressedKlassPointers) {
|
} else if (UseCompressedClassPointers) {
|
||||||
// otherwise length is in the class gap
|
// otherwise length is in the class gap
|
||||||
store_klass_gap(G0, obj);
|
store_klass_gap(G0, obj);
|
||||||
}
|
}
|
||||||
|
|
|
@ -57,6 +57,7 @@ define_pd_global(intx, RegisterCostAreaRatio, 12000);
|
||||||
define_pd_global(bool, UseTLAB, true);
|
define_pd_global(bool, UseTLAB, true);
|
||||||
define_pd_global(bool, ResizeTLAB, true);
|
define_pd_global(bool, ResizeTLAB, true);
|
||||||
define_pd_global(intx, LoopUnrollLimit, 60); // Design center runs on 1.3.1
|
define_pd_global(intx, LoopUnrollLimit, 60); // Design center runs on 1.3.1
|
||||||
|
define_pd_global(intx, MinJumpTableSize, 5);
|
||||||
|
|
||||||
// Peephole and CISC spilling both break the graph, and so makes the
|
// Peephole and CISC spilling both break the graph, and so makes the
|
||||||
// scheduler sick.
|
// scheduler sick.
|
||||||
|
|
|
@ -764,7 +764,7 @@ BasicType frame::interpreter_frame_result(oop* oop_result, jvalue* value_result)
|
||||||
#ifdef CC_INTERP
|
#ifdef CC_INTERP
|
||||||
*oop_result = istate->_oop_temp;
|
*oop_result = istate->_oop_temp;
|
||||||
#else
|
#else
|
||||||
oop obj = (oop) at(interpreter_frame_oop_temp_offset);
|
oop obj = cast_to_oop(at(interpreter_frame_oop_temp_offset));
|
||||||
assert(obj == NULL || Universe::heap()->is_in(obj), "sanity check");
|
assert(obj == NULL || Universe::heap()->is_in(obj), "sanity check");
|
||||||
*oop_result = obj;
|
*oop_result = obj;
|
||||||
#endif // CC_INTERP
|
#endif // CC_INTERP
|
||||||
|
@ -788,7 +788,7 @@ BasicType frame::interpreter_frame_result(oop* oop_result, jvalue* value_result)
|
||||||
switch(type) {
|
switch(type) {
|
||||||
case T_OBJECT:
|
case T_OBJECT:
|
||||||
case T_ARRAY: {
|
case T_ARRAY: {
|
||||||
oop obj = (oop)*tos_addr;
|
oop obj = cast_to_oop(*tos_addr);
|
||||||
assert(obj == NULL || Universe::heap()->is_in(obj), "sanity check");
|
assert(obj == NULL || Universe::heap()->is_in(obj), "sanity check");
|
||||||
*oop_result = obj;
|
*oop_result = obj;
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -3911,7 +3911,7 @@ void MacroAssembler::load_klass(Register src_oop, Register klass) {
|
||||||
// The number of bytes in this code is used by
|
// The number of bytes in this code is used by
|
||||||
// MachCallDynamicJavaNode::ret_addr_offset()
|
// MachCallDynamicJavaNode::ret_addr_offset()
|
||||||
// if this changes, change that.
|
// if this changes, change that.
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
lduw(src_oop, oopDesc::klass_offset_in_bytes(), klass);
|
lduw(src_oop, oopDesc::klass_offset_in_bytes(), klass);
|
||||||
decode_klass_not_null(klass);
|
decode_klass_not_null(klass);
|
||||||
} else {
|
} else {
|
||||||
|
@ -3920,7 +3920,7 @@ void MacroAssembler::load_klass(Register src_oop, Register klass) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void MacroAssembler::store_klass(Register klass, Register dst_oop) {
|
void MacroAssembler::store_klass(Register klass, Register dst_oop) {
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
assert(dst_oop != klass, "not enough registers");
|
assert(dst_oop != klass, "not enough registers");
|
||||||
encode_klass_not_null(klass);
|
encode_klass_not_null(klass);
|
||||||
st(klass, dst_oop, oopDesc::klass_offset_in_bytes());
|
st(klass, dst_oop, oopDesc::klass_offset_in_bytes());
|
||||||
|
@ -3930,7 +3930,7 @@ void MacroAssembler::store_klass(Register klass, Register dst_oop) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void MacroAssembler::store_klass_gap(Register s, Register d) {
|
void MacroAssembler::store_klass_gap(Register s, Register d) {
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
assert(s != d, "not enough registers");
|
assert(s != d, "not enough registers");
|
||||||
st(s, d, oopDesc::klass_gap_offset_in_bytes());
|
st(s, d, oopDesc::klass_gap_offset_in_bytes());
|
||||||
}
|
}
|
||||||
|
@ -4089,7 +4089,7 @@ void MacroAssembler::decode_heap_oop_not_null(Register src, Register dst) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void MacroAssembler::encode_klass_not_null(Register r) {
|
void MacroAssembler::encode_klass_not_null(Register r) {
|
||||||
assert (UseCompressedKlassPointers, "must be compressed");
|
assert (UseCompressedClassPointers, "must be compressed");
|
||||||
assert(Universe::narrow_klass_base() != NULL, "narrow_klass_base should be initialized");
|
assert(Universe::narrow_klass_base() != NULL, "narrow_klass_base should be initialized");
|
||||||
assert(r != G6_heapbase, "bad register choice");
|
assert(r != G6_heapbase, "bad register choice");
|
||||||
set((intptr_t)Universe::narrow_klass_base(), G6_heapbase);
|
set((intptr_t)Universe::narrow_klass_base(), G6_heapbase);
|
||||||
|
@ -4105,7 +4105,7 @@ void MacroAssembler::encode_klass_not_null(Register src, Register dst) {
|
||||||
if (src == dst) {
|
if (src == dst) {
|
||||||
encode_klass_not_null(src);
|
encode_klass_not_null(src);
|
||||||
} else {
|
} else {
|
||||||
assert (UseCompressedKlassPointers, "must be compressed");
|
assert (UseCompressedClassPointers, "must be compressed");
|
||||||
assert(Universe::narrow_klass_base() != NULL, "narrow_klass_base should be initialized");
|
assert(Universe::narrow_klass_base() != NULL, "narrow_klass_base should be initialized");
|
||||||
set((intptr_t)Universe::narrow_klass_base(), dst);
|
set((intptr_t)Universe::narrow_klass_base(), dst);
|
||||||
sub(src, dst, dst);
|
sub(src, dst, dst);
|
||||||
|
@ -4119,7 +4119,7 @@ void MacroAssembler::encode_klass_not_null(Register src, Register dst) {
|
||||||
// generated by decode_klass_not_null() and reinit_heapbase(). Hence, if
|
// generated by decode_klass_not_null() and reinit_heapbase(). Hence, if
|
||||||
// the instructions they generate change, then this method needs to be updated.
|
// the instructions they generate change, then this method needs to be updated.
|
||||||
int MacroAssembler::instr_size_for_decode_klass_not_null() {
|
int MacroAssembler::instr_size_for_decode_klass_not_null() {
|
||||||
assert (UseCompressedKlassPointers, "only for compressed klass ptrs");
|
assert (UseCompressedClassPointers, "only for compressed klass ptrs");
|
||||||
// set + add + set
|
// set + add + set
|
||||||
int num_instrs = insts_for_internal_set((intptr_t)Universe::narrow_klass_base()) + 1 +
|
int num_instrs = insts_for_internal_set((intptr_t)Universe::narrow_klass_base()) + 1 +
|
||||||
insts_for_internal_set((intptr_t)Universe::narrow_ptrs_base());
|
insts_for_internal_set((intptr_t)Universe::narrow_ptrs_base());
|
||||||
|
@ -4135,7 +4135,7 @@ int MacroAssembler::instr_size_for_decode_klass_not_null() {
|
||||||
void MacroAssembler::decode_klass_not_null(Register r) {
|
void MacroAssembler::decode_klass_not_null(Register r) {
|
||||||
// Do not add assert code to this unless you change vtableStubs_sparc.cpp
|
// Do not add assert code to this unless you change vtableStubs_sparc.cpp
|
||||||
// pd_code_size_limit.
|
// pd_code_size_limit.
|
||||||
assert (UseCompressedKlassPointers, "must be compressed");
|
assert (UseCompressedClassPointers, "must be compressed");
|
||||||
assert(Universe::narrow_klass_base() != NULL, "narrow_klass_base should be initialized");
|
assert(Universe::narrow_klass_base() != NULL, "narrow_klass_base should be initialized");
|
||||||
assert(r != G6_heapbase, "bad register choice");
|
assert(r != G6_heapbase, "bad register choice");
|
||||||
set((intptr_t)Universe::narrow_klass_base(), G6_heapbase);
|
set((intptr_t)Universe::narrow_klass_base(), G6_heapbase);
|
||||||
|
@ -4151,7 +4151,7 @@ void MacroAssembler::decode_klass_not_null(Register src, Register dst) {
|
||||||
} else {
|
} else {
|
||||||
// Do not add assert code to this unless you change vtableStubs_sparc.cpp
|
// Do not add assert code to this unless you change vtableStubs_sparc.cpp
|
||||||
// pd_code_size_limit.
|
// pd_code_size_limit.
|
||||||
assert (UseCompressedKlassPointers, "must be compressed");
|
assert (UseCompressedClassPointers, "must be compressed");
|
||||||
assert(Universe::narrow_klass_base() != NULL, "narrow_klass_base should be initialized");
|
assert(Universe::narrow_klass_base() != NULL, "narrow_klass_base should be initialized");
|
||||||
if (Universe::narrow_klass_shift() != 0) {
|
if (Universe::narrow_klass_shift() != 0) {
|
||||||
assert((src != G6_heapbase) && (dst != G6_heapbase), "bad register choice");
|
assert((src != G6_heapbase) && (dst != G6_heapbase), "bad register choice");
|
||||||
|
@ -4167,7 +4167,7 @@ void MacroAssembler::decode_klass_not_null(Register src, Register dst) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void MacroAssembler::reinit_heapbase() {
|
void MacroAssembler::reinit_heapbase() {
|
||||||
if (UseCompressedOops || UseCompressedKlassPointers) {
|
if (UseCompressedOops || UseCompressedClassPointers) {
|
||||||
if (Universe::heap() != NULL) {
|
if (Universe::heap() != NULL) {
|
||||||
set((intptr_t)Universe::narrow_ptrs_base(), G6_heapbase);
|
set((intptr_t)Universe::narrow_ptrs_base(), G6_heapbase);
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 2008, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
|
@ -121,6 +121,7 @@ void MethodHandles::verify_ref_kind(MacroAssembler* _masm, int ref_kind, Registe
|
||||||
|
|
||||||
void MethodHandles::jump_from_method_handle(MacroAssembler* _masm, Register method, Register target, Register temp,
|
void MethodHandles::jump_from_method_handle(MacroAssembler* _masm, Register method, Register target, Register temp,
|
||||||
bool for_compiler_entry) {
|
bool for_compiler_entry) {
|
||||||
|
Label L_no_such_method;
|
||||||
assert(method == G5_method, "interpreter calling convention");
|
assert(method == G5_method, "interpreter calling convention");
|
||||||
assert_different_registers(method, target, temp);
|
assert_different_registers(method, target, temp);
|
||||||
|
|
||||||
|
@ -133,6 +134,9 @@ void MethodHandles::jump_from_method_handle(MacroAssembler* _masm, Register meth
|
||||||
const Address interp_only(G2_thread, JavaThread::interp_only_mode_offset());
|
const Address interp_only(G2_thread, JavaThread::interp_only_mode_offset());
|
||||||
__ ld(interp_only, temp);
|
__ ld(interp_only, temp);
|
||||||
__ cmp_and_br_short(temp, 0, Assembler::zero, Assembler::pt, run_compiled_code);
|
__ cmp_and_br_short(temp, 0, Assembler::zero, Assembler::pt, run_compiled_code);
|
||||||
|
// Null method test is replicated below in compiled case,
|
||||||
|
// it might be able to address across the verify_thread()
|
||||||
|
__ br_null_short(G5_method, Assembler::pn, L_no_such_method);
|
||||||
__ ld_ptr(G5_method, in_bytes(Method::interpreter_entry_offset()), target);
|
__ ld_ptr(G5_method, in_bytes(Method::interpreter_entry_offset()), target);
|
||||||
__ jmp(target, 0);
|
__ jmp(target, 0);
|
||||||
__ delayed()->nop();
|
__ delayed()->nop();
|
||||||
|
@ -141,11 +145,19 @@ void MethodHandles::jump_from_method_handle(MacroAssembler* _masm, Register meth
|
||||||
// it doesn't matter, since this is interpreter code.
|
// it doesn't matter, since this is interpreter code.
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Compiled case, either static or fall-through from runtime conditional
|
||||||
|
__ br_null_short(G5_method, Assembler::pn, L_no_such_method);
|
||||||
|
|
||||||
const ByteSize entry_offset = for_compiler_entry ? Method::from_compiled_offset() :
|
const ByteSize entry_offset = for_compiler_entry ? Method::from_compiled_offset() :
|
||||||
Method::from_interpreted_offset();
|
Method::from_interpreted_offset();
|
||||||
__ ld_ptr(G5_method, in_bytes(entry_offset), target);
|
__ ld_ptr(G5_method, in_bytes(entry_offset), target);
|
||||||
__ jmp(target, 0);
|
__ jmp(target, 0);
|
||||||
__ delayed()->nop();
|
__ delayed()->nop();
|
||||||
|
|
||||||
|
__ bind(L_no_such_method);
|
||||||
|
AddressLiteral ame(StubRoutines::throw_AbstractMethodError_entry());
|
||||||
|
__ jump_to(ame, temp);
|
||||||
|
__ delayed()->nop();
|
||||||
}
|
}
|
||||||
|
|
||||||
void MethodHandles::jump_to_lambda_form(MacroAssembler* _masm,
|
void MethodHandles::jump_to_lambda_form(MacroAssembler* _masm,
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
|
@ -358,7 +358,7 @@ void NativeMovConstReg::set_data(intptr_t x) {
|
||||||
oop_Relocation *r = iter.oop_reloc();
|
oop_Relocation *r = iter.oop_reloc();
|
||||||
if (oop_addr == NULL) {
|
if (oop_addr == NULL) {
|
||||||
oop_addr = r->oop_addr();
|
oop_addr = r->oop_addr();
|
||||||
*oop_addr = (oop)x;
|
*oop_addr = cast_to_oop(x);
|
||||||
} else {
|
} else {
|
||||||
assert(oop_addr == r->oop_addr(), "must be only one set-oop here");
|
assert(oop_addr == r->oop_addr(), "must be only one set-oop here");
|
||||||
}
|
}
|
||||||
|
@ -478,7 +478,7 @@ void NativeMovConstRegPatching::set_data(int x) {
|
||||||
oop_Relocation *r = iter.oop_reloc();
|
oop_Relocation *r = iter.oop_reloc();
|
||||||
if (oop_addr == NULL) {
|
if (oop_addr == NULL) {
|
||||||
oop_addr = r->oop_addr();
|
oop_addr = r->oop_addr();
|
||||||
*oop_addr = (oop)x;
|
*oop_addr = cast_to_oop(x);
|
||||||
} else {
|
} else {
|
||||||
assert(oop_addr == r->oop_addr(), "must be only one set-oop here");
|
assert(oop_addr == r->oop_addr(), "must be only one set-oop here");
|
||||||
}
|
}
|
||||||
|
|
|
@ -557,7 +557,7 @@ int MachCallDynamicJavaNode::ret_addr_offset() {
|
||||||
int entry_offset = InstanceKlass::vtable_start_offset() + vtable_index*vtableEntry::size();
|
int entry_offset = InstanceKlass::vtable_start_offset() + vtable_index*vtableEntry::size();
|
||||||
int v_off = entry_offset*wordSize + vtableEntry::method_offset_in_bytes();
|
int v_off = entry_offset*wordSize + vtableEntry::method_offset_in_bytes();
|
||||||
int klass_load_size;
|
int klass_load_size;
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
assert(Universe::heap() != NULL, "java heap should be initialized");
|
assert(Universe::heap() != NULL, "java heap should be initialized");
|
||||||
klass_load_size = MacroAssembler::instr_size_for_decode_klass_not_null() + 1*BytesPerInstWord;
|
klass_load_size = MacroAssembler::instr_size_for_decode_klass_not_null() + 1*BytesPerInstWord;
|
||||||
} else {
|
} else {
|
||||||
|
@ -1657,7 +1657,7 @@ uint BoxLockNode::size(PhaseRegAlloc *ra_) const {
|
||||||
void MachUEPNode::format( PhaseRegAlloc *ra_, outputStream *st ) const {
|
void MachUEPNode::format( PhaseRegAlloc *ra_, outputStream *st ) const {
|
||||||
st->print_cr("\nUEP:");
|
st->print_cr("\nUEP:");
|
||||||
#ifdef _LP64
|
#ifdef _LP64
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
assert(Universe::heap() != NULL, "java heap should be initialized");
|
assert(Universe::heap() != NULL, "java heap should be initialized");
|
||||||
st->print_cr("\tLDUW [R_O0 + oopDesc::klass_offset_in_bytes],R_G5\t! Inline cache check - compressed klass");
|
st->print_cr("\tLDUW [R_O0 + oopDesc::klass_offset_in_bytes],R_G5\t! Inline cache check - compressed klass");
|
||||||
st->print_cr("\tSET Universe::narrow_klass_base,R_G6_heap_base");
|
st->print_cr("\tSET Universe::narrow_klass_base,R_G6_heap_base");
|
||||||
|
@ -1897,7 +1897,7 @@ bool Matcher::narrow_oop_use_complex_address() {
|
||||||
|
|
||||||
bool Matcher::narrow_klass_use_complex_address() {
|
bool Matcher::narrow_klass_use_complex_address() {
|
||||||
NOT_LP64(ShouldNotCallThis());
|
NOT_LP64(ShouldNotCallThis());
|
||||||
assert(UseCompressedKlassPointers, "only for compressed klass code");
|
assert(UseCompressedClassPointers, "only for compressed klass code");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2018,6 +2018,15 @@ const RegMask Matcher::method_handle_invoke_SP_save_mask() {
|
||||||
return L7_REGP_mask();
|
return L7_REGP_mask();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const RegMask Matcher::mathExactI_result_proj_mask() {
|
||||||
|
return G1_REGI_mask();
|
||||||
|
}
|
||||||
|
|
||||||
|
const RegMask Matcher::mathExactI_flags_proj_mask() {
|
||||||
|
return INT_FLAGS_mask();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
%}
|
%}
|
||||||
|
|
||||||
|
|
||||||
|
@ -2561,7 +2570,7 @@ encode %{
|
||||||
int off = __ offset();
|
int off = __ offset();
|
||||||
__ load_klass(O0, G3_scratch);
|
__ load_klass(O0, G3_scratch);
|
||||||
int klass_load_size;
|
int klass_load_size;
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
assert(Universe::heap() != NULL, "java heap should be initialized");
|
assert(Universe::heap() != NULL, "java heap should be initialized");
|
||||||
klass_load_size = MacroAssembler::instr_size_for_decode_klass_not_null() + 1*BytesPerInstWord;
|
klass_load_size = MacroAssembler::instr_size_for_decode_klass_not_null() + 1*BytesPerInstWord;
|
||||||
} else {
|
} else {
|
||||||
|
@ -4245,12 +4254,16 @@ operand cmpOp() %{
|
||||||
greater_equal(0xB);
|
greater_equal(0xB);
|
||||||
less_equal(0x2);
|
less_equal(0x2);
|
||||||
greater(0xA);
|
greater(0xA);
|
||||||
|
overflow(0x7);
|
||||||
|
no_overflow(0xF);
|
||||||
%}
|
%}
|
||||||
%}
|
%}
|
||||||
|
|
||||||
// Comparison Op, unsigned
|
// Comparison Op, unsigned
|
||||||
operand cmpOpU() %{
|
operand cmpOpU() %{
|
||||||
match(Bool);
|
match(Bool);
|
||||||
|
predicate(n->as_Bool()->_test._test != BoolTest::overflow &&
|
||||||
|
n->as_Bool()->_test._test != BoolTest::no_overflow);
|
||||||
|
|
||||||
format %{ "u" %}
|
format %{ "u" %}
|
||||||
interface(COND_INTER) %{
|
interface(COND_INTER) %{
|
||||||
|
@ -4260,12 +4273,16 @@ operand cmpOpU() %{
|
||||||
greater_equal(0xD);
|
greater_equal(0xD);
|
||||||
less_equal(0x4);
|
less_equal(0x4);
|
||||||
greater(0xC);
|
greater(0xC);
|
||||||
|
overflow(0x7);
|
||||||
|
no_overflow(0xF);
|
||||||
%}
|
%}
|
||||||
%}
|
%}
|
||||||
|
|
||||||
// Comparison Op, pointer (same as unsigned)
|
// Comparison Op, pointer (same as unsigned)
|
||||||
operand cmpOpP() %{
|
operand cmpOpP() %{
|
||||||
match(Bool);
|
match(Bool);
|
||||||
|
predicate(n->as_Bool()->_test._test != BoolTest::overflow &&
|
||||||
|
n->as_Bool()->_test._test != BoolTest::no_overflow);
|
||||||
|
|
||||||
format %{ "p" %}
|
format %{ "p" %}
|
||||||
interface(COND_INTER) %{
|
interface(COND_INTER) %{
|
||||||
|
@ -4275,12 +4292,16 @@ operand cmpOpP() %{
|
||||||
greater_equal(0xD);
|
greater_equal(0xD);
|
||||||
less_equal(0x4);
|
less_equal(0x4);
|
||||||
greater(0xC);
|
greater(0xC);
|
||||||
|
overflow(0x7);
|
||||||
|
no_overflow(0xF);
|
||||||
%}
|
%}
|
||||||
%}
|
%}
|
||||||
|
|
||||||
// Comparison Op, branch-register encoding
|
// Comparison Op, branch-register encoding
|
||||||
operand cmpOp_reg() %{
|
operand cmpOp_reg() %{
|
||||||
match(Bool);
|
match(Bool);
|
||||||
|
predicate(n->as_Bool()->_test._test != BoolTest::overflow &&
|
||||||
|
n->as_Bool()->_test._test != BoolTest::no_overflow);
|
||||||
|
|
||||||
format %{ "" %}
|
format %{ "" %}
|
||||||
interface(COND_INTER) %{
|
interface(COND_INTER) %{
|
||||||
|
@ -4290,12 +4311,16 @@ operand cmpOp_reg() %{
|
||||||
greater_equal(0x7);
|
greater_equal(0x7);
|
||||||
less_equal (0x2);
|
less_equal (0x2);
|
||||||
greater (0x6);
|
greater (0x6);
|
||||||
|
overflow(0x7); // not supported
|
||||||
|
no_overflow(0xF); // not supported
|
||||||
%}
|
%}
|
||||||
%}
|
%}
|
||||||
|
|
||||||
// Comparison Code, floating, unordered same as less
|
// Comparison Code, floating, unordered same as less
|
||||||
operand cmpOpF() %{
|
operand cmpOpF() %{
|
||||||
match(Bool);
|
match(Bool);
|
||||||
|
predicate(n->as_Bool()->_test._test != BoolTest::overflow &&
|
||||||
|
n->as_Bool()->_test._test != BoolTest::no_overflow);
|
||||||
|
|
||||||
format %{ "fl" %}
|
format %{ "fl" %}
|
||||||
interface(COND_INTER) %{
|
interface(COND_INTER) %{
|
||||||
|
@ -4305,12 +4330,17 @@ operand cmpOpF() %{
|
||||||
greater_equal(0xB);
|
greater_equal(0xB);
|
||||||
less_equal(0xE);
|
less_equal(0xE);
|
||||||
greater(0x6);
|
greater(0x6);
|
||||||
|
|
||||||
|
overflow(0x7); // not supported
|
||||||
|
no_overflow(0xF); // not supported
|
||||||
%}
|
%}
|
||||||
%}
|
%}
|
||||||
|
|
||||||
// Used by long compare
|
// Used by long compare
|
||||||
operand cmpOp_commute() %{
|
operand cmpOp_commute() %{
|
||||||
match(Bool);
|
match(Bool);
|
||||||
|
predicate(n->as_Bool()->_test._test != BoolTest::overflow &&
|
||||||
|
n->as_Bool()->_test._test != BoolTest::no_overflow);
|
||||||
|
|
||||||
format %{ "" %}
|
format %{ "" %}
|
||||||
interface(COND_INTER) %{
|
interface(COND_INTER) %{
|
||||||
|
@ -4320,6 +4350,8 @@ operand cmpOp_commute() %{
|
||||||
greater_equal(0x2);
|
greater_equal(0x2);
|
||||||
less_equal(0xB);
|
less_equal(0xB);
|
||||||
greater(0x3);
|
greater(0x3);
|
||||||
|
overflow(0x7);
|
||||||
|
no_overflow(0xF);
|
||||||
%}
|
%}
|
||||||
%}
|
%}
|
||||||
|
|
||||||
|
|
|
@ -2945,7 +2945,7 @@ class StubGenerator: public StubCodeGenerator {
|
||||||
|
|
||||||
BLOCK_COMMENT("arraycopy argument klass checks");
|
BLOCK_COMMENT("arraycopy argument klass checks");
|
||||||
// get src->klass()
|
// get src->klass()
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
__ delayed()->nop(); // ??? not good
|
__ delayed()->nop(); // ??? not good
|
||||||
__ load_klass(src, G3_src_klass);
|
__ load_klass(src, G3_src_klass);
|
||||||
} else {
|
} else {
|
||||||
|
@ -2980,7 +2980,7 @@ class StubGenerator: public StubCodeGenerator {
|
||||||
// Load 32-bits signed value. Use br() instruction with it to check icc.
|
// Load 32-bits signed value. Use br() instruction with it to check icc.
|
||||||
__ lduw(G3_src_klass, lh_offset, G5_lh);
|
__ lduw(G3_src_klass, lh_offset, G5_lh);
|
||||||
|
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
__ load_klass(dst, G4_dst_klass);
|
__ load_klass(dst, G4_dst_klass);
|
||||||
}
|
}
|
||||||
// Handle objArrays completely differently...
|
// Handle objArrays completely differently...
|
||||||
|
@ -2988,7 +2988,7 @@ class StubGenerator: public StubCodeGenerator {
|
||||||
__ set(objArray_lh, O5_temp);
|
__ set(objArray_lh, O5_temp);
|
||||||
__ cmp(G5_lh, O5_temp);
|
__ cmp(G5_lh, O5_temp);
|
||||||
__ br(Assembler::equal, false, Assembler::pt, L_objArray);
|
__ br(Assembler::equal, false, Assembler::pt, L_objArray);
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
__ delayed()->nop();
|
__ delayed()->nop();
|
||||||
} else {
|
} else {
|
||||||
__ delayed()->ld_ptr(dst, oopDesc::klass_offset_in_bytes(), G4_dst_klass);
|
__ delayed()->ld_ptr(dst, oopDesc::klass_offset_in_bytes(), G4_dst_klass);
|
||||||
|
|
|
@ -52,6 +52,11 @@ extern "C" void bad_compiled_vtable_index(JavaThread* thread, oopDesc* receiver,
|
||||||
VtableStub* VtableStubs::create_vtable_stub(int vtable_index) {
|
VtableStub* VtableStubs::create_vtable_stub(int vtable_index) {
|
||||||
const int sparc_code_length = VtableStub::pd_code_size_limit(true);
|
const int sparc_code_length = VtableStub::pd_code_size_limit(true);
|
||||||
VtableStub* s = new(sparc_code_length) VtableStub(true, vtable_index);
|
VtableStub* s = new(sparc_code_length) VtableStub(true, vtable_index);
|
||||||
|
// Can be NULL if there is no free space in the code cache.
|
||||||
|
if (s == NULL) {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
ResourceMark rm;
|
ResourceMark rm;
|
||||||
CodeBuffer cb(s->entry_point(), sparc_code_length);
|
CodeBuffer cb(s->entry_point(), sparc_code_length);
|
||||||
MacroAssembler* masm = new MacroAssembler(&cb);
|
MacroAssembler* masm = new MacroAssembler(&cb);
|
||||||
|
@ -125,6 +130,11 @@ VtableStub* VtableStubs::create_vtable_stub(int vtable_index) {
|
||||||
VtableStub* VtableStubs::create_itable_stub(int itable_index) {
|
VtableStub* VtableStubs::create_itable_stub(int itable_index) {
|
||||||
const int sparc_code_length = VtableStub::pd_code_size_limit(false);
|
const int sparc_code_length = VtableStub::pd_code_size_limit(false);
|
||||||
VtableStub* s = new(sparc_code_length) VtableStub(false, itable_index);
|
VtableStub* s = new(sparc_code_length) VtableStub(false, itable_index);
|
||||||
|
// Can be NULL if there is no free space in the code cache.
|
||||||
|
if (s == NULL) {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
ResourceMark rm;
|
ResourceMark rm;
|
||||||
CodeBuffer cb(s->entry_point(), sparc_code_length);
|
CodeBuffer cb(s->entry_point(), sparc_code_length);
|
||||||
MacroAssembler* masm = new MacroAssembler(&cb);
|
MacroAssembler* masm = new MacroAssembler(&cb);
|
||||||
|
@ -218,13 +228,13 @@ int VtableStub::pd_code_size_limit(bool is_vtable_stub) {
|
||||||
// ld;ld;ld,jmp,nop
|
// ld;ld;ld,jmp,nop
|
||||||
const int basic = 5*BytesPerInstWord +
|
const int basic = 5*BytesPerInstWord +
|
||||||
// shift;add for load_klass (only shift with zero heap based)
|
// shift;add for load_klass (only shift with zero heap based)
|
||||||
(UseCompressedKlassPointers ?
|
(UseCompressedClassPointers ?
|
||||||
MacroAssembler::instr_size_for_decode_klass_not_null() : 0);
|
MacroAssembler::instr_size_for_decode_klass_not_null() : 0);
|
||||||
return basic + slop;
|
return basic + slop;
|
||||||
} else {
|
} else {
|
||||||
const int basic = (28 LP64_ONLY(+ 6)) * BytesPerInstWord +
|
const int basic = (28 LP64_ONLY(+ 6)) * BytesPerInstWord +
|
||||||
// shift;add for load_klass (only shift with zero heap based)
|
// shift;add for load_klass (only shift with zero heap based)
|
||||||
(UseCompressedKlassPointers ?
|
(UseCompressedClassPointers ?
|
||||||
MacroAssembler::instr_size_for_decode_klass_not_null() : 0);
|
MacroAssembler::instr_size_for_decode_klass_not_null() : 0);
|
||||||
return (basic + slop);
|
return (basic + slop);
|
||||||
}
|
}
|
||||||
|
|
|
@ -4769,7 +4769,7 @@ void Assembler::adcq(Register dst, Address src) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void Assembler::adcq(Register dst, Register src) {
|
void Assembler::adcq(Register dst, Register src) {
|
||||||
(int) prefixq_and_encode(dst->encoding(), src->encoding());
|
(void) prefixq_and_encode(dst->encoding(), src->encoding());
|
||||||
emit_arith(0x13, 0xC0, dst, src);
|
emit_arith(0x13, 0xC0, dst, src);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -4824,7 +4824,7 @@ void Assembler::andq(Register dst, Address src) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void Assembler::andq(Register dst, Register src) {
|
void Assembler::andq(Register dst, Register src) {
|
||||||
(int) prefixq_and_encode(dst->encoding(), src->encoding());
|
(void) prefixq_and_encode(dst->encoding(), src->encoding());
|
||||||
emit_arith(0x23, 0xC0, dst, src);
|
emit_arith(0x23, 0xC0, dst, src);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -148,7 +148,7 @@
|
||||||
|
|
||||||
static int adjust_reg_range(int range) {
|
static int adjust_reg_range(int range) {
|
||||||
// Reduce the number of available regs (to free r12) in case of compressed oops
|
// Reduce the number of available regs (to free r12) in case of compressed oops
|
||||||
if (UseCompressedOops || UseCompressedKlassPointers) return range - 1;
|
if (UseCompressedOops || UseCompressedClassPointers) return range - 1;
|
||||||
return range;
|
return range;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -341,7 +341,7 @@ int LIR_Assembler::check_icache() {
|
||||||
Register receiver = FrameMap::receiver_opr->as_register();
|
Register receiver = FrameMap::receiver_opr->as_register();
|
||||||
Register ic_klass = IC_Klass;
|
Register ic_klass = IC_Klass;
|
||||||
const int ic_cmp_size = LP64_ONLY(10) NOT_LP64(9);
|
const int ic_cmp_size = LP64_ONLY(10) NOT_LP64(9);
|
||||||
const bool do_post_padding = VerifyOops || UseCompressedKlassPointers;
|
const bool do_post_padding = VerifyOops || UseCompressedClassPointers;
|
||||||
if (!do_post_padding) {
|
if (!do_post_padding) {
|
||||||
// insert some nops so that the verified entry point is aligned on CodeEntryAlignment
|
// insert some nops so that the verified entry point is aligned on CodeEntryAlignment
|
||||||
while ((__ offset() + ic_cmp_size) % CodeEntryAlignment != 0) {
|
while ((__ offset() + ic_cmp_size) % CodeEntryAlignment != 0) {
|
||||||
|
@ -1263,7 +1263,7 @@ void LIR_Assembler::mem2reg(LIR_Opr src, LIR_Opr dest, BasicType type, LIR_Patch
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case T_ADDRESS:
|
case T_ADDRESS:
|
||||||
if (UseCompressedKlassPointers && addr->disp() == oopDesc::klass_offset_in_bytes()) {
|
if (UseCompressedClassPointers && addr->disp() == oopDesc::klass_offset_in_bytes()) {
|
||||||
__ movl(dest->as_register(), from_addr);
|
__ movl(dest->as_register(), from_addr);
|
||||||
} else {
|
} else {
|
||||||
__ movptr(dest->as_register(), from_addr);
|
__ movptr(dest->as_register(), from_addr);
|
||||||
|
@ -1371,7 +1371,7 @@ void LIR_Assembler::mem2reg(LIR_Opr src, LIR_Opr dest, BasicType type, LIR_Patch
|
||||||
__ verify_oop(dest->as_register());
|
__ verify_oop(dest->as_register());
|
||||||
} else if (type == T_ADDRESS && addr->disp() == oopDesc::klass_offset_in_bytes()) {
|
} else if (type == T_ADDRESS && addr->disp() == oopDesc::klass_offset_in_bytes()) {
|
||||||
#ifdef _LP64
|
#ifdef _LP64
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
__ decode_klass_not_null(dest->as_register());
|
__ decode_klass_not_null(dest->as_register());
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@ -1716,7 +1716,7 @@ void LIR_Assembler::emit_typecheck_helper(LIR_OpTypeCheck *op, Label* success, L
|
||||||
} else if (obj == klass_RInfo) {
|
} else if (obj == klass_RInfo) {
|
||||||
klass_RInfo = dst;
|
klass_RInfo = dst;
|
||||||
}
|
}
|
||||||
if (k->is_loaded() && !UseCompressedKlassPointers) {
|
if (k->is_loaded() && !UseCompressedClassPointers) {
|
||||||
select_different_registers(obj, dst, k_RInfo, klass_RInfo);
|
select_different_registers(obj, dst, k_RInfo, klass_RInfo);
|
||||||
} else {
|
} else {
|
||||||
Rtmp1 = op->tmp3()->as_register();
|
Rtmp1 = op->tmp3()->as_register();
|
||||||
|
@ -1724,14 +1724,6 @@ void LIR_Assembler::emit_typecheck_helper(LIR_OpTypeCheck *op, Label* success, L
|
||||||
}
|
}
|
||||||
|
|
||||||
assert_different_registers(obj, k_RInfo, klass_RInfo);
|
assert_different_registers(obj, k_RInfo, klass_RInfo);
|
||||||
if (!k->is_loaded()) {
|
|
||||||
klass2reg_with_patching(k_RInfo, op->info_for_patch());
|
|
||||||
} else {
|
|
||||||
#ifdef _LP64
|
|
||||||
__ mov_metadata(k_RInfo, k->constant_encoding());
|
|
||||||
#endif // _LP64
|
|
||||||
}
|
|
||||||
assert(obj != k_RInfo, "must be different");
|
|
||||||
|
|
||||||
__ cmpptr(obj, (int32_t)NULL_WORD);
|
__ cmpptr(obj, (int32_t)NULL_WORD);
|
||||||
if (op->should_profile()) {
|
if (op->should_profile()) {
|
||||||
|
@ -1748,13 +1740,21 @@ void LIR_Assembler::emit_typecheck_helper(LIR_OpTypeCheck *op, Label* success, L
|
||||||
} else {
|
} else {
|
||||||
__ jcc(Assembler::equal, *obj_is_null);
|
__ jcc(Assembler::equal, *obj_is_null);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!k->is_loaded()) {
|
||||||
|
klass2reg_with_patching(k_RInfo, op->info_for_patch());
|
||||||
|
} else {
|
||||||
|
#ifdef _LP64
|
||||||
|
__ mov_metadata(k_RInfo, k->constant_encoding());
|
||||||
|
#endif // _LP64
|
||||||
|
}
|
||||||
__ verify_oop(obj);
|
__ verify_oop(obj);
|
||||||
|
|
||||||
if (op->fast_check()) {
|
if (op->fast_check()) {
|
||||||
// get object class
|
// get object class
|
||||||
// not a safepoint as obj null check happens earlier
|
// not a safepoint as obj null check happens earlier
|
||||||
#ifdef _LP64
|
#ifdef _LP64
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
__ load_klass(Rtmp1, obj);
|
__ load_klass(Rtmp1, obj);
|
||||||
__ cmpptr(k_RInfo, Rtmp1);
|
__ cmpptr(k_RInfo, Rtmp1);
|
||||||
} else {
|
} else {
|
||||||
|
@ -3294,7 +3294,7 @@ void LIR_Assembler::emit_arraycopy(LIR_OpArrayCopy* op) {
|
||||||
// We don't know the array types are compatible
|
// We don't know the array types are compatible
|
||||||
if (basic_type != T_OBJECT) {
|
if (basic_type != T_OBJECT) {
|
||||||
// Simple test for basic type arrays
|
// Simple test for basic type arrays
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
__ movl(tmp, src_klass_addr);
|
__ movl(tmp, src_klass_addr);
|
||||||
__ cmpl(tmp, dst_klass_addr);
|
__ cmpl(tmp, dst_klass_addr);
|
||||||
} else {
|
} else {
|
||||||
|
@ -3456,21 +3456,21 @@ void LIR_Assembler::emit_arraycopy(LIR_OpArrayCopy* op) {
|
||||||
Label known_ok, halt;
|
Label known_ok, halt;
|
||||||
__ mov_metadata(tmp, default_type->constant_encoding());
|
__ mov_metadata(tmp, default_type->constant_encoding());
|
||||||
#ifdef _LP64
|
#ifdef _LP64
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
__ encode_klass_not_null(tmp);
|
__ encode_klass_not_null(tmp);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (basic_type != T_OBJECT) {
|
if (basic_type != T_OBJECT) {
|
||||||
|
|
||||||
if (UseCompressedKlassPointers) __ cmpl(tmp, dst_klass_addr);
|
if (UseCompressedClassPointers) __ cmpl(tmp, dst_klass_addr);
|
||||||
else __ cmpptr(tmp, dst_klass_addr);
|
else __ cmpptr(tmp, dst_klass_addr);
|
||||||
__ jcc(Assembler::notEqual, halt);
|
__ jcc(Assembler::notEqual, halt);
|
||||||
if (UseCompressedKlassPointers) __ cmpl(tmp, src_klass_addr);
|
if (UseCompressedClassPointers) __ cmpl(tmp, src_klass_addr);
|
||||||
else __ cmpptr(tmp, src_klass_addr);
|
else __ cmpptr(tmp, src_klass_addr);
|
||||||
__ jcc(Assembler::equal, known_ok);
|
__ jcc(Assembler::equal, known_ok);
|
||||||
} else {
|
} else {
|
||||||
if (UseCompressedKlassPointers) __ cmpl(tmp, dst_klass_addr);
|
if (UseCompressedClassPointers) __ cmpl(tmp, dst_klass_addr);
|
||||||
else __ cmpptr(tmp, dst_klass_addr);
|
else __ cmpptr(tmp, dst_klass_addr);
|
||||||
__ jcc(Assembler::equal, known_ok);
|
__ jcc(Assembler::equal, known_ok);
|
||||||
__ cmpptr(src, dst);
|
__ cmpptr(src, dst);
|
||||||
|
|
|
@ -1239,7 +1239,7 @@ void LIRGenerator::do_CheckCast(CheckCast* x) {
|
||||||
}
|
}
|
||||||
LIR_Opr reg = rlock_result(x);
|
LIR_Opr reg = rlock_result(x);
|
||||||
LIR_Opr tmp3 = LIR_OprFact::illegalOpr;
|
LIR_Opr tmp3 = LIR_OprFact::illegalOpr;
|
||||||
if (!x->klass()->is_loaded() || UseCompressedKlassPointers) {
|
if (!x->klass()->is_loaded() || UseCompressedClassPointers) {
|
||||||
tmp3 = new_register(objectType);
|
tmp3 = new_register(objectType);
|
||||||
}
|
}
|
||||||
__ checkcast(reg, obj.result(), x->klass(),
|
__ checkcast(reg, obj.result(), x->klass(),
|
||||||
|
@ -1261,7 +1261,7 @@ void LIRGenerator::do_InstanceOf(InstanceOf* x) {
|
||||||
}
|
}
|
||||||
obj.load_item();
|
obj.load_item();
|
||||||
LIR_Opr tmp3 = LIR_OprFact::illegalOpr;
|
LIR_Opr tmp3 = LIR_OprFact::illegalOpr;
|
||||||
if (!x->klass()->is_loaded() || UseCompressedKlassPointers) {
|
if (!x->klass()->is_loaded() || UseCompressedClassPointers) {
|
||||||
tmp3 = new_register(objectType);
|
tmp3 = new_register(objectType);
|
||||||
}
|
}
|
||||||
__ instanceof(reg, obj.result(), x->klass(),
|
__ instanceof(reg, obj.result(), x->klass(),
|
||||||
|
|
|
@ -157,7 +157,7 @@ void C1_MacroAssembler::initialize_header(Register obj, Register klass, Register
|
||||||
movptr(Address(obj, oopDesc::mark_offset_in_bytes ()), (int32_t)(intptr_t)markOopDesc::prototype());
|
movptr(Address(obj, oopDesc::mark_offset_in_bytes ()), (int32_t)(intptr_t)markOopDesc::prototype());
|
||||||
}
|
}
|
||||||
#ifdef _LP64
|
#ifdef _LP64
|
||||||
if (UseCompressedKlassPointers) { // Take care not to kill klass
|
if (UseCompressedClassPointers) { // Take care not to kill klass
|
||||||
movptr(t1, klass);
|
movptr(t1, klass);
|
||||||
encode_klass_not_null(t1);
|
encode_klass_not_null(t1);
|
||||||
movl(Address(obj, oopDesc::klass_offset_in_bytes()), t1);
|
movl(Address(obj, oopDesc::klass_offset_in_bytes()), t1);
|
||||||
|
@ -171,7 +171,7 @@ void C1_MacroAssembler::initialize_header(Register obj, Register klass, Register
|
||||||
movl(Address(obj, arrayOopDesc::length_offset_in_bytes()), len);
|
movl(Address(obj, arrayOopDesc::length_offset_in_bytes()), len);
|
||||||
}
|
}
|
||||||
#ifdef _LP64
|
#ifdef _LP64
|
||||||
else if (UseCompressedKlassPointers) {
|
else if (UseCompressedClassPointers) {
|
||||||
xorptr(t1, t1);
|
xorptr(t1, t1);
|
||||||
store_klass_gap(obj, t1);
|
store_klass_gap(obj, t1);
|
||||||
}
|
}
|
||||||
|
@ -334,7 +334,7 @@ void C1_MacroAssembler::inline_cache_check(Register receiver, Register iCache) {
|
||||||
assert(!MacroAssembler::needs_explicit_null_check(oopDesc::klass_offset_in_bytes()), "must add explicit null check");
|
assert(!MacroAssembler::needs_explicit_null_check(oopDesc::klass_offset_in_bytes()), "must add explicit null check");
|
||||||
int start_offset = offset();
|
int start_offset = offset();
|
||||||
|
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
load_klass(rscratch1, receiver);
|
load_klass(rscratch1, receiver);
|
||||||
cmpptr(rscratch1, iCache);
|
cmpptr(rscratch1, iCache);
|
||||||
} else {
|
} else {
|
||||||
|
@ -345,7 +345,7 @@ void C1_MacroAssembler::inline_cache_check(Register receiver, Register iCache) {
|
||||||
jump_cc(Assembler::notEqual,
|
jump_cc(Assembler::notEqual,
|
||||||
RuntimeAddress(SharedRuntime::get_ic_miss_stub()));
|
RuntimeAddress(SharedRuntime::get_ic_miss_stub()));
|
||||||
const int ic_cmp_size = LP64_ONLY(10) NOT_LP64(9);
|
const int ic_cmp_size = LP64_ONLY(10) NOT_LP64(9);
|
||||||
assert(UseCompressedKlassPointers || offset() - start_offset == ic_cmp_size, "check alignment in emit_method_entry");
|
assert(UseCompressedClassPointers || offset() - start_offset == ic_cmp_size, "check alignment in emit_method_entry");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -30,7 +30,6 @@
|
||||||
|
|
||||||
// Sets the default values for platform dependent flags used by the server compiler.
|
// Sets the default values for platform dependent flags used by the server compiler.
|
||||||
// (see c2_globals.hpp). Alpha-sorted.
|
// (see c2_globals.hpp). Alpha-sorted.
|
||||||
|
|
||||||
define_pd_global(bool, BackgroundCompilation, true);
|
define_pd_global(bool, BackgroundCompilation, true);
|
||||||
define_pd_global(bool, UseTLAB, true);
|
define_pd_global(bool, UseTLAB, true);
|
||||||
define_pd_global(bool, ResizeTLAB, true);
|
define_pd_global(bool, ResizeTLAB, true);
|
||||||
|
@ -52,6 +51,7 @@ define_pd_global(intx, OnStackReplacePercentage, 140);
|
||||||
define_pd_global(intx, ConditionalMoveLimit, 3);
|
define_pd_global(intx, ConditionalMoveLimit, 3);
|
||||||
define_pd_global(intx, FLOATPRESSURE, 6);
|
define_pd_global(intx, FLOATPRESSURE, 6);
|
||||||
define_pd_global(intx, FreqInlineSize, 325);
|
define_pd_global(intx, FreqInlineSize, 325);
|
||||||
|
define_pd_global(intx, MinJumpTableSize, 10);
|
||||||
#ifdef AMD64
|
#ifdef AMD64
|
||||||
define_pd_global(intx, INTPRESSURE, 13);
|
define_pd_global(intx, INTPRESSURE, 13);
|
||||||
define_pd_global(intx, InteriorEntryAlignment, 16);
|
define_pd_global(intx, InteriorEntryAlignment, 16);
|
||||||
|
|
|
@ -639,7 +639,7 @@ BasicType frame::interpreter_frame_result(oop* oop_result, jvalue* value_result)
|
||||||
#ifdef CC_INTERP
|
#ifdef CC_INTERP
|
||||||
obj = istate->_oop_temp;
|
obj = istate->_oop_temp;
|
||||||
#else
|
#else
|
||||||
obj = (oop) at(interpreter_frame_oop_temp_offset);
|
obj = cast_to_oop(at(interpreter_frame_oop_temp_offset));
|
||||||
#endif // CC_INTERP
|
#endif // CC_INTERP
|
||||||
} else {
|
} else {
|
||||||
oop* obj_p = (oop*)tos_addr;
|
oop* obj_p = (oop*)tos_addr;
|
||||||
|
|
|
@ -1635,7 +1635,7 @@ void MacroAssembler::call_VM_base(Register oop_result,
|
||||||
#ifdef ASSERT
|
#ifdef ASSERT
|
||||||
// TraceBytecodes does not use r12 but saves it over the call, so don't verify
|
// TraceBytecodes does not use r12 but saves it over the call, so don't verify
|
||||||
// r12 is the heapbase.
|
// r12 is the heapbase.
|
||||||
LP64_ONLY(if ((UseCompressedOops || UseCompressedKlassPointers) && !TraceBytecodes) verify_heapbase("call_VM_base: heap base corrupted?");)
|
LP64_ONLY(if ((UseCompressedOops || UseCompressedClassPointers) && !TraceBytecodes) verify_heapbase("call_VM_base: heap base corrupted?");)
|
||||||
#endif // ASSERT
|
#endif // ASSERT
|
||||||
|
|
||||||
assert(java_thread != oop_result , "cannot use the same register for java_thread & oop_result");
|
assert(java_thread != oop_result , "cannot use the same register for java_thread & oop_result");
|
||||||
|
@ -4802,7 +4802,7 @@ void MacroAssembler::restore_cpu_control_state_after_jni() {
|
||||||
|
|
||||||
void MacroAssembler::load_klass(Register dst, Register src) {
|
void MacroAssembler::load_klass(Register dst, Register src) {
|
||||||
#ifdef _LP64
|
#ifdef _LP64
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
movl(dst, Address(src, oopDesc::klass_offset_in_bytes()));
|
movl(dst, Address(src, oopDesc::klass_offset_in_bytes()));
|
||||||
decode_klass_not_null(dst);
|
decode_klass_not_null(dst);
|
||||||
} else
|
} else
|
||||||
|
@ -4817,7 +4817,7 @@ void MacroAssembler::load_prototype_header(Register dst, Register src) {
|
||||||
|
|
||||||
void MacroAssembler::store_klass(Register dst, Register src) {
|
void MacroAssembler::store_klass(Register dst, Register src) {
|
||||||
#ifdef _LP64
|
#ifdef _LP64
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
encode_klass_not_null(src);
|
encode_klass_not_null(src);
|
||||||
movl(Address(dst, oopDesc::klass_offset_in_bytes()), src);
|
movl(Address(dst, oopDesc::klass_offset_in_bytes()), src);
|
||||||
} else
|
} else
|
||||||
|
@ -4892,7 +4892,7 @@ void MacroAssembler::store_heap_oop_null(Address dst) {
|
||||||
|
|
||||||
#ifdef _LP64
|
#ifdef _LP64
|
||||||
void MacroAssembler::store_klass_gap(Register dst, Register src) {
|
void MacroAssembler::store_klass_gap(Register dst, Register src) {
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
// Store to klass gap in destination
|
// Store to klass gap in destination
|
||||||
movl(Address(dst, oopDesc::klass_gap_offset_in_bytes()), src);
|
movl(Address(dst, oopDesc::klass_gap_offset_in_bytes()), src);
|
||||||
}
|
}
|
||||||
|
@ -5075,7 +5075,7 @@ void MacroAssembler::encode_klass_not_null(Register dst, Register src) {
|
||||||
// when (Universe::heap() != NULL). Hence, if the instructions they
|
// when (Universe::heap() != NULL). Hence, if the instructions they
|
||||||
// generate change, then this method needs to be updated.
|
// generate change, then this method needs to be updated.
|
||||||
int MacroAssembler::instr_size_for_decode_klass_not_null() {
|
int MacroAssembler::instr_size_for_decode_klass_not_null() {
|
||||||
assert (UseCompressedKlassPointers, "only for compressed klass ptrs");
|
assert (UseCompressedClassPointers, "only for compressed klass ptrs");
|
||||||
// mov64 + addq + shlq? + mov64 (for reinit_heapbase()).
|
// mov64 + addq + shlq? + mov64 (for reinit_heapbase()).
|
||||||
return (Universe::narrow_klass_shift() == 0 ? 20 : 24);
|
return (Universe::narrow_klass_shift() == 0 ? 20 : 24);
|
||||||
}
|
}
|
||||||
|
@ -5085,7 +5085,7 @@ int MacroAssembler::instr_size_for_decode_klass_not_null() {
|
||||||
void MacroAssembler::decode_klass_not_null(Register r) {
|
void MacroAssembler::decode_klass_not_null(Register r) {
|
||||||
// Note: it will change flags
|
// Note: it will change flags
|
||||||
assert(Universe::narrow_klass_base() != NULL, "Base should be initialized");
|
assert(Universe::narrow_klass_base() != NULL, "Base should be initialized");
|
||||||
assert (UseCompressedKlassPointers, "should only be used for compressed headers");
|
assert (UseCompressedClassPointers, "should only be used for compressed headers");
|
||||||
assert(r != r12_heapbase, "Decoding a klass in r12");
|
assert(r != r12_heapbase, "Decoding a klass in r12");
|
||||||
// Cannot assert, unverified entry point counts instructions (see .ad file)
|
// Cannot assert, unverified entry point counts instructions (see .ad file)
|
||||||
// vtableStubs also counts instructions in pd_code_size_limit.
|
// vtableStubs also counts instructions in pd_code_size_limit.
|
||||||
|
@ -5103,7 +5103,7 @@ void MacroAssembler::decode_klass_not_null(Register r) {
|
||||||
void MacroAssembler::decode_klass_not_null(Register dst, Register src) {
|
void MacroAssembler::decode_klass_not_null(Register dst, Register src) {
|
||||||
// Note: it will change flags
|
// Note: it will change flags
|
||||||
assert(Universe::narrow_klass_base() != NULL, "Base should be initialized");
|
assert(Universe::narrow_klass_base() != NULL, "Base should be initialized");
|
||||||
assert (UseCompressedKlassPointers, "should only be used for compressed headers");
|
assert (UseCompressedClassPointers, "should only be used for compressed headers");
|
||||||
if (dst == src) {
|
if (dst == src) {
|
||||||
decode_klass_not_null(dst);
|
decode_klass_not_null(dst);
|
||||||
} else {
|
} else {
|
||||||
|
@ -5141,7 +5141,7 @@ void MacroAssembler::set_narrow_oop(Address dst, jobject obj) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void MacroAssembler::set_narrow_klass(Register dst, Klass* k) {
|
void MacroAssembler::set_narrow_klass(Register dst, Klass* k) {
|
||||||
assert (UseCompressedKlassPointers, "should only be used for compressed headers");
|
assert (UseCompressedClassPointers, "should only be used for compressed headers");
|
||||||
assert (oop_recorder() != NULL, "this assembler needs an OopRecorder");
|
assert (oop_recorder() != NULL, "this assembler needs an OopRecorder");
|
||||||
int klass_index = oop_recorder()->find_index(k);
|
int klass_index = oop_recorder()->find_index(k);
|
||||||
RelocationHolder rspec = metadata_Relocation::spec(klass_index);
|
RelocationHolder rspec = metadata_Relocation::spec(klass_index);
|
||||||
|
@ -5149,7 +5149,7 @@ void MacroAssembler::set_narrow_klass(Register dst, Klass* k) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void MacroAssembler::set_narrow_klass(Address dst, Klass* k) {
|
void MacroAssembler::set_narrow_klass(Address dst, Klass* k) {
|
||||||
assert (UseCompressedKlassPointers, "should only be used for compressed headers");
|
assert (UseCompressedClassPointers, "should only be used for compressed headers");
|
||||||
assert (oop_recorder() != NULL, "this assembler needs an OopRecorder");
|
assert (oop_recorder() != NULL, "this assembler needs an OopRecorder");
|
||||||
int klass_index = oop_recorder()->find_index(k);
|
int klass_index = oop_recorder()->find_index(k);
|
||||||
RelocationHolder rspec = metadata_Relocation::spec(klass_index);
|
RelocationHolder rspec = metadata_Relocation::spec(klass_index);
|
||||||
|
@ -5175,7 +5175,7 @@ void MacroAssembler::cmp_narrow_oop(Address dst, jobject obj) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void MacroAssembler::cmp_narrow_klass(Register dst, Klass* k) {
|
void MacroAssembler::cmp_narrow_klass(Register dst, Klass* k) {
|
||||||
assert (UseCompressedKlassPointers, "should only be used for compressed headers");
|
assert (UseCompressedClassPointers, "should only be used for compressed headers");
|
||||||
assert (oop_recorder() != NULL, "this assembler needs an OopRecorder");
|
assert (oop_recorder() != NULL, "this assembler needs an OopRecorder");
|
||||||
int klass_index = oop_recorder()->find_index(k);
|
int klass_index = oop_recorder()->find_index(k);
|
||||||
RelocationHolder rspec = metadata_Relocation::spec(klass_index);
|
RelocationHolder rspec = metadata_Relocation::spec(klass_index);
|
||||||
|
@ -5183,7 +5183,7 @@ void MacroAssembler::cmp_narrow_klass(Register dst, Klass* k) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void MacroAssembler::cmp_narrow_klass(Address dst, Klass* k) {
|
void MacroAssembler::cmp_narrow_klass(Address dst, Klass* k) {
|
||||||
assert (UseCompressedKlassPointers, "should only be used for compressed headers");
|
assert (UseCompressedClassPointers, "should only be used for compressed headers");
|
||||||
assert (oop_recorder() != NULL, "this assembler needs an OopRecorder");
|
assert (oop_recorder() != NULL, "this assembler needs an OopRecorder");
|
||||||
int klass_index = oop_recorder()->find_index(k);
|
int klass_index = oop_recorder()->find_index(k);
|
||||||
RelocationHolder rspec = metadata_Relocation::spec(klass_index);
|
RelocationHolder rspec = metadata_Relocation::spec(klass_index);
|
||||||
|
@ -5191,7 +5191,7 @@ void MacroAssembler::cmp_narrow_klass(Address dst, Klass* k) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void MacroAssembler::reinit_heapbase() {
|
void MacroAssembler::reinit_heapbase() {
|
||||||
if (UseCompressedOops || UseCompressedKlassPointers) {
|
if (UseCompressedOops || UseCompressedClassPointers) {
|
||||||
if (Universe::heap() != NULL) {
|
if (Universe::heap() != NULL) {
|
||||||
if (Universe::narrow_oop_base() == NULL) {
|
if (Universe::narrow_oop_base() == NULL) {
|
||||||
MacroAssembler::xorptr(r12_heapbase, r12_heapbase);
|
MacroAssembler::xorptr(r12_heapbase, r12_heapbase);
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
|
@ -114,6 +114,11 @@ void MethodHandles::verify_ref_kind(MacroAssembler* _masm, int ref_kind, Registe
|
||||||
void MethodHandles::jump_from_method_handle(MacroAssembler* _masm, Register method, Register temp,
|
void MethodHandles::jump_from_method_handle(MacroAssembler* _masm, Register method, Register temp,
|
||||||
bool for_compiler_entry) {
|
bool for_compiler_entry) {
|
||||||
assert(method == rbx, "interpreter calling convention");
|
assert(method == rbx, "interpreter calling convention");
|
||||||
|
|
||||||
|
Label L_no_such_method;
|
||||||
|
__ testptr(rbx, rbx);
|
||||||
|
__ jcc(Assembler::zero, L_no_such_method);
|
||||||
|
|
||||||
__ verify_method_ptr(method);
|
__ verify_method_ptr(method);
|
||||||
|
|
||||||
if (!for_compiler_entry && JvmtiExport::can_post_interpreter_events()) {
|
if (!for_compiler_entry && JvmtiExport::can_post_interpreter_events()) {
|
||||||
|
@ -138,6 +143,9 @@ void MethodHandles::jump_from_method_handle(MacroAssembler* _masm, Register meth
|
||||||
const ByteSize entry_offset = for_compiler_entry ? Method::from_compiled_offset() :
|
const ByteSize entry_offset = for_compiler_entry ? Method::from_compiled_offset() :
|
||||||
Method::from_interpreted_offset();
|
Method::from_interpreted_offset();
|
||||||
__ jmp(Address(method, entry_offset));
|
__ jmp(Address(method, entry_offset));
|
||||||
|
|
||||||
|
__ bind(L_no_such_method);
|
||||||
|
__ jump(RuntimeAddress(StubRoutines::throw_AbstractMethodError_entry()));
|
||||||
}
|
}
|
||||||
|
|
||||||
void MethodHandles::jump_to_lambda_form(MacroAssembler* _masm,
|
void MethodHandles::jump_to_lambda_form(MacroAssembler* _masm,
|
||||||
|
@ -475,7 +483,7 @@ void trace_method_handle_stub(const char* adaptername,
|
||||||
const char* mh_reg_name = has_mh ? "rcx_mh" : "rcx";
|
const char* mh_reg_name = has_mh ? "rcx_mh" : "rcx";
|
||||||
tty->print_cr("MH %s %s="PTR_FORMAT" sp="PTR_FORMAT,
|
tty->print_cr("MH %s %s="PTR_FORMAT" sp="PTR_FORMAT,
|
||||||
adaptername, mh_reg_name,
|
adaptername, mh_reg_name,
|
||||||
mh, entry_sp);
|
(void *)mh, entry_sp);
|
||||||
|
|
||||||
if (Verbose) {
|
if (Verbose) {
|
||||||
tty->print_cr("Registers:");
|
tty->print_cr("Registers:");
|
||||||
|
|
|
@ -34,9 +34,9 @@
|
||||||
// Run with +PrintInterpreter to get the VM to print out the size.
|
// Run with +PrintInterpreter to get the VM to print out the size.
|
||||||
// Max size with JVMTI
|
// Max size with JVMTI
|
||||||
#ifdef AMD64
|
#ifdef AMD64
|
||||||
const static int InterpreterCodeSize = 200 * 1024;
|
const static int InterpreterCodeSize = 208 * 1024;
|
||||||
#else
|
#else
|
||||||
const static int InterpreterCodeSize = 168 * 1024;
|
const static int InterpreterCodeSize = 176 * 1024;
|
||||||
#endif // AMD64
|
#endif // AMD64
|
||||||
|
|
||||||
#endif // CPU_X86_VM_TEMPLATEINTERPRETER_X86_HPP
|
#endif // CPU_X86_VM_TEMPLATEINTERPRETER_X86_HPP
|
||||||
|
|
|
@ -58,6 +58,11 @@ extern "C" void bad_compiled_vtable_index(JavaThread* thread, oop receiver, int
|
||||||
VtableStub* VtableStubs::create_vtable_stub(int vtable_index) {
|
VtableStub* VtableStubs::create_vtable_stub(int vtable_index) {
|
||||||
const int i486_code_length = VtableStub::pd_code_size_limit(true);
|
const int i486_code_length = VtableStub::pd_code_size_limit(true);
|
||||||
VtableStub* s = new(i486_code_length) VtableStub(true, vtable_index);
|
VtableStub* s = new(i486_code_length) VtableStub(true, vtable_index);
|
||||||
|
// Can be NULL if there is no free space in the code cache.
|
||||||
|
if (s == NULL) {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
ResourceMark rm;
|
ResourceMark rm;
|
||||||
CodeBuffer cb(s->entry_point(), i486_code_length);
|
CodeBuffer cb(s->entry_point(), i486_code_length);
|
||||||
MacroAssembler* masm = new MacroAssembler(&cb);
|
MacroAssembler* masm = new MacroAssembler(&cb);
|
||||||
|
@ -132,6 +137,11 @@ VtableStub* VtableStubs::create_itable_stub(int itable_index) {
|
||||||
// add code here, bump the code stub size returned by pd_code_size_limit!
|
// add code here, bump the code stub size returned by pd_code_size_limit!
|
||||||
const int i486_code_length = VtableStub::pd_code_size_limit(false);
|
const int i486_code_length = VtableStub::pd_code_size_limit(false);
|
||||||
VtableStub* s = new(i486_code_length) VtableStub(false, itable_index);
|
VtableStub* s = new(i486_code_length) VtableStub(false, itable_index);
|
||||||
|
// Can be NULL if there is no free space in the code cache.
|
||||||
|
if (s == NULL) {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
ResourceMark rm;
|
ResourceMark rm;
|
||||||
CodeBuffer cb(s->entry_point(), i486_code_length);
|
CodeBuffer cb(s->entry_point(), i486_code_length);
|
||||||
MacroAssembler* masm = new MacroAssembler(&cb);
|
MacroAssembler* masm = new MacroAssembler(&cb);
|
||||||
|
|
|
@ -49,6 +49,11 @@ extern "C" void bad_compiled_vtable_index(JavaThread* thread,
|
||||||
VtableStub* VtableStubs::create_vtable_stub(int vtable_index) {
|
VtableStub* VtableStubs::create_vtable_stub(int vtable_index) {
|
||||||
const int amd64_code_length = VtableStub::pd_code_size_limit(true);
|
const int amd64_code_length = VtableStub::pd_code_size_limit(true);
|
||||||
VtableStub* s = new(amd64_code_length) VtableStub(true, vtable_index);
|
VtableStub* s = new(amd64_code_length) VtableStub(true, vtable_index);
|
||||||
|
// Can be NULL if there is no free space in the code cache.
|
||||||
|
if (s == NULL) {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
ResourceMark rm;
|
ResourceMark rm;
|
||||||
CodeBuffer cb(s->entry_point(), amd64_code_length);
|
CodeBuffer cb(s->entry_point(), amd64_code_length);
|
||||||
MacroAssembler* masm = new MacroAssembler(&cb);
|
MacroAssembler* masm = new MacroAssembler(&cb);
|
||||||
|
@ -126,6 +131,11 @@ VtableStub* VtableStubs::create_itable_stub(int itable_index) {
|
||||||
// returned by pd_code_size_limit!
|
// returned by pd_code_size_limit!
|
||||||
const int amd64_code_length = VtableStub::pd_code_size_limit(false);
|
const int amd64_code_length = VtableStub::pd_code_size_limit(false);
|
||||||
VtableStub* s = new(amd64_code_length) VtableStub(false, itable_index);
|
VtableStub* s = new(amd64_code_length) VtableStub(false, itable_index);
|
||||||
|
// Can be NULL if there is no free space in the code cache.
|
||||||
|
if (s == NULL) {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
ResourceMark rm;
|
ResourceMark rm;
|
||||||
CodeBuffer cb(s->entry_point(), amd64_code_length);
|
CodeBuffer cb(s->entry_point(), amd64_code_length);
|
||||||
MacroAssembler* masm = new MacroAssembler(&cb);
|
MacroAssembler* masm = new MacroAssembler(&cb);
|
||||||
|
@ -211,11 +221,11 @@ int VtableStub::pd_code_size_limit(bool is_vtable_stub) {
|
||||||
if (is_vtable_stub) {
|
if (is_vtable_stub) {
|
||||||
// Vtable stub size
|
// Vtable stub size
|
||||||
return (DebugVtables ? 512 : 24) + (CountCompiledCalls ? 13 : 0) +
|
return (DebugVtables ? 512 : 24) + (CountCompiledCalls ? 13 : 0) +
|
||||||
(UseCompressedKlassPointers ? MacroAssembler::instr_size_for_decode_klass_not_null() : 0);
|
(UseCompressedClassPointers ? MacroAssembler::instr_size_for_decode_klass_not_null() : 0);
|
||||||
} else {
|
} else {
|
||||||
// Itable stub size
|
// Itable stub size
|
||||||
return (DebugVtables ? 512 : 74) + (CountCompiledCalls ? 13 : 0) +
|
return (DebugVtables ? 512 : 74) + (CountCompiledCalls ? 13 : 0) +
|
||||||
(UseCompressedKlassPointers ? MacroAssembler::instr_size_for_decode_klass_not_null() : 0);
|
(UseCompressedClassPointers ? MacroAssembler::instr_size_for_decode_klass_not_null() : 0);
|
||||||
}
|
}
|
||||||
// In order to tune these parameters, run the JVM with VM options
|
// In order to tune these parameters, run the JVM with VM options
|
||||||
// +PrintMiscellaneous and +WizardMode to see information about
|
// +PrintMiscellaneous and +WizardMode to see information about
|
||||||
|
|
|
@ -351,7 +351,7 @@ void emit_d32_reloc(CodeBuffer &cbuf, int d32, RelocationHolder const& rspec,
|
||||||
int format) {
|
int format) {
|
||||||
#ifdef ASSERT
|
#ifdef ASSERT
|
||||||
if (rspec.reloc()->type() == relocInfo::oop_type && d32 != 0 && d32 != (int)Universe::non_oop_word()) {
|
if (rspec.reloc()->type() == relocInfo::oop_type && d32 != 0 && d32 != (int)Universe::non_oop_word()) {
|
||||||
assert(oop(d32)->is_oop() && (ScavengeRootsInCode || !oop(d32)->is_scavengable()), "cannot embed scavengable oops in code");
|
assert(cast_to_oop(d32)->is_oop() && (ScavengeRootsInCode || !cast_to_oop(d32)->is_scavengable()), "cannot embed scavengable oops in code");
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
cbuf.relocate(cbuf.insts_mark(), rspec, format);
|
cbuf.relocate(cbuf.insts_mark(), rspec, format);
|
||||||
|
@ -1534,6 +1534,14 @@ const RegMask Matcher::method_handle_invoke_SP_save_mask() {
|
||||||
return EBP_REG_mask();
|
return EBP_REG_mask();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const RegMask Matcher::mathExactI_result_proj_mask() {
|
||||||
|
return EAX_REG_mask();
|
||||||
|
}
|
||||||
|
|
||||||
|
const RegMask Matcher::mathExactI_flags_proj_mask() {
|
||||||
|
return INT_FLAGS_mask();
|
||||||
|
}
|
||||||
|
|
||||||
// Returns true if the high 32 bits of the value is known to be zero.
|
// Returns true if the high 32 bits of the value is known to be zero.
|
||||||
bool is_operand_hi32_zero(Node* n) {
|
bool is_operand_hi32_zero(Node* n) {
|
||||||
int opc = n->Opcode();
|
int opc = n->Opcode();
|
||||||
|
@ -4922,6 +4930,8 @@ operand cmpOp() %{
|
||||||
greater_equal(0xD, "ge");
|
greater_equal(0xD, "ge");
|
||||||
less_equal(0xE, "le");
|
less_equal(0xE, "le");
|
||||||
greater(0xF, "g");
|
greater(0xF, "g");
|
||||||
|
overflow(0x0, "o");
|
||||||
|
no_overflow(0x1, "no");
|
||||||
%}
|
%}
|
||||||
%}
|
%}
|
||||||
|
|
||||||
|
@ -4939,6 +4949,8 @@ operand cmpOpU() %{
|
||||||
greater_equal(0x3, "nb");
|
greater_equal(0x3, "nb");
|
||||||
less_equal(0x6, "be");
|
less_equal(0x6, "be");
|
||||||
greater(0x7, "nbe");
|
greater(0x7, "nbe");
|
||||||
|
overflow(0x0, "o");
|
||||||
|
no_overflow(0x1, "no");
|
||||||
%}
|
%}
|
||||||
%}
|
%}
|
||||||
|
|
||||||
|
@ -4957,6 +4969,8 @@ operand cmpOpUCF() %{
|
||||||
greater_equal(0x3, "nb");
|
greater_equal(0x3, "nb");
|
||||||
less_equal(0x6, "be");
|
less_equal(0x6, "be");
|
||||||
greater(0x7, "nbe");
|
greater(0x7, "nbe");
|
||||||
|
overflow(0x0, "o");
|
||||||
|
no_overflow(0x1, "no");
|
||||||
%}
|
%}
|
||||||
%}
|
%}
|
||||||
|
|
||||||
|
@ -4974,6 +4988,8 @@ operand cmpOpUCF2() %{
|
||||||
greater_equal(0x3, "nb");
|
greater_equal(0x3, "nb");
|
||||||
less_equal(0x6, "be");
|
less_equal(0x6, "be");
|
||||||
greater(0x7, "nbe");
|
greater(0x7, "nbe");
|
||||||
|
overflow(0x0, "o");
|
||||||
|
no_overflow(0x1, "no");
|
||||||
%}
|
%}
|
||||||
%}
|
%}
|
||||||
|
|
||||||
|
@ -4981,6 +4997,8 @@ operand cmpOpUCF2() %{
|
||||||
operand cmpOp_fcmov() %{
|
operand cmpOp_fcmov() %{
|
||||||
match(Bool);
|
match(Bool);
|
||||||
|
|
||||||
|
predicate(n->as_Bool()->_test._test != BoolTest::overflow &&
|
||||||
|
n->as_Bool()->_test._test != BoolTest::no_overflow);
|
||||||
format %{ "" %}
|
format %{ "" %}
|
||||||
interface(COND_INTER) %{
|
interface(COND_INTER) %{
|
||||||
equal (0x0C8);
|
equal (0x0C8);
|
||||||
|
@ -4989,6 +5007,8 @@ operand cmpOp_fcmov() %{
|
||||||
greater_equal(0x1C0);
|
greater_equal(0x1C0);
|
||||||
less_equal (0x0D0);
|
less_equal (0x0D0);
|
||||||
greater (0x1D0);
|
greater (0x1D0);
|
||||||
|
overflow(0x0, "o"); // not really supported by the instruction
|
||||||
|
no_overflow(0x1, "no"); // not really supported by the instruction
|
||||||
%}
|
%}
|
||||||
%}
|
%}
|
||||||
|
|
||||||
|
@ -5004,6 +5024,8 @@ operand cmpOp_commute() %{
|
||||||
greater_equal(0xE, "le");
|
greater_equal(0xE, "le");
|
||||||
less_equal(0xD, "ge");
|
less_equal(0xD, "ge");
|
||||||
greater(0xC, "l");
|
greater(0xC, "l");
|
||||||
|
overflow(0x0, "o");
|
||||||
|
no_overflow(0x1, "no");
|
||||||
%}
|
%}
|
||||||
%}
|
%}
|
||||||
|
|
||||||
|
@ -7496,6 +7518,31 @@ instruct cmovL_regUCF(cmpOpUCF cop, eFlagsRegUCF cr, eRegL dst, eRegL src) %{
|
||||||
|
|
||||||
//----------Arithmetic Instructions--------------------------------------------
|
//----------Arithmetic Instructions--------------------------------------------
|
||||||
//----------Addition Instructions----------------------------------------------
|
//----------Addition Instructions----------------------------------------------
|
||||||
|
|
||||||
|
instruct addExactI_rReg(eAXRegI dst, rRegI src, eFlagsReg cr)
|
||||||
|
%{
|
||||||
|
match(AddExactI dst src);
|
||||||
|
effect(DEF cr);
|
||||||
|
|
||||||
|
format %{ "ADD $dst, $src\t# addExact int" %}
|
||||||
|
ins_encode %{
|
||||||
|
__ addl($dst$$Register, $src$$Register);
|
||||||
|
%}
|
||||||
|
ins_pipe(ialu_reg_reg);
|
||||||
|
%}
|
||||||
|
|
||||||
|
instruct addExactI_rReg_imm(eAXRegI dst, immI src, eFlagsReg cr)
|
||||||
|
%{
|
||||||
|
match(AddExactI dst src);
|
||||||
|
effect(DEF cr);
|
||||||
|
|
||||||
|
format %{ "ADD $dst, $src\t# addExact int" %}
|
||||||
|
ins_encode %{
|
||||||
|
__ addl($dst$$Register, $src$$constant);
|
||||||
|
%}
|
||||||
|
ins_pipe(ialu_reg_reg);
|
||||||
|
%}
|
||||||
|
|
||||||
// Integer Addition Instructions
|
// Integer Addition Instructions
|
||||||
instruct addI_eReg(rRegI dst, rRegI src, eFlagsReg cr) %{
|
instruct addI_eReg(rRegI dst, rRegI src, eFlagsReg cr) %{
|
||||||
match(Set dst (AddI dst src));
|
match(Set dst (AddI dst src));
|
||||||
|
|
|
@ -529,7 +529,7 @@ void emit_d32_reloc(CodeBuffer& cbuf, int d32, RelocationHolder const& rspec, in
|
||||||
if (rspec.reloc()->type() == relocInfo::oop_type &&
|
if (rspec.reloc()->type() == relocInfo::oop_type &&
|
||||||
d32 != 0 && d32 != (intptr_t) Universe::non_oop_word()) {
|
d32 != 0 && d32 != (intptr_t) Universe::non_oop_word()) {
|
||||||
assert(Universe::heap()->is_in_reserved((address)(intptr_t)d32), "should be real oop");
|
assert(Universe::heap()->is_in_reserved((address)(intptr_t)d32), "should be real oop");
|
||||||
assert(oop((intptr_t)d32)->is_oop() && (ScavengeRootsInCode || !oop((intptr_t)d32)->is_scavengable()), "cannot embed scavengable oops in code");
|
assert(cast_to_oop((intptr_t)d32)->is_oop() && (ScavengeRootsInCode || !cast_to_oop((intptr_t)d32)->is_scavengable()), "cannot embed scavengable oops in code");
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
cbuf.relocate(cbuf.insts_mark(), rspec, format);
|
cbuf.relocate(cbuf.insts_mark(), rspec, format);
|
||||||
|
@ -556,7 +556,7 @@ void emit_d64_reloc(CodeBuffer& cbuf, int64_t d64, RelocationHolder const& rspec
|
||||||
if (rspec.reloc()->type() == relocInfo::oop_type &&
|
if (rspec.reloc()->type() == relocInfo::oop_type &&
|
||||||
d64 != 0 && d64 != (int64_t) Universe::non_oop_word()) {
|
d64 != 0 && d64 != (int64_t) Universe::non_oop_word()) {
|
||||||
assert(Universe::heap()->is_in_reserved((address)d64), "should be real oop");
|
assert(Universe::heap()->is_in_reserved((address)d64), "should be real oop");
|
||||||
assert(oop(d64)->is_oop() && (ScavengeRootsInCode || !oop(d64)->is_scavengable()),
|
assert(cast_to_oop(d64)->is_oop() && (ScavengeRootsInCode || !cast_to_oop(d64)->is_scavengable()),
|
||||||
"cannot embed scavengable oops in code");
|
"cannot embed scavengable oops in code");
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@ -1391,7 +1391,7 @@ uint BoxLockNode::size(PhaseRegAlloc *ra_) const
|
||||||
#ifndef PRODUCT
|
#ifndef PRODUCT
|
||||||
void MachUEPNode::format(PhaseRegAlloc* ra_, outputStream* st) const
|
void MachUEPNode::format(PhaseRegAlloc* ra_, outputStream* st) const
|
||||||
{
|
{
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
st->print_cr("movl rscratch1, [j_rarg0 + oopDesc::klass_offset_in_bytes()]\t# compressed klass");
|
st->print_cr("movl rscratch1, [j_rarg0 + oopDesc::klass_offset_in_bytes()]\t# compressed klass");
|
||||||
st->print_cr("\tdecode_klass_not_null rscratch1, rscratch1");
|
st->print_cr("\tdecode_klass_not_null rscratch1, rscratch1");
|
||||||
st->print_cr("\tcmpq rax, rscratch1\t # Inline cache check");
|
st->print_cr("\tcmpq rax, rscratch1\t # Inline cache check");
|
||||||
|
@ -1408,7 +1408,7 @@ void MachUEPNode::emit(CodeBuffer& cbuf, PhaseRegAlloc* ra_) const
|
||||||
{
|
{
|
||||||
MacroAssembler masm(&cbuf);
|
MacroAssembler masm(&cbuf);
|
||||||
uint insts_size = cbuf.insts_size();
|
uint insts_size = cbuf.insts_size();
|
||||||
if (UseCompressedKlassPointers) {
|
if (UseCompressedClassPointers) {
|
||||||
masm.load_klass(rscratch1, j_rarg0);
|
masm.load_klass(rscratch1, j_rarg0);
|
||||||
masm.cmpptr(rax, rscratch1);
|
masm.cmpptr(rax, rscratch1);
|
||||||
} else {
|
} else {
|
||||||
|
@ -1557,7 +1557,7 @@ bool Matcher::narrow_oop_use_complex_address() {
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Matcher::narrow_klass_use_complex_address() {
|
bool Matcher::narrow_klass_use_complex_address() {
|
||||||
assert(UseCompressedKlassPointers, "only for compressed klass code");
|
assert(UseCompressedClassPointers, "only for compressed klass code");
|
||||||
return (LogKlassAlignmentInBytes <= 3);
|
return (LogKlassAlignmentInBytes <= 3);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1649,6 +1649,14 @@ const RegMask Matcher::method_handle_invoke_SP_save_mask() {
|
||||||
return PTR_RBP_REG_mask();
|
return PTR_RBP_REG_mask();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const RegMask Matcher::mathExactI_result_proj_mask() {
|
||||||
|
return INT_RAX_REG_mask();
|
||||||
|
}
|
||||||
|
|
||||||
|
const RegMask Matcher::mathExactI_flags_proj_mask() {
|
||||||
|
return INT_FLAGS_mask();
|
||||||
|
}
|
||||||
|
|
||||||
%}
|
%}
|
||||||
|
|
||||||
//----------ENCODING BLOCK-----------------------------------------------------
|
//----------ENCODING BLOCK-----------------------------------------------------
|
||||||
|
@ -4133,6 +4141,8 @@ operand cmpOp()
|
||||||
greater_equal(0xD, "ge");
|
greater_equal(0xD, "ge");
|
||||||
less_equal(0xE, "le");
|
less_equal(0xE, "le");
|
||||||
greater(0xF, "g");
|
greater(0xF, "g");
|
||||||
|
overflow(0x0, "o");
|
||||||
|
no_overflow(0x1, "no");
|
||||||
%}
|
%}
|
||||||
%}
|
%}
|
||||||
|
|
||||||
|
@ -4151,6 +4161,8 @@ operand cmpOpU()
|
||||||
greater_equal(0x3, "nb");
|
greater_equal(0x3, "nb");
|
||||||
less_equal(0x6, "be");
|
less_equal(0x6, "be");
|
||||||
greater(0x7, "nbe");
|
greater(0x7, "nbe");
|
||||||
|
overflow(0x0, "o");
|
||||||
|
no_overflow(0x1, "no");
|
||||||
%}
|
%}
|
||||||
%}
|
%}
|
||||||
|
|
||||||
|
@ -4170,6 +4182,8 @@ operand cmpOpUCF() %{
|
||||||
greater_equal(0x3, "nb");
|
greater_equal(0x3, "nb");
|
||||||
less_equal(0x6, "be");
|
less_equal(0x6, "be");
|
||||||
greater(0x7, "nbe");
|
greater(0x7, "nbe");
|
||||||
|
overflow(0x0, "o");
|
||||||
|
no_overflow(0x1, "no");
|
||||||
%}
|
%}
|
||||||
%}
|
%}
|
||||||
|
|
||||||
|
@ -4187,6 +4201,8 @@ operand cmpOpUCF2() %{
|
||||||
greater_equal(0x3, "nb");
|
greater_equal(0x3, "nb");
|
||||||
less_equal(0x6, "be");
|
less_equal(0x6, "be");
|
||||||
greater(0x7, "nbe");
|
greater(0x7, "nbe");
|
||||||
|
overflow(0x0, "o");
|
||||||
|
no_overflow(0x1, "no");
|
||||||
%}
|
%}
|
||||||
%}
|
%}
|
||||||
|
|
||||||
|
@ -6922,6 +6938,30 @@ instruct cmovD_regUCF(cmpOpUCF cop, rFlagsRegUCF cr, regD dst, regD src) %{
|
||||||
//----------Arithmetic Instructions--------------------------------------------
|
//----------Arithmetic Instructions--------------------------------------------
|
||||||
//----------Addition Instructions----------------------------------------------
|
//----------Addition Instructions----------------------------------------------
|
||||||
|
|
||||||
|
instruct addExactI_rReg(rax_RegI dst, rRegI src, rFlagsReg cr)
|
||||||
|
%{
|
||||||
|
match(AddExactI dst src);
|
||||||
|
effect(DEF cr);
|
||||||
|
|
||||||
|
format %{ "addl $dst, $src\t# addExact int" %}
|
||||||
|
ins_encode %{
|
||||||
|
__ addl($dst$$Register, $src$$Register);
|
||||||
|
%}
|
||||||
|
ins_pipe(ialu_reg_reg);
|
||||||
|
%}
|
||||||
|
|
||||||
|
instruct addExactI_rReg_imm(rax_RegI dst, immI src, rFlagsReg cr)
|
||||||
|
%{
|
||||||
|
match(AddExactI dst src);
|
||||||
|
effect(DEF cr);
|
||||||
|
|
||||||
|
format %{ "addl $dst, $src\t# addExact int" %}
|
||||||
|
ins_encode %{
|
||||||
|
__ addl($dst$$Register, $src$$constant);
|
||||||
|
%}
|
||||||
|
ins_pipe(ialu_reg_reg);
|
||||||
|
%}
|
||||||
|
|
||||||
instruct addI_rReg(rRegI dst, rRegI src, rFlagsReg cr)
|
instruct addI_rReg(rRegI dst, rRegI src, rFlagsReg cr)
|
||||||
%{
|
%{
|
||||||
match(Set dst (AddI dst src));
|
match(Set dst (AddI dst src));
|
||||||
|
|
|
@ -3589,8 +3589,6 @@ jint os::init_2(void)
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
os::large_page_init();
|
|
||||||
|
|
||||||
// initialize suspend/resume support - must do this before signal_sets_init()
|
// initialize suspend/resume support - must do this before signal_sets_init()
|
||||||
if (SR_initialize() != 0) {
|
if (SR_initialize() != 0) {
|
||||||
perror("SR_initialize failed");
|
perror("SR_initialize failed");
|
||||||
|
|
|
@ -131,6 +131,7 @@ bool os::Linux::_is_NPTL = false;
|
||||||
bool os::Linux::_supports_fast_thread_cpu_time = false;
|
bool os::Linux::_supports_fast_thread_cpu_time = false;
|
||||||
const char * os::Linux::_glibc_version = NULL;
|
const char * os::Linux::_glibc_version = NULL;
|
||||||
const char * os::Linux::_libpthread_version = NULL;
|
const char * os::Linux::_libpthread_version = NULL;
|
||||||
|
pthread_condattr_t os::Linux::_condattr[1];
|
||||||
|
|
||||||
static jlong initial_time_count=0;
|
static jlong initial_time_count=0;
|
||||||
|
|
||||||
|
@ -1399,12 +1400,15 @@ void os::Linux::clock_init() {
|
||||||
clock_gettime_func(CLOCK_MONOTONIC, &tp) == 0) {
|
clock_gettime_func(CLOCK_MONOTONIC, &tp) == 0) {
|
||||||
// yes, monotonic clock is supported
|
// yes, monotonic clock is supported
|
||||||
_clock_gettime = clock_gettime_func;
|
_clock_gettime = clock_gettime_func;
|
||||||
|
return;
|
||||||
} else {
|
} else {
|
||||||
// close librt if there is no monotonic clock
|
// close librt if there is no monotonic clock
|
||||||
dlclose(handle);
|
dlclose(handle);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
warning("No monotonic clock was available - timed services may " \
|
||||||
|
"be adversely affected if the time-of-day clock changes");
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef SYS_clock_getres
|
#ifndef SYS_clock_getres
|
||||||
|
@ -2165,23 +2169,49 @@ void os::print_os_info(outputStream* st) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Try to identify popular distros.
|
// Try to identify popular distros.
|
||||||
// Most Linux distributions have /etc/XXX-release file, which contains
|
// Most Linux distributions have a /etc/XXX-release file, which contains
|
||||||
// the OS version string. Some have more than one /etc/XXX-release file
|
// the OS version string. Newer Linux distributions have a /etc/lsb-release
|
||||||
// (e.g. Mandrake has both /etc/mandrake-release and /etc/redhat-release.),
|
// file that also contains the OS version string. Some have more than one
|
||||||
// so the order is important.
|
// /etc/XXX-release file (e.g. Mandrake has both /etc/mandrake-release and
|
||||||
|
// /etc/redhat-release.), so the order is important.
|
||||||
|
// Any Linux that is based on Redhat (i.e. Oracle, Mandrake, Sun JDS...) have
|
||||||
|
// their own specific XXX-release file as well as a redhat-release file.
|
||||||
|
// Because of this the XXX-release file needs to be searched for before the
|
||||||
|
// redhat-release file.
|
||||||
|
// Since Red Hat has a lsb-release file that is not very descriptive the
|
||||||
|
// search for redhat-release needs to be before lsb-release.
|
||||||
|
// Since the lsb-release file is the new standard it needs to be searched
|
||||||
|
// before the older style release files.
|
||||||
|
// Searching system-release (Red Hat) and os-release (other Linuxes) are a
|
||||||
|
// next to last resort. The os-release file is a new standard that contains
|
||||||
|
// distribution information and the system-release file seems to be an old
|
||||||
|
// standard that has been replaced by the lsb-release and os-release files.
|
||||||
|
// Searching for the debian_version file is the last resort. It contains
|
||||||
|
// an informative string like "6.0.6" or "wheezy/sid". Because of this
|
||||||
|
// "Debian " is printed before the contents of the debian_version file.
|
||||||
void os::Linux::print_distro_info(outputStream* st) {
|
void os::Linux::print_distro_info(outputStream* st) {
|
||||||
if (!_print_ascii_file("/etc/mandrake-release", st) &&
|
if (!_print_ascii_file("/etc/oracle-release", st) &&
|
||||||
!_print_ascii_file("/etc/sun-release", st) &&
|
!_print_ascii_file("/etc/mandriva-release", st) &&
|
||||||
!_print_ascii_file("/etc/redhat-release", st) &&
|
!_print_ascii_file("/etc/mandrake-release", st) &&
|
||||||
!_print_ascii_file("/etc/SuSE-release", st) &&
|
!_print_ascii_file("/etc/sun-release", st) &&
|
||||||
!_print_ascii_file("/etc/turbolinux-release", st) &&
|
!_print_ascii_file("/etc/redhat-release", st) &&
|
||||||
!_print_ascii_file("/etc/gentoo-release", st) &&
|
!_print_ascii_file("/etc/lsb-release", st) &&
|
||||||
!_print_ascii_file("/etc/debian_version", st) &&
|
!_print_ascii_file("/etc/SuSE-release", st) &&
|
||||||
!_print_ascii_file("/etc/ltib-release", st) &&
|
!_print_ascii_file("/etc/turbolinux-release", st) &&
|
||||||
!_print_ascii_file("/etc/angstrom-version", st)) {
|
!_print_ascii_file("/etc/gentoo-release", st) &&
|
||||||
st->print("Linux");
|
!_print_ascii_file("/etc/ltib-release", st) &&
|
||||||
}
|
!_print_ascii_file("/etc/angstrom-version", st) &&
|
||||||
st->cr();
|
!_print_ascii_file("/etc/system-release", st) &&
|
||||||
|
!_print_ascii_file("/etc/os-release", st)) {
|
||||||
|
|
||||||
|
if (file_exists("/etc/debian_version")) {
|
||||||
|
st->print("Debian ");
|
||||||
|
_print_ascii_file("/etc/debian_version", st);
|
||||||
|
} else {
|
||||||
|
st->print("Linux");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
st->cr();
|
||||||
}
|
}
|
||||||
|
|
||||||
void os::Linux::print_libversion_info(outputStream* st) {
|
void os::Linux::print_libversion_info(outputStream* st) {
|
||||||
|
@ -4709,6 +4739,26 @@ void os::init(void) {
|
||||||
|
|
||||||
Linux::clock_init();
|
Linux::clock_init();
|
||||||
initial_time_count = os::elapsed_counter();
|
initial_time_count = os::elapsed_counter();
|
||||||
|
|
||||||
|
// pthread_condattr initialization for monotonic clock
|
||||||
|
int status;
|
||||||
|
pthread_condattr_t* _condattr = os::Linux::condAttr();
|
||||||
|
if ((status = pthread_condattr_init(_condattr)) != 0) {
|
||||||
|
fatal(err_msg("pthread_condattr_init: %s", strerror(status)));
|
||||||
|
}
|
||||||
|
// Only set the clock if CLOCK_MONOTONIC is available
|
||||||
|
if (Linux::supports_monotonic_clock()) {
|
||||||
|
if ((status = pthread_condattr_setclock(_condattr, CLOCK_MONOTONIC)) != 0) {
|
||||||
|
if (status == EINVAL) {
|
||||||
|
warning("Unable to use monotonic clock with relative timed-waits" \
|
||||||
|
" - changes to the time-of-day clock may have adverse affects");
|
||||||
|
} else {
|
||||||
|
fatal(err_msg("pthread_condattr_setclock: %s", strerror(status)));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// else it defaults to CLOCK_REALTIME
|
||||||
|
|
||||||
pthread_mutex_init(&dl_mutex, NULL);
|
pthread_mutex_init(&dl_mutex, NULL);
|
||||||
|
|
||||||
// If the pagesize of the VM is greater than 8K determine the appropriate
|
// If the pagesize of the VM is greater than 8K determine the appropriate
|
||||||
|
@ -4755,8 +4805,6 @@ jint os::init_2(void)
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
os::large_page_init();
|
|
||||||
|
|
||||||
// initialize suspend/resume support - must do this before signal_sets_init()
|
// initialize suspend/resume support - must do this before signal_sets_init()
|
||||||
if (SR_initialize() != 0) {
|
if (SR_initialize() != 0) {
|
||||||
perror("SR_initialize failed");
|
perror("SR_initialize failed");
|
||||||
|
@ -4791,6 +4839,10 @@ jint os::init_2(void)
|
||||||
|
|
||||||
Linux::capture_initial_stack(JavaThread::stack_size_at_create());
|
Linux::capture_initial_stack(JavaThread::stack_size_at_create());
|
||||||
|
|
||||||
|
#if defined(IA32)
|
||||||
|
workaround_expand_exec_shield_cs_limit();
|
||||||
|
#endif
|
||||||
|
|
||||||
Linux::libpthread_init();
|
Linux::libpthread_init();
|
||||||
if (PrintMiscellaneous && (Verbose || WizardMode)) {
|
if (PrintMiscellaneous && (Verbose || WizardMode)) {
|
||||||
tty->print_cr("[HotSpot is running with %s, %s(%s)]\n",
|
tty->print_cr("[HotSpot is running with %s, %s(%s)]\n",
|
||||||
|
@ -5519,21 +5571,36 @@ void os::pause() {
|
||||||
|
|
||||||
static struct timespec* compute_abstime(timespec* abstime, jlong millis) {
|
static struct timespec* compute_abstime(timespec* abstime, jlong millis) {
|
||||||
if (millis < 0) millis = 0;
|
if (millis < 0) millis = 0;
|
||||||
struct timeval now;
|
|
||||||
int status = gettimeofday(&now, NULL);
|
|
||||||
assert(status == 0, "gettimeofday");
|
|
||||||
jlong seconds = millis / 1000;
|
jlong seconds = millis / 1000;
|
||||||
millis %= 1000;
|
millis %= 1000;
|
||||||
if (seconds > 50000000) { // see man cond_timedwait(3T)
|
if (seconds > 50000000) { // see man cond_timedwait(3T)
|
||||||
seconds = 50000000;
|
seconds = 50000000;
|
||||||
}
|
}
|
||||||
abstime->tv_sec = now.tv_sec + seconds;
|
|
||||||
long usec = now.tv_usec + millis * 1000;
|
if (os::Linux::supports_monotonic_clock()) {
|
||||||
if (usec >= 1000000) {
|
struct timespec now;
|
||||||
abstime->tv_sec += 1;
|
int status = os::Linux::clock_gettime(CLOCK_MONOTONIC, &now);
|
||||||
usec -= 1000000;
|
assert_status(status == 0, status, "clock_gettime");
|
||||||
|
abstime->tv_sec = now.tv_sec + seconds;
|
||||||
|
long nanos = now.tv_nsec + millis * NANOSECS_PER_MILLISEC;
|
||||||
|
if (nanos >= NANOSECS_PER_SEC) {
|
||||||
|
abstime->tv_sec += 1;
|
||||||
|
nanos -= NANOSECS_PER_SEC;
|
||||||
|
}
|
||||||
|
abstime->tv_nsec = nanos;
|
||||||
|
} else {
|
||||||
|
struct timeval now;
|
||||||
|
int status = gettimeofday(&now, NULL);
|
||||||
|
assert(status == 0, "gettimeofday");
|
||||||
|
abstime->tv_sec = now.tv_sec + seconds;
|
||||||
|
long usec = now.tv_usec + millis * 1000;
|
||||||
|
if (usec >= 1000000) {
|
||||||
|
abstime->tv_sec += 1;
|
||||||
|
usec -= 1000000;
|
||||||
|
}
|
||||||
|
abstime->tv_nsec = usec * 1000;
|
||||||
}
|
}
|
||||||
abstime->tv_nsec = usec * 1000;
|
|
||||||
return abstime;
|
return abstime;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5625,7 +5692,7 @@ int os::PlatformEvent::park(jlong millis) {
|
||||||
status = os::Linux::safe_cond_timedwait(_cond, _mutex, &abst);
|
status = os::Linux::safe_cond_timedwait(_cond, _mutex, &abst);
|
||||||
if (status != 0 && WorkAroundNPTLTimedWaitHang) {
|
if (status != 0 && WorkAroundNPTLTimedWaitHang) {
|
||||||
pthread_cond_destroy (_cond);
|
pthread_cond_destroy (_cond);
|
||||||
pthread_cond_init (_cond, NULL) ;
|
pthread_cond_init (_cond, os::Linux::condAttr()) ;
|
||||||
}
|
}
|
||||||
assert_status(status == 0 || status == EINTR ||
|
assert_status(status == 0 || status == EINTR ||
|
||||||
status == ETIME || status == ETIMEDOUT,
|
status == ETIME || status == ETIMEDOUT,
|
||||||
|
@ -5726,32 +5793,50 @@ void os::PlatformEvent::unpark() {
|
||||||
|
|
||||||
static void unpackTime(timespec* absTime, bool isAbsolute, jlong time) {
|
static void unpackTime(timespec* absTime, bool isAbsolute, jlong time) {
|
||||||
assert (time > 0, "convertTime");
|
assert (time > 0, "convertTime");
|
||||||
|
time_t max_secs = 0;
|
||||||
|
|
||||||
struct timeval now;
|
if (!os::Linux::supports_monotonic_clock() || isAbsolute) {
|
||||||
int status = gettimeofday(&now, NULL);
|
struct timeval now;
|
||||||
assert(status == 0, "gettimeofday");
|
int status = gettimeofday(&now, NULL);
|
||||||
|
assert(status == 0, "gettimeofday");
|
||||||
|
|
||||||
time_t max_secs = now.tv_sec + MAX_SECS;
|
max_secs = now.tv_sec + MAX_SECS;
|
||||||
|
|
||||||
if (isAbsolute) {
|
if (isAbsolute) {
|
||||||
jlong secs = time / 1000;
|
jlong secs = time / 1000;
|
||||||
if (secs > max_secs) {
|
if (secs > max_secs) {
|
||||||
absTime->tv_sec = max_secs;
|
absTime->tv_sec = max_secs;
|
||||||
|
} else {
|
||||||
|
absTime->tv_sec = secs;
|
||||||
|
}
|
||||||
|
absTime->tv_nsec = (time % 1000) * NANOSECS_PER_MILLISEC;
|
||||||
|
} else {
|
||||||
|
jlong secs = time / NANOSECS_PER_SEC;
|
||||||
|
if (secs >= MAX_SECS) {
|
||||||
|
absTime->tv_sec = max_secs;
|
||||||
|
absTime->tv_nsec = 0;
|
||||||
|
} else {
|
||||||
|
absTime->tv_sec = now.tv_sec + secs;
|
||||||
|
absTime->tv_nsec = (time % NANOSECS_PER_SEC) + now.tv_usec*1000;
|
||||||
|
if (absTime->tv_nsec >= NANOSECS_PER_SEC) {
|
||||||
|
absTime->tv_nsec -= NANOSECS_PER_SEC;
|
||||||
|
++absTime->tv_sec; // note: this must be <= max_secs
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else {
|
} else {
|
||||||
absTime->tv_sec = secs;
|
// must be relative using monotonic clock
|
||||||
}
|
struct timespec now;
|
||||||
absTime->tv_nsec = (time % 1000) * NANOSECS_PER_MILLISEC;
|
int status = os::Linux::clock_gettime(CLOCK_MONOTONIC, &now);
|
||||||
}
|
assert_status(status == 0, status, "clock_gettime");
|
||||||
else {
|
max_secs = now.tv_sec + MAX_SECS;
|
||||||
jlong secs = time / NANOSECS_PER_SEC;
|
jlong secs = time / NANOSECS_PER_SEC;
|
||||||
if (secs >= MAX_SECS) {
|
if (secs >= MAX_SECS) {
|
||||||
absTime->tv_sec = max_secs;
|
absTime->tv_sec = max_secs;
|
||||||
absTime->tv_nsec = 0;
|
absTime->tv_nsec = 0;
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
absTime->tv_sec = now.tv_sec + secs;
|
absTime->tv_sec = now.tv_sec + secs;
|
||||||
absTime->tv_nsec = (time % NANOSECS_PER_SEC) + now.tv_usec*1000;
|
absTime->tv_nsec = (time % NANOSECS_PER_SEC) + now.tv_nsec;
|
||||||
if (absTime->tv_nsec >= NANOSECS_PER_SEC) {
|
if (absTime->tv_nsec >= NANOSECS_PER_SEC) {
|
||||||
absTime->tv_nsec -= NANOSECS_PER_SEC;
|
absTime->tv_nsec -= NANOSECS_PER_SEC;
|
||||||
++absTime->tv_sec; // note: this must be <= max_secs
|
++absTime->tv_sec; // note: this must be <= max_secs
|
||||||
|
@ -5831,15 +5916,19 @@ void Parker::park(bool isAbsolute, jlong time) {
|
||||||
jt->set_suspend_equivalent();
|
jt->set_suspend_equivalent();
|
||||||
// cleared by handle_special_suspend_equivalent_condition() or java_suspend_self()
|
// cleared by handle_special_suspend_equivalent_condition() or java_suspend_self()
|
||||||
|
|
||||||
|
assert(_cur_index == -1, "invariant");
|
||||||
if (time == 0) {
|
if (time == 0) {
|
||||||
status = pthread_cond_wait (_cond, _mutex) ;
|
_cur_index = REL_INDEX; // arbitrary choice when not timed
|
||||||
|
status = pthread_cond_wait (&_cond[_cur_index], _mutex) ;
|
||||||
} else {
|
} else {
|
||||||
status = os::Linux::safe_cond_timedwait (_cond, _mutex, &absTime) ;
|
_cur_index = isAbsolute ? ABS_INDEX : REL_INDEX;
|
||||||
|
status = os::Linux::safe_cond_timedwait (&_cond[_cur_index], _mutex, &absTime) ;
|
||||||
if (status != 0 && WorkAroundNPTLTimedWaitHang) {
|
if (status != 0 && WorkAroundNPTLTimedWaitHang) {
|
||||||
pthread_cond_destroy (_cond) ;
|
pthread_cond_destroy (&_cond[_cur_index]) ;
|
||||||
pthread_cond_init (_cond, NULL);
|
pthread_cond_init (&_cond[_cur_index], isAbsolute ? NULL : os::Linux::condAttr());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
_cur_index = -1;
|
||||||
assert_status(status == 0 || status == EINTR ||
|
assert_status(status == 0 || status == EINTR ||
|
||||||
status == ETIME || status == ETIMEDOUT,
|
status == ETIME || status == ETIMEDOUT,
|
||||||
status, "cond_timedwait");
|
status, "cond_timedwait");
|
||||||
|
@ -5868,17 +5957,24 @@ void Parker::unpark() {
|
||||||
s = _counter;
|
s = _counter;
|
||||||
_counter = 1;
|
_counter = 1;
|
||||||
if (s < 1) {
|
if (s < 1) {
|
||||||
if (WorkAroundNPTLTimedWaitHang) {
|
// thread might be parked
|
||||||
status = pthread_cond_signal (_cond) ;
|
if (_cur_index != -1) {
|
||||||
assert (status == 0, "invariant") ;
|
// thread is definitely parked
|
||||||
|
if (WorkAroundNPTLTimedWaitHang) {
|
||||||
|
status = pthread_cond_signal (&_cond[_cur_index]);
|
||||||
|
assert (status == 0, "invariant");
|
||||||
status = pthread_mutex_unlock(_mutex);
|
status = pthread_mutex_unlock(_mutex);
|
||||||
assert (status == 0, "invariant") ;
|
assert (status == 0, "invariant");
|
||||||
} else {
|
} else {
|
||||||
status = pthread_mutex_unlock(_mutex);
|
status = pthread_mutex_unlock(_mutex);
|
||||||
assert (status == 0, "invariant") ;
|
assert (status == 0, "invariant");
|
||||||
status = pthread_cond_signal (_cond) ;
|
status = pthread_cond_signal (&_cond[_cur_index]);
|
||||||
assert (status == 0, "invariant") ;
|
assert (status == 0, "invariant");
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
pthread_mutex_unlock(_mutex);
|
||||||
|
assert (status == 0, "invariant") ;
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
pthread_mutex_unlock(_mutex);
|
pthread_mutex_unlock(_mutex);
|
||||||
assert (status == 0, "invariant") ;
|
assert (status == 0, "invariant") ;
|
||||||
|
|
|
@ -221,6 +221,13 @@ class Linux {
|
||||||
|
|
||||||
static jlong fast_thread_cpu_time(clockid_t clockid);
|
static jlong fast_thread_cpu_time(clockid_t clockid);
|
||||||
|
|
||||||
|
// pthread_cond clock suppport
|
||||||
|
private:
|
||||||
|
static pthread_condattr_t _condattr[1];
|
||||||
|
|
||||||
|
public:
|
||||||
|
static pthread_condattr_t* condAttr() { return _condattr; }
|
||||||
|
|
||||||
// Stack repair handling
|
// Stack repair handling
|
||||||
|
|
||||||
// none present
|
// none present
|
||||||
|
@ -295,7 +302,7 @@ class PlatformEvent : public CHeapObj<mtInternal> {
|
||||||
public:
|
public:
|
||||||
PlatformEvent() {
|
PlatformEvent() {
|
||||||
int status;
|
int status;
|
||||||
status = pthread_cond_init (_cond, NULL);
|
status = pthread_cond_init (_cond, os::Linux::condAttr());
|
||||||
assert_status(status == 0, status, "cond_init");
|
assert_status(status == 0, status, "cond_init");
|
||||||
status = pthread_mutex_init (_mutex, NULL);
|
status = pthread_mutex_init (_mutex, NULL);
|
||||||
assert_status(status == 0, status, "mutex_init");
|
assert_status(status == 0, status, "mutex_init");
|
||||||
|
@ -310,14 +317,19 @@ class PlatformEvent : public CHeapObj<mtInternal> {
|
||||||
void park () ;
|
void park () ;
|
||||||
void unpark () ;
|
void unpark () ;
|
||||||
int TryPark () ;
|
int TryPark () ;
|
||||||
int park (jlong millis) ;
|
int park (jlong millis) ; // relative timed-wait only
|
||||||
void SetAssociation (Thread * a) { _Assoc = a ; }
|
void SetAssociation (Thread * a) { _Assoc = a ; }
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
class PlatformParker : public CHeapObj<mtInternal> {
|
class PlatformParker : public CHeapObj<mtInternal> {
|
||||||
protected:
|
protected:
|
||||||
|
enum {
|
||||||
|
REL_INDEX = 0,
|
||||||
|
ABS_INDEX = 1
|
||||||
|
};
|
||||||
|
int _cur_index; // which cond is in use: -1, 0, 1
|
||||||
pthread_mutex_t _mutex [1] ;
|
pthread_mutex_t _mutex [1] ;
|
||||||
pthread_cond_t _cond [1] ;
|
pthread_cond_t _cond [2] ; // one for relative times and one for abs.
|
||||||
|
|
||||||
public: // TODO-FIXME: make dtor private
|
public: // TODO-FIXME: make dtor private
|
||||||
~PlatformParker() { guarantee (0, "invariant") ; }
|
~PlatformParker() { guarantee (0, "invariant") ; }
|
||||||
|
@ -325,10 +337,13 @@ class PlatformParker : public CHeapObj<mtInternal> {
|
||||||
public:
|
public:
|
||||||
PlatformParker() {
|
PlatformParker() {
|
||||||
int status;
|
int status;
|
||||||
status = pthread_cond_init (_cond, NULL);
|
status = pthread_cond_init (&_cond[REL_INDEX], os::Linux::condAttr());
|
||||||
assert_status(status == 0, status, "cond_init");
|
assert_status(status == 0, status, "cond_init rel");
|
||||||
|
status = pthread_cond_init (&_cond[ABS_INDEX], NULL);
|
||||||
|
assert_status(status == 0, status, "cond_init abs");
|
||||||
status = pthread_mutex_init (_mutex, NULL);
|
status = pthread_mutex_init (_mutex, NULL);
|
||||||
assert_status(status == 0, status, "mutex_init");
|
assert_status(status == 0, status, "mutex_init");
|
||||||
|
_cur_index = -1; // mark as unused
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -5178,9 +5178,7 @@ jint os::init_2(void) {
|
||||||
if(Verbose && PrintMiscellaneous)
|
if(Verbose && PrintMiscellaneous)
|
||||||
tty->print("[Memory Serialize Page address: " INTPTR_FORMAT "]\n", (intptr_t)mem_serialize_page);
|
tty->print("[Memory Serialize Page address: " INTPTR_FORMAT "]\n", (intptr_t)mem_serialize_page);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
os::large_page_init();
|
|
||||||
|
|
||||||
// Check minimum allowable stack size for thread creation and to initialize
|
// Check minimum allowable stack size for thread creation and to initialize
|
||||||
// the java system classes, including StackOverflowError - depends on page
|
// the java system classes, including StackOverflowError - depends on page
|
||||||
|
|
|
@ -32,7 +32,11 @@ WindowsDecoder::WindowsDecoder() {
|
||||||
_can_decode_in_vm = false;
|
_can_decode_in_vm = false;
|
||||||
_pfnSymGetSymFromAddr64 = NULL;
|
_pfnSymGetSymFromAddr64 = NULL;
|
||||||
_pfnUndecorateSymbolName = NULL;
|
_pfnUndecorateSymbolName = NULL;
|
||||||
|
#ifdef AMD64
|
||||||
|
_pfnStackWalk64 = NULL;
|
||||||
|
_pfnSymFunctionTableAccess64 = NULL;
|
||||||
|
_pfnSymGetModuleBase64 = NULL;
|
||||||
|
#endif
|
||||||
_decoder_status = no_error;
|
_decoder_status = no_error;
|
||||||
initialize();
|
initialize();
|
||||||
}
|
}
|
||||||
|
@ -53,14 +57,24 @@ void WindowsDecoder::initialize() {
|
||||||
_pfnUndecorateSymbolName = (pfn_UndecorateSymbolName)::GetProcAddress(handle, "UnDecorateSymbolName");
|
_pfnUndecorateSymbolName = (pfn_UndecorateSymbolName)::GetProcAddress(handle, "UnDecorateSymbolName");
|
||||||
|
|
||||||
if (_pfnSymSetOptions == NULL || _pfnSymInitialize == NULL || _pfnSymGetSymFromAddr64 == NULL) {
|
if (_pfnSymSetOptions == NULL || _pfnSymInitialize == NULL || _pfnSymGetSymFromAddr64 == NULL) {
|
||||||
_pfnSymGetSymFromAddr64 = NULL;
|
uninitialize();
|
||||||
_pfnUndecorateSymbolName = NULL;
|
|
||||||
::FreeLibrary(handle);
|
|
||||||
_dbghelp_handle = NULL;
|
|
||||||
_decoder_status = helper_func_error;
|
_decoder_status = helper_func_error;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef AMD64
|
||||||
|
_pfnStackWalk64 = (pfn_StackWalk64)::GetProcAddress(handle, "StackWalk64");
|
||||||
|
_pfnSymFunctionTableAccess64 = (pfn_SymFunctionTableAccess64)::GetProcAddress(handle, "SymFunctionTableAccess64");
|
||||||
|
_pfnSymGetModuleBase64 = (pfn_SymGetModuleBase64)::GetProcAddress(handle, "SymGetModuleBase64");
|
||||||
|
if (_pfnStackWalk64 == NULL || _pfnSymFunctionTableAccess64 == NULL || _pfnSymGetModuleBase64 == NULL) {
|
||||||
|
// We can't call StackWalk64 to walk the stack, but we are still
|
||||||
|
// able to decode the symbols. Let's limp on.
|
||||||
|
_pfnStackWalk64 = NULL;
|
||||||
|
_pfnSymFunctionTableAccess64 = NULL;
|
||||||
|
_pfnSymGetModuleBase64 = NULL;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
HANDLE hProcess = ::GetCurrentProcess();
|
HANDLE hProcess = ::GetCurrentProcess();
|
||||||
_pfnSymSetOptions(SYMOPT_UNDNAME | SYMOPT_DEFERRED_LOADS | SYMOPT_EXACT_SYMBOLS);
|
_pfnSymSetOptions(SYMOPT_UNDNAME | SYMOPT_DEFERRED_LOADS | SYMOPT_EXACT_SYMBOLS);
|
||||||
if (!_pfnSymInitialize(hProcess, NULL, TRUE)) {
|
if (!_pfnSymInitialize(hProcess, NULL, TRUE)) {
|
||||||
|
@ -156,6 +170,11 @@ void WindowsDecoder::initialize() {
|
||||||
void WindowsDecoder::uninitialize() {
|
void WindowsDecoder::uninitialize() {
|
||||||
_pfnSymGetSymFromAddr64 = NULL;
|
_pfnSymGetSymFromAddr64 = NULL;
|
||||||
_pfnUndecorateSymbolName = NULL;
|
_pfnUndecorateSymbolName = NULL;
|
||||||
|
#ifdef AMD64
|
||||||
|
_pfnStackWalk64 = NULL;
|
||||||
|
_pfnSymFunctionTableAccess64 = NULL;
|
||||||
|
_pfnSymGetModuleBase64 = NULL;
|
||||||
|
#endif
|
||||||
if (_dbghelp_handle != NULL) {
|
if (_dbghelp_handle != NULL) {
|
||||||
::FreeLibrary(_dbghelp_handle);
|
::FreeLibrary(_dbghelp_handle);
|
||||||
}
|
}
|
||||||
|
@ -195,3 +214,65 @@ bool WindowsDecoder::demangle(const char* symbol, char *buf, int buflen) {
|
||||||
_pfnUndecorateSymbolName(symbol, buf, buflen, UNDNAME_COMPLETE);
|
_pfnUndecorateSymbolName(symbol, buf, buflen, UNDNAME_COMPLETE);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef AMD64
|
||||||
|
BOOL WindowsDbgHelp::StackWalk64(DWORD MachineType,
|
||||||
|
HANDLE hProcess,
|
||||||
|
HANDLE hThread,
|
||||||
|
LPSTACKFRAME64 StackFrame,
|
||||||
|
PVOID ContextRecord,
|
||||||
|
PREAD_PROCESS_MEMORY_ROUTINE64 ReadMemoryRoutine,
|
||||||
|
PFUNCTION_TABLE_ACCESS_ROUTINE64 FunctionTableAccessRoutine,
|
||||||
|
PGET_MODULE_BASE_ROUTINE64 GetModuleBaseRoutine,
|
||||||
|
PTRANSLATE_ADDRESS_ROUTINE64 TranslateAddress) {
|
||||||
|
DecoderLocker locker;
|
||||||
|
WindowsDecoder* wd = (WindowsDecoder*)locker.decoder();
|
||||||
|
|
||||||
|
if (!wd->has_error() && wd->_pfnStackWalk64) {
|
||||||
|
return wd->_pfnStackWalk64(MachineType,
|
||||||
|
hProcess,
|
||||||
|
hThread,
|
||||||
|
StackFrame,
|
||||||
|
ContextRecord,
|
||||||
|
ReadMemoryRoutine,
|
||||||
|
FunctionTableAccessRoutine,
|
||||||
|
GetModuleBaseRoutine,
|
||||||
|
TranslateAddress);
|
||||||
|
} else {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
PVOID WindowsDbgHelp::SymFunctionTableAccess64(HANDLE hProcess, DWORD64 AddrBase) {
|
||||||
|
DecoderLocker locker;
|
||||||
|
WindowsDecoder* wd = (WindowsDecoder*)locker.decoder();
|
||||||
|
|
||||||
|
if (!wd->has_error() && wd->_pfnSymFunctionTableAccess64) {
|
||||||
|
return wd->_pfnSymFunctionTableAccess64(hProcess, AddrBase);
|
||||||
|
} else {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
pfn_SymFunctionTableAccess64 WindowsDbgHelp::pfnSymFunctionTableAccess64() {
|
||||||
|
DecoderLocker locker;
|
||||||
|
WindowsDecoder* wd = (WindowsDecoder*)locker.decoder();
|
||||||
|
|
||||||
|
if (!wd->has_error()) {
|
||||||
|
return wd->_pfnSymFunctionTableAccess64;
|
||||||
|
} else {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
pfn_SymGetModuleBase64 WindowsDbgHelp::pfnSymGetModuleBase64() {
|
||||||
|
DecoderLocker locker;
|
||||||
|
WindowsDecoder* wd = (WindowsDecoder*)locker.decoder();
|
||||||
|
|
||||||
|
if (!wd->has_error()) {
|
||||||
|
return wd->_pfnSymGetModuleBase64;
|
||||||
|
} else {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif // AMD64
|
||||||
|
|
|
@ -38,6 +38,20 @@ typedef DWORD (WINAPI *pfn_UndecorateSymbolName)(const char*, char*, DWORD, DWOR
|
||||||
typedef BOOL (WINAPI *pfn_SymSetSearchPath)(HANDLE, PCTSTR);
|
typedef BOOL (WINAPI *pfn_SymSetSearchPath)(HANDLE, PCTSTR);
|
||||||
typedef BOOL (WINAPI *pfn_SymGetSearchPath)(HANDLE, PTSTR, int);
|
typedef BOOL (WINAPI *pfn_SymGetSearchPath)(HANDLE, PTSTR, int);
|
||||||
|
|
||||||
|
#ifdef AMD64
|
||||||
|
typedef BOOL (WINAPI *pfn_StackWalk64)(DWORD MachineType,
|
||||||
|
HANDLE hProcess,
|
||||||
|
HANDLE hThread,
|
||||||
|
LPSTACKFRAME64 StackFrame,
|
||||||
|
PVOID ContextRecord,
|
||||||
|
PREAD_PROCESS_MEMORY_ROUTINE64 ReadMemoryRoutine,
|
||||||
|
PFUNCTION_TABLE_ACCESS_ROUTINE64 FunctionTableAccessRoutine,
|
||||||
|
PGET_MODULE_BASE_ROUTINE64 GetModuleBaseRoutine,
|
||||||
|
PTRANSLATE_ADDRESS_ROUTINE64 TranslateAddress);
|
||||||
|
typedef PVOID (WINAPI *pfn_SymFunctionTableAccess64)(HANDLE hProcess, DWORD64 AddrBase);
|
||||||
|
typedef DWORD64 (WINAPI *pfn_SymGetModuleBase64)(HANDLE hProcess, DWORD64 dwAddr);
|
||||||
|
#endif
|
||||||
|
|
||||||
class WindowsDecoder : public AbstractDecoder {
|
class WindowsDecoder : public AbstractDecoder {
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
@ -61,7 +75,34 @@ private:
|
||||||
bool _can_decode_in_vm;
|
bool _can_decode_in_vm;
|
||||||
pfn_SymGetSymFromAddr64 _pfnSymGetSymFromAddr64;
|
pfn_SymGetSymFromAddr64 _pfnSymGetSymFromAddr64;
|
||||||
pfn_UndecorateSymbolName _pfnUndecorateSymbolName;
|
pfn_UndecorateSymbolName _pfnUndecorateSymbolName;
|
||||||
|
#ifdef AMD64
|
||||||
|
pfn_StackWalk64 _pfnStackWalk64;
|
||||||
|
pfn_SymFunctionTableAccess64 _pfnSymFunctionTableAccess64;
|
||||||
|
pfn_SymGetModuleBase64 _pfnSymGetModuleBase64;
|
||||||
|
|
||||||
|
friend class WindowsDbgHelp;
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef AMD64
|
||||||
|
// TODO: refactor and move the handling of dbghelp.dll outside of Decoder
|
||||||
|
class WindowsDbgHelp : public Decoder {
|
||||||
|
public:
|
||||||
|
static BOOL StackWalk64(DWORD MachineType,
|
||||||
|
HANDLE hProcess,
|
||||||
|
HANDLE hThread,
|
||||||
|
LPSTACKFRAME64 StackFrame,
|
||||||
|
PVOID ContextRecord,
|
||||||
|
PREAD_PROCESS_MEMORY_ROUTINE64 ReadMemoryRoutine,
|
||||||
|
PFUNCTION_TABLE_ACCESS_ROUTINE64 FunctionTableAccessRoutine,
|
||||||
|
PGET_MODULE_BASE_ROUTINE64 GetModuleBaseRoutine,
|
||||||
|
PTRANSLATE_ADDRESS_ROUTINE64 TranslateAddress);
|
||||||
|
static PVOID SymFunctionTableAccess64(HANDLE hProcess, DWORD64 AddrBase);
|
||||||
|
|
||||||
|
static pfn_SymFunctionTableAccess64 pfnSymFunctionTableAccess64();
|
||||||
|
static pfn_SymGetModuleBase64 pfnSymGetModuleBase64();
|
||||||
|
};
|
||||||
|
#endif
|
||||||
|
|
||||||
#endif // OS_WINDOWS_VM_DECODER_WINDOWS_HPP
|
#endif // OS_WINDOWS_VM_DECODER_WINDOWS_HPP
|
||||||
|
|
||||||
|
|
|
@ -3189,9 +3189,12 @@ char* os::reserve_memory_special(size_t bytes, size_t alignment, char* addr, boo
|
||||||
return p_buf;
|
return p_buf;
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
if (TracePageSizes && Verbose) {
|
||||||
|
tty->print_cr("Reserving large pages in a single large chunk.");
|
||||||
|
}
|
||||||
// normal policy just allocate it all at once
|
// normal policy just allocate it all at once
|
||||||
DWORD flag = MEM_RESERVE | MEM_COMMIT | MEM_LARGE_PAGES;
|
DWORD flag = MEM_RESERVE | MEM_COMMIT | MEM_LARGE_PAGES;
|
||||||
char * res = (char *)VirtualAlloc(NULL, bytes, flag, prot);
|
char * res = (char *)VirtualAlloc(addr, bytes, flag, prot);
|
||||||
if (res != NULL) {
|
if (res != NULL) {
|
||||||
address pc = CALLER_PC;
|
address pc = CALLER_PC;
|
||||||
MemTracker::record_virtual_memory_reserve_and_commit((address)res, bytes, mtNone, pc);
|
MemTracker::record_virtual_memory_reserve_and_commit((address)res, bytes, mtNone, pc);
|
||||||
|
@ -3917,8 +3920,6 @@ jint os::init_2(void) {
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
os::large_page_init();
|
|
||||||
|
|
||||||
// Setup Windows Exceptions
|
// Setup Windows Exceptions
|
||||||
|
|
||||||
// for debugging float code generation bugs
|
// for debugging float code generation bugs
|
||||||
|
@ -5429,7 +5430,7 @@ char* os::build_agent_function_name(const char *sym_name, const char *lib_name,
|
||||||
if ((start = strrchr(lib_name, *os::file_separator())) != NULL) {
|
if ((start = strrchr(lib_name, *os::file_separator())) != NULL) {
|
||||||
lib_name = ++start;
|
lib_name = ++start;
|
||||||
} else {
|
} else {
|
||||||
// Need to check for C:
|
// Need to check for drive prefix
|
||||||
if ((start = strchr(lib_name, ':')) != NULL) {
|
if ((start = strchr(lib_name, ':')) != NULL) {
|
||||||
lib_name = ++start;
|
lib_name = ++start;
|
||||||
}
|
}
|
||||||
|
@ -5714,7 +5715,66 @@ BOOL os::Advapi32Dll::AdvapiAvailable() {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifndef PRODUCT
|
#ifndef PRODUCT
|
||||||
|
|
||||||
|
// test the code path in reserve_memory_special() that tries to allocate memory in a single
|
||||||
|
// contiguous memory block at a particular address.
|
||||||
|
// The test first tries to find a good approximate address to allocate at by using the same
|
||||||
|
// method to allocate some memory at any address. The test then tries to allocate memory in
|
||||||
|
// the vicinity (not directly after it to avoid possible by-chance use of that location)
|
||||||
|
// This is of course only some dodgy assumption, there is no guarantee that the vicinity of
|
||||||
|
// the previously allocated memory is available for allocation. The only actual failure
|
||||||
|
// that is reported is when the test tries to allocate at a particular location but gets a
|
||||||
|
// different valid one. A NULL return value at this point is not considered an error but may
|
||||||
|
// be legitimate.
|
||||||
|
// If -XX:+VerboseInternalVMTests is enabled, print some explanatory messages.
|
||||||
void TestReserveMemorySpecial_test() {
|
void TestReserveMemorySpecial_test() {
|
||||||
// No tests available for this platform
|
if (!UseLargePages) {
|
||||||
|
if (VerboseInternalVMTests) {
|
||||||
|
gclog_or_tty->print("Skipping test because large pages are disabled");
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// save current value of globals
|
||||||
|
bool old_use_large_pages_individual_allocation = UseLargePagesIndividualAllocation;
|
||||||
|
bool old_use_numa_interleaving = UseNUMAInterleaving;
|
||||||
|
|
||||||
|
// set globals to make sure we hit the correct code path
|
||||||
|
UseLargePagesIndividualAllocation = UseNUMAInterleaving = false;
|
||||||
|
|
||||||
|
// do an allocation at an address selected by the OS to get a good one.
|
||||||
|
const size_t large_allocation_size = os::large_page_size() * 4;
|
||||||
|
char* result = os::reserve_memory_special(large_allocation_size, os::large_page_size(), NULL, false);
|
||||||
|
if (result == NULL) {
|
||||||
|
if (VerboseInternalVMTests) {
|
||||||
|
gclog_or_tty->print("Failed to allocate control block with size "SIZE_FORMAT". Skipping remainder of test.",
|
||||||
|
large_allocation_size);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
os::release_memory_special(result, large_allocation_size);
|
||||||
|
|
||||||
|
// allocate another page within the recently allocated memory area which seems to be a good location. At least
|
||||||
|
// we managed to get it once.
|
||||||
|
const size_t expected_allocation_size = os::large_page_size();
|
||||||
|
char* expected_location = result + os::large_page_size();
|
||||||
|
char* actual_location = os::reserve_memory_special(expected_allocation_size, os::large_page_size(), expected_location, false);
|
||||||
|
if (actual_location == NULL) {
|
||||||
|
if (VerboseInternalVMTests) {
|
||||||
|
gclog_or_tty->print("Failed to allocate any memory at "PTR_FORMAT" size "SIZE_FORMAT". Skipping remainder of test.",
|
||||||
|
expected_location, large_allocation_size);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
// release memory
|
||||||
|
os::release_memory_special(actual_location, expected_allocation_size);
|
||||||
|
// only now check, after releasing any memory to avoid any leaks.
|
||||||
|
assert(actual_location == expected_location,
|
||||||
|
err_msg("Failed to allocate memory at requested location "PTR_FORMAT" of size "SIZE_FORMAT", is "PTR_FORMAT" instead",
|
||||||
|
expected_location, expected_allocation_size, actual_location));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// restore globals
|
||||||
|
UseLargePagesIndividualAllocation = old_use_large_pages_individual_allocation;
|
||||||
|
UseNUMAInterleaving = old_use_numa_interleaving;
|
||||||
}
|
}
|
||||||
#endif
|
#endif // PRODUCT
|
||||||
|
|
||||||
|
|
|
@ -876,3 +876,46 @@ void os::verify_stack_alignment() {
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
* IA32 only: execute code at a high address in case buggy NX emulation is present. I.e. avoid CS limit
|
||||||
|
* updates (JDK-8023956).
|
||||||
|
*/
|
||||||
|
void os::workaround_expand_exec_shield_cs_limit() {
|
||||||
|
#if defined(IA32)
|
||||||
|
size_t page_size = os::vm_page_size();
|
||||||
|
/*
|
||||||
|
* Take the highest VA the OS will give us and exec
|
||||||
|
*
|
||||||
|
* Although using -(pagesz) as mmap hint works on newer kernel as you would
|
||||||
|
* think, older variants affected by this work-around don't (search forward only).
|
||||||
|
*
|
||||||
|
* On the affected distributions, we understand the memory layout to be:
|
||||||
|
*
|
||||||
|
* TASK_LIMIT= 3G, main stack base close to TASK_LIMT.
|
||||||
|
*
|
||||||
|
* A few pages south main stack will do it.
|
||||||
|
*
|
||||||
|
* If we are embedded in an app other than launcher (initial != main stack),
|
||||||
|
* we don't have much control or understanding of the address space, just let it slide.
|
||||||
|
*/
|
||||||
|
char* hint = (char*) (Linux::initial_thread_stack_bottom() -
|
||||||
|
((StackYellowPages + StackRedPages + 1) * page_size));
|
||||||
|
char* codebuf = os::reserve_memory(page_size, hint);
|
||||||
|
if ( (codebuf == NULL) || (!os::commit_memory(codebuf, page_size, true)) ) {
|
||||||
|
return; // No matter, we tried, best effort.
|
||||||
|
}
|
||||||
|
if (PrintMiscellaneous && (Verbose || WizardMode)) {
|
||||||
|
tty->print_cr("[CS limit NX emulation work-around, exec code at: %p]", codebuf);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Some code to exec: the 'ret' instruction
|
||||||
|
codebuf[0] = 0xC3;
|
||||||
|
|
||||||
|
// Call the code in the codebuf
|
||||||
|
__asm__ volatile("call *%0" : : "r"(codebuf));
|
||||||
|
|
||||||
|
// keep the page mapped so CS limit isn't reduced.
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
|
@ -36,4 +36,17 @@
|
||||||
// Note: Currently only used in 64 bit Windows implementations
|
// Note: Currently only used in 64 bit Windows implementations
|
||||||
static bool register_code_area(char *low, char *high) { return true; }
|
static bool register_code_area(char *low, char *high) { return true; }
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Work-around for broken NX emulation using CS limit, Red Hat patch "Exec-Shield"
|
||||||
|
* (IA32 only).
|
||||||
|
*
|
||||||
|
* Map and execute at a high VA to prevent CS lazy updates race with SMP MM
|
||||||
|
* invalidation.Further code generation by the JVM will no longer cause CS limit
|
||||||
|
* updates.
|
||||||
|
*
|
||||||
|
* Affects IA32: RHEL 5 & 6, Ubuntu 10.04 (LTS), 10.10, 11.04, 11.10, 12.04.
|
||||||
|
* @see JDK-8023956
|
||||||
|
*/
|
||||||
|
static void workaround_expand_exec_shield_cs_limit();
|
||||||
|
|
||||||
#endif // OS_CPU_LINUX_X86_VM_OS_LINUX_X86_HPP
|
#endif // OS_CPU_LINUX_X86_VM_OS_LINUX_X86_HPP
|
||||||
|
|
|
@ -35,7 +35,9 @@ define_pd_global(intx, CompilerThreadStackSize, 0);
|
||||||
|
|
||||||
// Used on 64 bit platforms for UseCompressedOops base address
|
// Used on 64 bit platforms for UseCompressedOops base address
|
||||||
#ifdef _LP64
|
#ifdef _LP64
|
||||||
define_pd_global(uintx, HeapBaseMinAddress, CONST64(4)*G);
|
// use 6G as default base address because by default the OS maps the application
|
||||||
|
// to 4G on Solaris-Sparc. This leaves at least 2G for the native heap.
|
||||||
|
define_pd_global(uintx, HeapBaseMinAddress, CONST64(6)*G);
|
||||||
#else
|
#else
|
||||||
define_pd_global(uintx, HeapBaseMinAddress, 2*G);
|
define_pd_global(uintx, HeapBaseMinAddress, 2*G);
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -29,6 +29,7 @@
|
||||||
#include "classfile/vmSymbols.hpp"
|
#include "classfile/vmSymbols.hpp"
|
||||||
#include "code/icBuffer.hpp"
|
#include "code/icBuffer.hpp"
|
||||||
#include "code/vtableStubs.hpp"
|
#include "code/vtableStubs.hpp"
|
||||||
|
#include "decoder_windows.hpp"
|
||||||
#include "interpreter/interpreter.hpp"
|
#include "interpreter/interpreter.hpp"
|
||||||
#include "jvm_windows.h"
|
#include "jvm_windows.h"
|
||||||
#include "memory/allocation.inline.hpp"
|
#include "memory/allocation.inline.hpp"
|
||||||
|
@ -327,6 +328,94 @@ add_ptr_func_t* os::atomic_add_ptr_func = os::atomic_add_ptr_bootstrap
|
||||||
|
|
||||||
cmpxchg_long_func_t* os::atomic_cmpxchg_long_func = os::atomic_cmpxchg_long_bootstrap;
|
cmpxchg_long_func_t* os::atomic_cmpxchg_long_func = os::atomic_cmpxchg_long_bootstrap;
|
||||||
|
|
||||||
|
#ifdef AMD64
|
||||||
|
/*
|
||||||
|
* Windows/x64 does not use stack frames the way expected by Java:
|
||||||
|
* [1] in most cases, there is no frame pointer. All locals are addressed via RSP
|
||||||
|
* [2] in rare cases, when alloca() is used, a frame pointer is used, but this may
|
||||||
|
* not be RBP.
|
||||||
|
* See http://msdn.microsoft.com/en-us/library/ew5tede7.aspx
|
||||||
|
*
|
||||||
|
* So it's not possible to print the native stack using the
|
||||||
|
* while (...) {... fr = os::get_sender_for_C_frame(&fr); }
|
||||||
|
* loop in vmError.cpp. We need to roll our own loop.
|
||||||
|
*/
|
||||||
|
bool os::platform_print_native_stack(outputStream* st, void* context,
|
||||||
|
char *buf, int buf_size)
|
||||||
|
{
|
||||||
|
CONTEXT ctx;
|
||||||
|
if (context != NULL) {
|
||||||
|
memcpy(&ctx, context, sizeof(ctx));
|
||||||
|
} else {
|
||||||
|
RtlCaptureContext(&ctx);
|
||||||
|
}
|
||||||
|
|
||||||
|
st->print_cr("Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)");
|
||||||
|
|
||||||
|
STACKFRAME stk;
|
||||||
|
memset(&stk, 0, sizeof(stk));
|
||||||
|
stk.AddrStack.Offset = ctx.Rsp;
|
||||||
|
stk.AddrStack.Mode = AddrModeFlat;
|
||||||
|
stk.AddrFrame.Offset = ctx.Rbp;
|
||||||
|
stk.AddrFrame.Mode = AddrModeFlat;
|
||||||
|
stk.AddrPC.Offset = ctx.Rip;
|
||||||
|
stk.AddrPC.Mode = AddrModeFlat;
|
||||||
|
|
||||||
|
int count = 0;
|
||||||
|
address lastpc = 0;
|
||||||
|
while (count++ < StackPrintLimit) {
|
||||||
|
intptr_t* sp = (intptr_t*)stk.AddrStack.Offset;
|
||||||
|
intptr_t* fp = (intptr_t*)stk.AddrFrame.Offset; // NOT necessarily the same as ctx.Rbp!
|
||||||
|
address pc = (address)stk.AddrPC.Offset;
|
||||||
|
|
||||||
|
if (pc != NULL && sp != NULL && fp != NULL) {
|
||||||
|
if (count == 2 && lastpc == pc) {
|
||||||
|
// Skip it -- StackWalk64() may return the same PC
|
||||||
|
// (but different SP) on the first try.
|
||||||
|
} else {
|
||||||
|
// Don't try to create a frame(sp, fp, pc) -- on WinX64, stk.AddrFrame
|
||||||
|
// may not contain what Java expects, and may cause the frame() constructor
|
||||||
|
// to crash. Let's just print out the symbolic address.
|
||||||
|
frame::print_C_frame(st, buf, buf_size, pc);
|
||||||
|
st->cr();
|
||||||
|
}
|
||||||
|
lastpc = pc;
|
||||||
|
} else {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
PVOID p = WindowsDbgHelp::SymFunctionTableAccess64(GetCurrentProcess(), stk.AddrPC.Offset);
|
||||||
|
if (!p) {
|
||||||
|
// StackWalk64() can't handle this PC. Calling StackWalk64 again may cause crash.
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
BOOL result = WindowsDbgHelp::StackWalk64(
|
||||||
|
IMAGE_FILE_MACHINE_AMD64, // __in DWORD MachineType,
|
||||||
|
GetCurrentProcess(), // __in HANDLE hProcess,
|
||||||
|
GetCurrentThread(), // __in HANDLE hThread,
|
||||||
|
&stk, // __inout LP STACKFRAME64 StackFrame,
|
||||||
|
&ctx, // __inout PVOID ContextRecord,
|
||||||
|
NULL, // __in_opt PREAD_PROCESS_MEMORY_ROUTINE64 ReadMemoryRoutine,
|
||||||
|
WindowsDbgHelp::pfnSymFunctionTableAccess64(),
|
||||||
|
// __in_opt PFUNCTION_TABLE_ACCESS_ROUTINE64 FunctionTableAccessRoutine,
|
||||||
|
WindowsDbgHelp::pfnSymGetModuleBase64(),
|
||||||
|
// __in_opt PGET_MODULE_BASE_ROUTINE64 GetModuleBaseRoutine,
|
||||||
|
NULL); // __in_opt PTRANSLATE_ADDRESS_ROUTINE64 TranslateAddress
|
||||||
|
|
||||||
|
if (!result) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (count > StackPrintLimit) {
|
||||||
|
st->print_cr("...<more frames>...");
|
||||||
|
}
|
||||||
|
st->cr();
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
#endif // AMD64
|
||||||
|
|
||||||
ExtendedPC os::fetch_frame_from_context(void* ucVoid,
|
ExtendedPC os::fetch_frame_from_context(void* ucVoid,
|
||||||
intptr_t** ret_sp, intptr_t** ret_fp) {
|
intptr_t** ret_sp, intptr_t** ret_fp) {
|
||||||
|
|
||||||
|
@ -401,6 +490,9 @@ frame os::current_frame() {
|
||||||
StubRoutines::x86::get_previous_fp_entry());
|
StubRoutines::x86::get_previous_fp_entry());
|
||||||
if (func == NULL) return frame();
|
if (func == NULL) return frame();
|
||||||
intptr_t* fp = (*func)();
|
intptr_t* fp = (*func)();
|
||||||
|
if (fp == NULL) {
|
||||||
|
return frame();
|
||||||
|
}
|
||||||
#else
|
#else
|
||||||
intptr_t* fp = _get_previous_fp();
|
intptr_t* fp = _get_previous_fp();
|
||||||
#endif // AMD64
|
#endif // AMD64
|
||||||
|
|
|
@ -62,4 +62,10 @@
|
||||||
|
|
||||||
static bool register_code_area(char *low, char *high);
|
static bool register_code_area(char *low, char *high);
|
||||||
|
|
||||||
|
#ifdef AMD64
|
||||||
|
#define PLATFORM_PRINT_NATIVE_STACK 1
|
||||||
|
static bool platform_print_native_stack(outputStream* st, void* context,
|
||||||
|
char *buf, int buf_size);
|
||||||
|
#endif
|
||||||
|
|
||||||
#endif // OS_CPU_WINDOWS_X86_VM_OS_WINDOWS_X86_HPP
|
#endif // OS_CPU_WINDOWS_X86_VM_OS_WINDOWS_X86_HPP
|
||||||
|
|
|
@ -4,14 +4,14 @@ It's main purpose is to recreate output similar to
|
||||||
requires a 1.5 JDK to build and simply typing make should build it.
|
requires a 1.5 JDK to build and simply typing make should build it.
|
||||||
|
|
||||||
It produces a jar file, logc.jar, that can be run on the
|
It produces a jar file, logc.jar, that can be run on the
|
||||||
hotspot.log from LogCompilation output like this:
|
HotSpot log (by default, hotspot_pid{pid}.log) from LogCompilation output like this:
|
||||||
|
|
||||||
java -jar logc.jar hotspot.log
|
java -jar logc.jar hotspot_pid1234.log
|
||||||
|
|
||||||
This will produce something like the normal PrintCompilation output.
|
This will produce something like the normal PrintCompilation output.
|
||||||
Adding the -i option with also report inlining like PrintInlining.
|
Adding the -i option with also report inlining like PrintInlining.
|
||||||
|
|
||||||
More information about the LogCompilation output can be found at
|
More information about the LogCompilation output can be found at
|
||||||
|
|
||||||
https://wikis.oracle.com/display/HotSpotInternals/LogCompilation+overview
|
https://wikis.oracle.com/display/HotSpotInternals/LogCompilation+overview
|
||||||
https://wikis.oracle.com/display/HotSpotInternals/PrintCompilation
|
https://wikis.oracle.com/display/HotSpotInternals/PrintCompilation
|
||||||
|
|
|
@ -3395,12 +3395,16 @@ Interface *ADLParser::cond_interface_parse(void) {
|
||||||
char *greater_equal;
|
char *greater_equal;
|
||||||
char *less_equal;
|
char *less_equal;
|
||||||
char *greater;
|
char *greater;
|
||||||
|
char *overflow;
|
||||||
|
char *no_overflow;
|
||||||
const char *equal_format = "eq";
|
const char *equal_format = "eq";
|
||||||
const char *not_equal_format = "ne";
|
const char *not_equal_format = "ne";
|
||||||
const char *less_format = "lt";
|
const char *less_format = "lt";
|
||||||
const char *greater_equal_format = "ge";
|
const char *greater_equal_format = "ge";
|
||||||
const char *less_equal_format = "le";
|
const char *less_equal_format = "le";
|
||||||
const char *greater_format = "gt";
|
const char *greater_format = "gt";
|
||||||
|
const char *overflow_format = "o";
|
||||||
|
const char *no_overflow_format = "no";
|
||||||
|
|
||||||
if (_curchar != '%') {
|
if (_curchar != '%') {
|
||||||
parse_err(SYNERR, "Missing '%%{' for 'cond_interface' block.\n");
|
parse_err(SYNERR, "Missing '%%{' for 'cond_interface' block.\n");
|
||||||
|
@ -3437,6 +3441,12 @@ Interface *ADLParser::cond_interface_parse(void) {
|
||||||
else if ( strcmp(field,"greater") == 0 ) {
|
else if ( strcmp(field,"greater") == 0 ) {
|
||||||
greater = interface_field_parse(&greater_format);
|
greater = interface_field_parse(&greater_format);
|
||||||
}
|
}
|
||||||
|
else if ( strcmp(field,"overflow") == 0 ) {
|
||||||
|
overflow = interface_field_parse(&overflow_format);
|
||||||
|
}
|
||||||
|
else if ( strcmp(field,"no_overflow") == 0 ) {
|
||||||
|
no_overflow = interface_field_parse(&no_overflow_format);
|
||||||
|
}
|
||||||
else {
|
else {
|
||||||
parse_err(SYNERR, "Expected keyword, base|index|scale|disp, or '%%}' ending interface.\n");
|
parse_err(SYNERR, "Expected keyword, base|index|scale|disp, or '%%}' ending interface.\n");
|
||||||
return NULL;
|
return NULL;
|
||||||
|
@ -3455,7 +3465,9 @@ Interface *ADLParser::cond_interface_parse(void) {
|
||||||
less, less_format,
|
less, less_format,
|
||||||
greater_equal, greater_equal_format,
|
greater_equal, greater_equal_format,
|
||||||
less_equal, less_equal_format,
|
less_equal, less_equal_format,
|
||||||
greater, greater_format);
|
greater, greater_format,
|
||||||
|
overflow, overflow_format,
|
||||||
|
no_overflow, no_overflow_format);
|
||||||
return inter;
|
return inter;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1192,6 +1192,8 @@ void ArchDesc::buildMustCloneMap(FILE *fp_hpp, FILE *fp_cpp) {
|
||||||
|| strcmp(idealName,"CmpF") == 0
|
|| strcmp(idealName,"CmpF") == 0
|
||||||
|| strcmp(idealName,"FastLock") == 0
|
|| strcmp(idealName,"FastLock") == 0
|
||||||
|| strcmp(idealName,"FastUnlock") == 0
|
|| strcmp(idealName,"FastUnlock") == 0
|
||||||
|
|| strcmp(idealName,"AddExactI") == 0
|
||||||
|
|| strcmp(idealName,"FlagsProj") == 0
|
||||||
|| strcmp(idealName,"Bool") == 0
|
|| strcmp(idealName,"Bool") == 0
|
||||||
|| strcmp(idealName,"Binary") == 0 ) {
|
|| strcmp(idealName,"Binary") == 0 ) {
|
||||||
// Removed ConI from the must_clone list. CPUs that cannot use
|
// Removed ConI from the must_clone list. CPUs that cannot use
|
||||||
|
|
|
@ -2757,14 +2757,18 @@ CondInterface::CondInterface(const char* equal, const char* equal_format
|
||||||
const char* less, const char* less_format,
|
const char* less, const char* less_format,
|
||||||
const char* greater_equal, const char* greater_equal_format,
|
const char* greater_equal, const char* greater_equal_format,
|
||||||
const char* less_equal, const char* less_equal_format,
|
const char* less_equal, const char* less_equal_format,
|
||||||
const char* greater, const char* greater_format)
|
const char* greater, const char* greater_format,
|
||||||
|
const char* overflow, const char* overflow_format,
|
||||||
|
const char* no_overflow, const char* no_overflow_format)
|
||||||
: Interface("COND_INTER"),
|
: Interface("COND_INTER"),
|
||||||
_equal(equal), _equal_format(equal_format),
|
_equal(equal), _equal_format(equal_format),
|
||||||
_not_equal(not_equal), _not_equal_format(not_equal_format),
|
_not_equal(not_equal), _not_equal_format(not_equal_format),
|
||||||
_less(less), _less_format(less_format),
|
_less(less), _less_format(less_format),
|
||||||
_greater_equal(greater_equal), _greater_equal_format(greater_equal_format),
|
_greater_equal(greater_equal), _greater_equal_format(greater_equal_format),
|
||||||
_less_equal(less_equal), _less_equal_format(less_equal_format),
|
_less_equal(less_equal), _less_equal_format(less_equal_format),
|
||||||
_greater(greater), _greater_format(greater_format) {
|
_greater(greater), _greater_format(greater_format),
|
||||||
|
_overflow(overflow), _overflow_format(overflow_format),
|
||||||
|
_no_overflow(no_overflow), _no_overflow_format(no_overflow_format) {
|
||||||
}
|
}
|
||||||
CondInterface::~CondInterface() {
|
CondInterface::~CondInterface() {
|
||||||
// not owner of any character arrays
|
// not owner of any character arrays
|
||||||
|
@ -2777,12 +2781,14 @@ void CondInterface::dump() {
|
||||||
// Write info to output files
|
// Write info to output files
|
||||||
void CondInterface::output(FILE *fp) {
|
void CondInterface::output(FILE *fp) {
|
||||||
Interface::output(fp);
|
Interface::output(fp);
|
||||||
if ( _equal != NULL ) fprintf(fp," equal == %s\n", _equal);
|
if ( _equal != NULL ) fprintf(fp," equal == %s\n", _equal);
|
||||||
if ( _not_equal != NULL ) fprintf(fp," not_equal == %s\n", _not_equal);
|
if ( _not_equal != NULL ) fprintf(fp," not_equal == %s\n", _not_equal);
|
||||||
if ( _less != NULL ) fprintf(fp," less == %s\n", _less);
|
if ( _less != NULL ) fprintf(fp," less == %s\n", _less);
|
||||||
if ( _greater_equal != NULL ) fprintf(fp," greater_equal == %s\n", _greater_equal);
|
if ( _greater_equal != NULL ) fprintf(fp," greater_equal == %s\n", _greater_equal);
|
||||||
if ( _less_equal != NULL ) fprintf(fp," less_equal == %s\n", _less_equal);
|
if ( _less_equal != NULL ) fprintf(fp," less_equal == %s\n", _less_equal);
|
||||||
if ( _greater != NULL ) fprintf(fp," greater == %s\n", _greater);
|
if ( _greater != NULL ) fprintf(fp," greater == %s\n", _greater);
|
||||||
|
if ( _overflow != NULL ) fprintf(fp," overflow == %s\n", _overflow);
|
||||||
|
if ( _no_overflow != NULL ) fprintf(fp," no_overflow == %s\n", _no_overflow);
|
||||||
// fprintf(fp,"\n");
|
// fprintf(fp,"\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -798,12 +798,16 @@ public:
|
||||||
const char *_greater_equal;
|
const char *_greater_equal;
|
||||||
const char *_less_equal;
|
const char *_less_equal;
|
||||||
const char *_greater;
|
const char *_greater;
|
||||||
|
const char *_overflow;
|
||||||
|
const char *_no_overflow;
|
||||||
const char *_equal_format;
|
const char *_equal_format;
|
||||||
const char *_not_equal_format;
|
const char *_not_equal_format;
|
||||||
const char *_less_format;
|
const char *_less_format;
|
||||||
const char *_greater_equal_format;
|
const char *_greater_equal_format;
|
||||||
const char *_less_equal_format;
|
const char *_less_equal_format;
|
||||||
const char *_greater_format;
|
const char *_greater_format;
|
||||||
|
const char *_overflow_format;
|
||||||
|
const char *_no_overflow_format;
|
||||||
|
|
||||||
// Public Methods
|
// Public Methods
|
||||||
CondInterface(const char* equal, const char* equal_format,
|
CondInterface(const char* equal, const char* equal_format,
|
||||||
|
@ -811,7 +815,9 @@ public:
|
||||||
const char* less, const char* less_format,
|
const char* less, const char* less_format,
|
||||||
const char* greater_equal, const char* greater_equal_format,
|
const char* greater_equal, const char* greater_equal_format,
|
||||||
const char* less_equal, const char* less_equal_format,
|
const char* less_equal, const char* less_equal_format,
|
||||||
const char* greater, const char* greater_format);
|
const char* greater, const char* greater_format,
|
||||||
|
const char* overflow, const char* overflow_format,
|
||||||
|
const char* no_overflow, const char* no_overflow_format);
|
||||||
~CondInterface();
|
~CondInterface();
|
||||||
|
|
||||||
void dump();
|
void dump();
|
||||||
|
|
|
@ -388,6 +388,8 @@ static void defineCCodeDump(OperandForm* oper, FILE *fp, int i) {
|
||||||
fprintf(fp, " else if( _c%d == BoolTest::ge ) st->print(\"%s\");\n",i,cond->_greater_equal_format);
|
fprintf(fp, " else if( _c%d == BoolTest::ge ) st->print(\"%s\");\n",i,cond->_greater_equal_format);
|
||||||
fprintf(fp, " else if( _c%d == BoolTest::lt ) st->print(\"%s\");\n",i,cond->_less_format);
|
fprintf(fp, " else if( _c%d == BoolTest::lt ) st->print(\"%s\");\n",i,cond->_less_format);
|
||||||
fprintf(fp, " else if( _c%d == BoolTest::gt ) st->print(\"%s\");\n",i,cond->_greater_format);
|
fprintf(fp, " else if( _c%d == BoolTest::gt ) st->print(\"%s\");\n",i,cond->_greater_format);
|
||||||
|
fprintf(fp, " else if( _c%d == BoolTest::overflow ) st->print(\"%s\");\n",i,cond->_overflow_format);
|
||||||
|
fprintf(fp, " else if( _c%d == BoolTest::no_overflow ) st->print(\"%s\");\n",i,cond->_no_overflow_format);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Output code that dumps constant values, increment "i" if type is constant
|
// Output code that dumps constant values, increment "i" if type is constant
|
||||||
|
@ -1208,6 +1210,8 @@ void ArchDesc::declareClasses(FILE *fp) {
|
||||||
fprintf(fp," case BoolTest::ne : return not_equal();\n");
|
fprintf(fp," case BoolTest::ne : return not_equal();\n");
|
||||||
fprintf(fp," case BoolTest::le : return less_equal();\n");
|
fprintf(fp," case BoolTest::le : return less_equal();\n");
|
||||||
fprintf(fp," case BoolTest::ge : return greater_equal();\n");
|
fprintf(fp," case BoolTest::ge : return greater_equal();\n");
|
||||||
|
fprintf(fp," case BoolTest::overflow : return overflow();\n");
|
||||||
|
fprintf(fp," case BoolTest::no_overflow: return no_overflow();\n");
|
||||||
fprintf(fp," default : ShouldNotReachHere(); return 0;\n");
|
fprintf(fp," default : ShouldNotReachHere(); return 0;\n");
|
||||||
fprintf(fp," }\n");
|
fprintf(fp," }\n");
|
||||||
fprintf(fp," };\n");
|
fprintf(fp," };\n");
|
||||||
|
@ -1373,6 +1377,14 @@ void ArchDesc::declareClasses(FILE *fp) {
|
||||||
if( greater != NULL ) {
|
if( greater != NULL ) {
|
||||||
define_oper_interface(fp, *oper, _globalNames, "greater", greater);
|
define_oper_interface(fp, *oper, _globalNames, "greater", greater);
|
||||||
}
|
}
|
||||||
|
const char *overflow = cInterface->_overflow;
|
||||||
|
if( overflow != NULL ) {
|
||||||
|
define_oper_interface(fp, *oper, _globalNames, "overflow", overflow);
|
||||||
|
}
|
||||||
|
const char *no_overflow = cInterface->_no_overflow;
|
||||||
|
if( no_overflow != NULL ) {
|
||||||
|
define_oper_interface(fp, *oper, _globalNames, "no_overflow", no_overflow);
|
||||||
|
}
|
||||||
} // end Conditional Interface
|
} // end Conditional Interface
|
||||||
// Check if it is a Constant Interface
|
// Check if it is a Constant Interface
|
||||||
else if (oper->_interface->is_ConstInterface() != NULL ) {
|
else if (oper->_interface->is_ConstInterface() != NULL ) {
|
||||||
|
|
|
@ -4219,7 +4219,9 @@ void GraphBuilder::print_inlining(ciMethod* callee, const char* msg, bool succes
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!PrintInlining) return;
|
if (!PrintInlining && !compilation()->method()->has_option("PrintInlining")) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
CompileTask::print_inlining(callee, scope()->level(), bci(), msg);
|
CompileTask::print_inlining(callee, scope()->level(), bci(), msg);
|
||||||
if (success && CIPrintMethodCodes) {
|
if (success && CIPrintMethodCodes) {
|
||||||
callee->print_codes();
|
callee->print_codes();
|
||||||
|
|
|
@ -709,10 +709,10 @@ static Klass* resolve_field_return_klass(methodHandle caller, int bci, TRAPS) {
|
||||||
Bytecodes::Code code = field_access.code();
|
Bytecodes::Code code = field_access.code();
|
||||||
|
|
||||||
// We must load class, initialize class and resolvethe field
|
// We must load class, initialize class and resolvethe field
|
||||||
FieldAccessInfo result; // initialize class if needed
|
fieldDescriptor result; // initialize class if needed
|
||||||
constantPoolHandle constants(THREAD, caller->constants());
|
constantPoolHandle constants(THREAD, caller->constants());
|
||||||
LinkResolver::resolve_field(result, constants, field_access.index(), Bytecodes::java_code(code), false, CHECK_NULL);
|
LinkResolver::resolve_field_access(result, constants, field_access.index(), Bytecodes::java_code(code), CHECK_NULL);
|
||||||
return result.klass()();
|
return result.field_holder();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -826,11 +826,11 @@ JRT_ENTRY(void, Runtime1::patch_code(JavaThread* thread, Runtime1::StubID stub_i
|
||||||
if (stub_id == Runtime1::access_field_patching_id) {
|
if (stub_id == Runtime1::access_field_patching_id) {
|
||||||
|
|
||||||
Bytecode_field field_access(caller_method, bci);
|
Bytecode_field field_access(caller_method, bci);
|
||||||
FieldAccessInfo result; // initialize class if needed
|
fieldDescriptor result; // initialize class if needed
|
||||||
Bytecodes::Code code = field_access.code();
|
Bytecodes::Code code = field_access.code();
|
||||||
constantPoolHandle constants(THREAD, caller_method->constants());
|
constantPoolHandle constants(THREAD, caller_method->constants());
|
||||||
LinkResolver::resolve_field(result, constants, field_access.index(), Bytecodes::java_code(code), false, CHECK);
|
LinkResolver::resolve_field_access(result, constants, field_access.index(), Bytecodes::java_code(code), CHECK);
|
||||||
patch_field_offset = result.field_offset();
|
patch_field_offset = result.offset();
|
||||||
|
|
||||||
// If we're patching a field which is volatile then at compile it
|
// If we're patching a field which is volatile then at compile it
|
||||||
// must not have been know to be volatile, so the generated code
|
// must not have been know to be volatile, so the generated code
|
||||||
|
@ -1019,7 +1019,7 @@ JRT_ENTRY(void, Runtime1::patch_code(JavaThread* thread, Runtime1::StubID stub_i
|
||||||
n_copy->set_data((intx) (load_klass()));
|
n_copy->set_data((intx) (load_klass()));
|
||||||
} else {
|
} else {
|
||||||
assert(mirror() != NULL, "klass not set");
|
assert(mirror() != NULL, "klass not set");
|
||||||
n_copy->set_data((intx) (mirror()));
|
n_copy->set_data(cast_from_oop<intx>(mirror()));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (TracePatching) {
|
if (TracePatching) {
|
||||||
|
@ -1031,7 +1031,7 @@ JRT_ENTRY(void, Runtime1::patch_code(JavaThread* thread, Runtime1::StubID stub_i
|
||||||
assert(n_copy->data() == 0 ||
|
assert(n_copy->data() == 0 ||
|
||||||
n_copy->data() == (intptr_t)Universe::non_oop_word(),
|
n_copy->data() == (intptr_t)Universe::non_oop_word(),
|
||||||
"illegal init value");
|
"illegal init value");
|
||||||
n_copy->set_data((intx) (appendix()));
|
n_copy->set_data(cast_from_oop<intx>(appendix()));
|
||||||
|
|
||||||
if (TracePatching) {
|
if (TracePatching) {
|
||||||
Disassembler::decode(copy_buff, copy_buff + *byte_count, tty);
|
Disassembler::decode(copy_buff, copy_buff + *byte_count, tty);
|
||||||
|
@ -1078,14 +1078,17 @@ JRT_ENTRY(void, Runtime1::patch_code(JavaThread* thread, Runtime1::StubID stub_i
|
||||||
// replace instructions
|
// replace instructions
|
||||||
// first replace the tail, then the call
|
// first replace the tail, then the call
|
||||||
#ifdef ARM
|
#ifdef ARM
|
||||||
if(load_klass_or_mirror_patch_id && !VM_Version::supports_movw()) {
|
if((load_klass_or_mirror_patch_id ||
|
||||||
|
stub_id == Runtime1::load_appendix_patching_id) &&
|
||||||
|
!VM_Version::supports_movw()) {
|
||||||
nmethod* nm = CodeCache::find_nmethod(instr_pc);
|
nmethod* nm = CodeCache::find_nmethod(instr_pc);
|
||||||
address addr = NULL;
|
address addr = NULL;
|
||||||
assert(nm != NULL, "invalid nmethod_pc");
|
assert(nm != NULL, "invalid nmethod_pc");
|
||||||
RelocIterator mds(nm, copy_buff, copy_buff + 1);
|
RelocIterator mds(nm, copy_buff, copy_buff + 1);
|
||||||
while (mds.next()) {
|
while (mds.next()) {
|
||||||
if (mds.type() == relocInfo::oop_type) {
|
if (mds.type() == relocInfo::oop_type) {
|
||||||
assert(stub_id == Runtime1::load_mirror_patching_id, "wrong stub id");
|
assert(stub_id == Runtime1::load_mirror_patching_id ||
|
||||||
|
stub_id == Runtime1::load_appendix_patching_id, "wrong stub id");
|
||||||
oop_Relocation* r = mds.oop_reloc();
|
oop_Relocation* r = mds.oop_reloc();
|
||||||
addr = (address)r->oop_addr();
|
addr = (address)r->oop_addr();
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -24,13 +24,92 @@
|
||||||
|
|
||||||
#include "precompiled.hpp"
|
#include "precompiled.hpp"
|
||||||
#include "ci/ciArray.hpp"
|
#include "ci/ciArray.hpp"
|
||||||
|
#include "ci/ciArrayKlass.hpp"
|
||||||
|
#include "ci/ciConstant.hpp"
|
||||||
#include "ci/ciKlass.hpp"
|
#include "ci/ciKlass.hpp"
|
||||||
#include "ci/ciUtilities.hpp"
|
#include "ci/ciUtilities.hpp"
|
||||||
|
#include "oops/objArrayOop.hpp"
|
||||||
|
#include "oops/typeArrayOop.hpp"
|
||||||
|
|
||||||
// ciArray
|
// ciArray
|
||||||
//
|
//
|
||||||
// This class represents an arrayOop in the HotSpot virtual
|
// This class represents an arrayOop in the HotSpot virtual
|
||||||
// machine.
|
// machine.
|
||||||
|
static BasicType fixup_element_type(BasicType bt) {
|
||||||
|
if (bt == T_ARRAY) return T_OBJECT;
|
||||||
|
if (bt == T_BOOLEAN) return T_BYTE;
|
||||||
|
return bt;
|
||||||
|
}
|
||||||
|
|
||||||
|
ciConstant ciArray::element_value_impl(BasicType elembt,
|
||||||
|
arrayOop ary,
|
||||||
|
int index) {
|
||||||
|
if (ary == NULL)
|
||||||
|
return ciConstant();
|
||||||
|
assert(ary->is_array(), "");
|
||||||
|
if (index < 0 || index >= ary->length())
|
||||||
|
return ciConstant();
|
||||||
|
ArrayKlass* ak = (ArrayKlass*) ary->klass();
|
||||||
|
BasicType abt = ak->element_type();
|
||||||
|
if (fixup_element_type(elembt) !=
|
||||||
|
fixup_element_type(abt))
|
||||||
|
return ciConstant();
|
||||||
|
switch (elembt) {
|
||||||
|
case T_ARRAY:
|
||||||
|
case T_OBJECT:
|
||||||
|
{
|
||||||
|
assert(ary->is_objArray(), "");
|
||||||
|
objArrayOop objary = (objArrayOop) ary;
|
||||||
|
oop elem = objary->obj_at(index);
|
||||||
|
ciEnv* env = CURRENT_ENV;
|
||||||
|
ciObject* box = env->get_object(elem);
|
||||||
|
return ciConstant(T_OBJECT, box);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
assert(ary->is_typeArray(), "");
|
||||||
|
typeArrayOop tary = (typeArrayOop) ary;
|
||||||
|
jint value = 0;
|
||||||
|
switch (elembt) {
|
||||||
|
case T_LONG: return ciConstant(tary->long_at(index));
|
||||||
|
case T_FLOAT: return ciConstant(tary->float_at(index));
|
||||||
|
case T_DOUBLE: return ciConstant(tary->double_at(index));
|
||||||
|
default: return ciConstant();
|
||||||
|
case T_BYTE: value = tary->byte_at(index); break;
|
||||||
|
case T_BOOLEAN: value = tary->byte_at(index) & 1; break;
|
||||||
|
case T_SHORT: value = tary->short_at(index); break;
|
||||||
|
case T_CHAR: value = tary->char_at(index); break;
|
||||||
|
case T_INT: value = tary->int_at(index); break;
|
||||||
|
}
|
||||||
|
return ciConstant(elembt, value);
|
||||||
|
}
|
||||||
|
|
||||||
|
// ------------------------------------------------------------------
|
||||||
|
// ciArray::element_value
|
||||||
|
//
|
||||||
|
// Current value of an element.
|
||||||
|
// Returns T_ILLEGAL if there is no element at the given index.
|
||||||
|
ciConstant ciArray::element_value(int index) {
|
||||||
|
BasicType elembt = element_basic_type();
|
||||||
|
GUARDED_VM_ENTRY(
|
||||||
|
return element_value_impl(elembt, get_arrayOop(), index);
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
// ------------------------------------------------------------------
|
||||||
|
// ciArray::element_value_by_offset
|
||||||
|
//
|
||||||
|
// Current value of an element at the specified offset.
|
||||||
|
// Returns T_ILLEGAL if there is no element at the given offset.
|
||||||
|
ciConstant ciArray::element_value_by_offset(intptr_t element_offset) {
|
||||||
|
BasicType elembt = element_basic_type();
|
||||||
|
intptr_t shift = exact_log2(type2aelembytes(elembt));
|
||||||
|
intptr_t header = arrayOopDesc::base_offset_in_bytes(elembt);
|
||||||
|
intptr_t index = (element_offset - header) >> shift;
|
||||||
|
intptr_t offset = header + ((intptr_t)index << shift);
|
||||||
|
if (offset != element_offset || index != (jint)index)
|
||||||
|
return ciConstant();
|
||||||
|
return element_value((jint) index);
|
||||||
|
}
|
||||||
|
|
||||||
// ------------------------------------------------------------------
|
// ------------------------------------------------------------------
|
||||||
// ciArray::print_impl
|
// ciArray::print_impl
|
||||||
|
|
|
@ -25,6 +25,8 @@
|
||||||
#ifndef SHARE_VM_CI_CIARRAY_HPP
|
#ifndef SHARE_VM_CI_CIARRAY_HPP
|
||||||
#define SHARE_VM_CI_CIARRAY_HPP
|
#define SHARE_VM_CI_CIARRAY_HPP
|
||||||
|
|
||||||
|
#include "ci/ciArrayKlass.hpp"
|
||||||
|
#include "ci/ciConstant.hpp"
|
||||||
#include "ci/ciObject.hpp"
|
#include "ci/ciObject.hpp"
|
||||||
#include "oops/arrayOop.hpp"
|
#include "oops/arrayOop.hpp"
|
||||||
#include "oops/objArrayOop.hpp"
|
#include "oops/objArrayOop.hpp"
|
||||||
|
@ -45,15 +47,30 @@ protected:
|
||||||
|
|
||||||
ciArray(ciKlass* klass, int len) : ciObject(klass), _length(len) {}
|
ciArray(ciKlass* klass, int len) : ciObject(klass), _length(len) {}
|
||||||
|
|
||||||
arrayOop get_arrayOop() { return (arrayOop)get_oop(); }
|
arrayOop get_arrayOop() const { return (arrayOop)get_oop(); }
|
||||||
|
|
||||||
const char* type_string() { return "ciArray"; }
|
const char* type_string() { return "ciArray"; }
|
||||||
|
|
||||||
void print_impl(outputStream* st);
|
void print_impl(outputStream* st);
|
||||||
|
|
||||||
|
ciConstant element_value_impl(BasicType elembt, arrayOop ary, int index);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
int length() { return _length; }
|
int length() { return _length; }
|
||||||
|
|
||||||
|
// Convenience routines.
|
||||||
|
ciArrayKlass* array_type() { return klass()->as_array_klass(); }
|
||||||
|
ciType* element_type() { return array_type()->element_type(); }
|
||||||
|
BasicType element_basic_type() { return element_type()->basic_type(); }
|
||||||
|
|
||||||
|
// Current value of an element.
|
||||||
|
// Returns T_ILLEGAL if there is no element at the given index.
|
||||||
|
ciConstant element_value(int index);
|
||||||
|
|
||||||
|
// Current value of an element at the specified offset.
|
||||||
|
// Returns T_ILLEGAL if there is no element at the given offset.
|
||||||
|
ciConstant element_value_by_offset(intptr_t element_offset);
|
||||||
|
|
||||||
// What kind of ciObject is this?
|
// What kind of ciObject is this?
|
||||||
bool is_array() { return true; }
|
bool is_array() { return true; }
|
||||||
bool is_java_object() { return true; }
|
bool is_java_object() { return true; }
|
||||||
|
|
|
@ -41,7 +41,6 @@ private:
|
||||||
union {
|
union {
|
||||||
jint _int;
|
jint _int;
|
||||||
jlong _long;
|
jlong _long;
|
||||||
jint _long_half[2];
|
|
||||||
jfloat _float;
|
jfloat _float;
|
||||||
jdouble _double;
|
jdouble _double;
|
||||||
ciObject* _object;
|
ciObject* _object;
|
||||||
|
@ -111,6 +110,20 @@ public:
|
||||||
return _value._object;
|
return _value._object;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool is_null_or_zero() const {
|
||||||
|
if (!is_java_primitive(basic_type())) {
|
||||||
|
return as_object()->is_null_object();
|
||||||
|
} else if (type2size[basic_type()] == 1) {
|
||||||
|
// treat float bits as int, to avoid comparison with -0 and NaN
|
||||||
|
return (_value._int == 0);
|
||||||
|
} else if (type2size[basic_type()] == 2) {
|
||||||
|
// treat double bits as long, to avoid comparison with -0 and NaN
|
||||||
|
return (_value._long == 0);
|
||||||
|
} else {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Debugging output
|
// Debugging output
|
||||||
void print();
|
void print();
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
|
@ -75,7 +75,6 @@ ciField::ciField(ciInstanceKlass* klass, int index): _known_to_link_with_put(NUL
|
||||||
|
|
||||||
assert(klass->get_instanceKlass()->is_linked(), "must be linked before using its constan-pool");
|
assert(klass->get_instanceKlass()->is_linked(), "must be linked before using its constan-pool");
|
||||||
|
|
||||||
_cp_index = index;
|
|
||||||
constantPoolHandle cpool(thread, klass->get_instanceKlass()->constants());
|
constantPoolHandle cpool(thread, klass->get_instanceKlass()->constants());
|
||||||
|
|
||||||
// Get the field's name, signature, and type.
|
// Get the field's name, signature, and type.
|
||||||
|
@ -116,7 +115,7 @@ ciField::ciField(ciInstanceKlass* klass, int index): _known_to_link_with_put(NUL
|
||||||
// The declared holder of this field may not have been loaded.
|
// The declared holder of this field may not have been loaded.
|
||||||
// Bail out with partial field information.
|
// Bail out with partial field information.
|
||||||
if (!holder_is_accessible) {
|
if (!holder_is_accessible) {
|
||||||
// _cp_index and _type have already been set.
|
// _type has already been set.
|
||||||
// The default values for _flags and _constant_value will suffice.
|
// The default values for _flags and _constant_value will suffice.
|
||||||
// We need values for _holder, _offset, and _is_constant,
|
// We need values for _holder, _offset, and _is_constant,
|
||||||
_holder = declared_holder;
|
_holder = declared_holder;
|
||||||
|
@ -146,8 +145,6 @@ ciField::ciField(ciInstanceKlass* klass, int index): _known_to_link_with_put(NUL
|
||||||
ciField::ciField(fieldDescriptor *fd): _known_to_link_with_put(NULL), _known_to_link_with_get(NULL) {
|
ciField::ciField(fieldDescriptor *fd): _known_to_link_with_put(NULL), _known_to_link_with_get(NULL) {
|
||||||
ASSERT_IN_VM;
|
ASSERT_IN_VM;
|
||||||
|
|
||||||
_cp_index = -1;
|
|
||||||
|
|
||||||
// Get the field's name, signature, and type.
|
// Get the field's name, signature, and type.
|
||||||
ciEnv* env = CURRENT_ENV;
|
ciEnv* env = CURRENT_ENV;
|
||||||
_name = env->get_symbol(fd->name());
|
_name = env->get_symbol(fd->name());
|
||||||
|
@ -189,12 +186,14 @@ void ciField::initialize_from(fieldDescriptor* fd) {
|
||||||
_holder = CURRENT_ENV->get_instance_klass(fd->field_holder());
|
_holder = CURRENT_ENV->get_instance_klass(fd->field_holder());
|
||||||
|
|
||||||
// Check to see if the field is constant.
|
// Check to see if the field is constant.
|
||||||
if (_holder->is_initialized() && this->is_final()) {
|
bool is_final = this->is_final();
|
||||||
|
bool is_stable = FoldStableValues && this->is_stable();
|
||||||
|
if (_holder->is_initialized() && (is_final || is_stable)) {
|
||||||
if (!this->is_static()) {
|
if (!this->is_static()) {
|
||||||
// A field can be constant if it's a final static field or if
|
// A field can be constant if it's a final static field or if
|
||||||
// it's a final non-static field of a trusted class (classes in
|
// it's a final non-static field of a trusted class (classes in
|
||||||
// java.lang.invoke and sun.invoke packages and subpackages).
|
// java.lang.invoke and sun.invoke packages and subpackages).
|
||||||
if (trust_final_non_static_fields(_holder)) {
|
if (is_stable || trust_final_non_static_fields(_holder)) {
|
||||||
_is_constant = true;
|
_is_constant = true;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -227,7 +226,6 @@ void ciField::initialize_from(fieldDescriptor* fd) {
|
||||||
|
|
||||||
Handle mirror = k->java_mirror();
|
Handle mirror = k->java_mirror();
|
||||||
|
|
||||||
_is_constant = true;
|
|
||||||
switch(type()->basic_type()) {
|
switch(type()->basic_type()) {
|
||||||
case T_BYTE:
|
case T_BYTE:
|
||||||
_constant_value = ciConstant(type()->basic_type(), mirror->byte_field(_offset));
|
_constant_value = ciConstant(type()->basic_type(), mirror->byte_field(_offset));
|
||||||
|
@ -273,6 +271,12 @@ void ciField::initialize_from(fieldDescriptor* fd) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (is_stable && _constant_value.is_null_or_zero()) {
|
||||||
|
// It is not a constant after all; treat it as uninitialized.
|
||||||
|
_is_constant = false;
|
||||||
|
} else {
|
||||||
|
_is_constant = true;
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
_is_constant = false;
|
_is_constant = false;
|
||||||
}
|
}
|
||||||
|
@ -344,12 +348,11 @@ bool ciField::will_link(ciInstanceKlass* accessing_klass,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
FieldAccessInfo result;
|
fieldDescriptor result;
|
||||||
constantPoolHandle c_pool(THREAD,
|
LinkResolver::resolve_field(result, _holder->get_instanceKlass(),
|
||||||
accessing_klass->get_instanceKlass()->constants());
|
_name->get_symbol(), _signature->get_symbol(),
|
||||||
LinkResolver::resolve_field(result, c_pool, _cp_index,
|
accessing_klass->get_Klass(), bc, true, false,
|
||||||
Bytecodes::java_code(bc),
|
KILL_COMPILE_ON_FATAL_(false));
|
||||||
true, false, KILL_COMPILE_ON_FATAL_(false));
|
|
||||||
|
|
||||||
// update the hit-cache, unless there is a problem with memory scoping:
|
// update the hit-cache, unless there is a problem with memory scoping:
|
||||||
if (accessing_klass->is_shared() || !is_shared()) {
|
if (accessing_klass->is_shared() || !is_shared()) {
|
||||||
|
@ -373,8 +376,11 @@ void ciField::print() {
|
||||||
tty->print(" signature=");
|
tty->print(" signature=");
|
||||||
_signature->print_symbol();
|
_signature->print_symbol();
|
||||||
tty->print(" offset=%d type=", _offset);
|
tty->print(" offset=%d type=", _offset);
|
||||||
if (_type != NULL) _type->print_name();
|
if (_type != NULL)
|
||||||
else tty->print("(reference)");
|
_type->print_name();
|
||||||
|
else
|
||||||
|
tty->print("(reference)");
|
||||||
|
tty->print(" flags=%04x", flags().as_int());
|
||||||
tty->print(" is_constant=%s", bool_to_str(_is_constant));
|
tty->print(" is_constant=%s", bool_to_str(_is_constant));
|
||||||
if (_is_constant && is_static()) {
|
if (_is_constant && is_static()) {
|
||||||
tty->print(" constant_value=");
|
tty->print(" constant_value=");
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
|
@ -53,9 +53,6 @@ private:
|
||||||
ciInstanceKlass* _known_to_link_with_get;
|
ciInstanceKlass* _known_to_link_with_get;
|
||||||
ciConstant _constant_value;
|
ciConstant _constant_value;
|
||||||
|
|
||||||
// Used for will_link
|
|
||||||
int _cp_index;
|
|
||||||
|
|
||||||
ciType* compute_type();
|
ciType* compute_type();
|
||||||
ciType* compute_type_impl();
|
ciType* compute_type_impl();
|
||||||
|
|
||||||
|
@ -139,7 +136,10 @@ public:
|
||||||
// non-constant fields. These are java.lang.System.in
|
// non-constant fields. These are java.lang.System.in
|
||||||
// and java.lang.System.out. Abomination.
|
// and java.lang.System.out. Abomination.
|
||||||
//
|
//
|
||||||
// Note: the check for case 4 is not yet implemented.
|
// A field is also considered constant if it is marked @Stable
|
||||||
|
// and is non-null (or non-zero, if a primitive).
|
||||||
|
// For non-static fields, the null/zero check must be
|
||||||
|
// arranged by the user, as constant_value().is_null_or_zero().
|
||||||
bool is_constant() { return _is_constant; }
|
bool is_constant() { return _is_constant; }
|
||||||
|
|
||||||
// Get the constant value of this field.
|
// Get the constant value of this field.
|
||||||
|
@ -173,6 +173,7 @@ public:
|
||||||
bool is_protected () { return flags().is_protected(); }
|
bool is_protected () { return flags().is_protected(); }
|
||||||
bool is_static () { return flags().is_static(); }
|
bool is_static () { return flags().is_static(); }
|
||||||
bool is_final () { return flags().is_final(); }
|
bool is_final () { return flags().is_final(); }
|
||||||
|
bool is_stable () { return flags().is_stable(); }
|
||||||
bool is_volatile () { return flags().is_volatile(); }
|
bool is_volatile () { return flags().is_volatile(); }
|
||||||
bool is_transient () { return flags().is_transient(); }
|
bool is_transient () { return flags().is_transient(); }
|
||||||
|
|
||||||
|
|
|
@ -59,6 +59,7 @@ public:
|
||||||
bool is_interface () const { return (_flags & JVM_ACC_INTERFACE ) != 0; }
|
bool is_interface () const { return (_flags & JVM_ACC_INTERFACE ) != 0; }
|
||||||
bool is_abstract () const { return (_flags & JVM_ACC_ABSTRACT ) != 0; }
|
bool is_abstract () const { return (_flags & JVM_ACC_ABSTRACT ) != 0; }
|
||||||
bool is_strict () const { return (_flags & JVM_ACC_STRICT ) != 0; }
|
bool is_strict () const { return (_flags & JVM_ACC_STRICT ) != 0; }
|
||||||
|
bool is_stable () const { return (_flags & JVM_ACC_FIELD_STABLE) != 0; }
|
||||||
|
|
||||||
// Conversion
|
// Conversion
|
||||||
jint as_int() { return _flags; }
|
jint as_int() { return _flags; }
|
||||||
|
|
|
@ -127,6 +127,8 @@ ciConstant ciInstance::field_value(ciField* field) {
|
||||||
ciConstant ciInstance::field_value_by_offset(int field_offset) {
|
ciConstant ciInstance::field_value_by_offset(int field_offset) {
|
||||||
ciInstanceKlass* ik = klass()->as_instance_klass();
|
ciInstanceKlass* ik = klass()->as_instance_klass();
|
||||||
ciField* field = ik->get_field_by_offset(field_offset, false);
|
ciField* field = ik->get_field_by_offset(field_offset, false);
|
||||||
|
if (field == NULL)
|
||||||
|
return ciConstant(); // T_ILLEGAL
|
||||||
return field_value(field);
|
return field_value(field);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
|
@ -522,8 +522,7 @@ ciInstanceKlass::compute_nonstatic_fields_impl(GrowableArray<ciField*>*
|
||||||
|
|
||||||
for (JavaFieldStream fs(k); !fs.done(); fs.next()) {
|
for (JavaFieldStream fs(k); !fs.done(); fs.next()) {
|
||||||
if (fs.access_flags().is_static()) continue;
|
if (fs.access_flags().is_static()) continue;
|
||||||
fieldDescriptor fd;
|
fieldDescriptor& fd = fs.field_descriptor();
|
||||||
fd.initialize(k, fs.index());
|
|
||||||
ciField* field = new (arena) ciField(&fd);
|
ciField* field = new (arena) ciField(&fd);
|
||||||
fields->append(field);
|
fields->append(field);
|
||||||
}
|
}
|
||||||
|
|
|
@ -286,7 +286,10 @@ int ciMethod::itable_index() {
|
||||||
check_is_loaded();
|
check_is_loaded();
|
||||||
assert(holder()->is_linked(), "must be linked");
|
assert(holder()->is_linked(), "must be linked");
|
||||||
VM_ENTRY_MARK;
|
VM_ENTRY_MARK;
|
||||||
return klassItable::compute_itable_index(get_Method());
|
Method* m = get_Method();
|
||||||
|
if (!m->has_itable_index())
|
||||||
|
return Method::nonvirtual_vtable_index;
|
||||||
|
return m->itable_index();
|
||||||
}
|
}
|
||||||
#endif // SHARK
|
#endif // SHARK
|
||||||
|
|
||||||
|
@ -1137,6 +1140,10 @@ bool ciMethod::is_klass_loaded(int refinfo_index, bool must_be_resolved) const {
|
||||||
// ------------------------------------------------------------------
|
// ------------------------------------------------------------------
|
||||||
// ciMethod::check_call
|
// ciMethod::check_call
|
||||||
bool ciMethod::check_call(int refinfo_index, bool is_static) const {
|
bool ciMethod::check_call(int refinfo_index, bool is_static) const {
|
||||||
|
// This method is used only in C2 from InlineTree::ok_to_inline,
|
||||||
|
// and is only used under -Xcomp or -XX:CompileTheWorld.
|
||||||
|
// It appears to fail when applied to an invokeinterface call site.
|
||||||
|
// FIXME: Remove this method and resolve_method_statically; refactor to use the other LinkResolver entry points.
|
||||||
VM_ENTRY_MARK;
|
VM_ENTRY_MARK;
|
||||||
{
|
{
|
||||||
EXCEPTION_MARK;
|
EXCEPTION_MARK;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
|
* Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
|
@ -44,6 +44,7 @@ class ciSymbol : public ciBaseObject {
|
||||||
friend class ciInstanceKlass;
|
friend class ciInstanceKlass;
|
||||||
friend class ciSignature;
|
friend class ciSignature;
|
||||||
friend class ciMethod;
|
friend class ciMethod;
|
||||||
|
friend class ciField;
|
||||||
friend class ciObjArrayKlass;
|
friend class ciObjArrayKlass;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
|
@ -39,5 +39,10 @@
|
||||||
jchar ciTypeArray::char_at(int index) {
|
jchar ciTypeArray::char_at(int index) {
|
||||||
VM_ENTRY_MARK;
|
VM_ENTRY_MARK;
|
||||||
assert(index >= 0 && index < length(), "out of range");
|
assert(index >= 0 && index < length(), "out of range");
|
||||||
return get_typeArrayOop()->char_at(index);
|
jchar c = get_typeArrayOop()->char_at(index);
|
||||||
|
#ifdef ASSERT
|
||||||
|
jchar d = element_value(index).as_char();
|
||||||
|
assert(c == d, "");
|
||||||
|
#endif //ASSERT
|
||||||
|
return c;
|
||||||
}
|
}
|
||||||
|
|
|
@ -888,6 +888,7 @@ void ClassFileParser::parse_field_attributes(u2 attributes_count,
|
||||||
int runtime_visible_type_annotations_length = 0;
|
int runtime_visible_type_annotations_length = 0;
|
||||||
u1* runtime_invisible_type_annotations = NULL;
|
u1* runtime_invisible_type_annotations = NULL;
|
||||||
int runtime_invisible_type_annotations_length = 0;
|
int runtime_invisible_type_annotations_length = 0;
|
||||||
|
bool runtime_invisible_type_annotations_exists = false;
|
||||||
while (attributes_count--) {
|
while (attributes_count--) {
|
||||||
cfs->guarantee_more(6, CHECK); // attribute_name_index, attribute_length
|
cfs->guarantee_more(6, CHECK); // attribute_name_index, attribute_length
|
||||||
u2 attribute_name_index = cfs->get_u2_fast();
|
u2 attribute_name_index = cfs->get_u2_fast();
|
||||||
|
@ -946,15 +947,27 @@ void ClassFileParser::parse_field_attributes(u2 attributes_count,
|
||||||
assert(runtime_invisible_annotations != NULL, "null invisible annotations");
|
assert(runtime_invisible_annotations != NULL, "null invisible annotations");
|
||||||
cfs->skip_u1(runtime_invisible_annotations_length, CHECK);
|
cfs->skip_u1(runtime_invisible_annotations_length, CHECK);
|
||||||
} else if (attribute_name == vmSymbols::tag_runtime_visible_type_annotations()) {
|
} else if (attribute_name == vmSymbols::tag_runtime_visible_type_annotations()) {
|
||||||
|
if (runtime_visible_type_annotations != NULL) {
|
||||||
|
classfile_parse_error(
|
||||||
|
"Multiple RuntimeVisibleTypeAnnotations attributes for field in class file %s", CHECK);
|
||||||
|
}
|
||||||
runtime_visible_type_annotations_length = attribute_length;
|
runtime_visible_type_annotations_length = attribute_length;
|
||||||
runtime_visible_type_annotations = cfs->get_u1_buffer();
|
runtime_visible_type_annotations = cfs->get_u1_buffer();
|
||||||
assert(runtime_visible_type_annotations != NULL, "null visible type annotations");
|
assert(runtime_visible_type_annotations != NULL, "null visible type annotations");
|
||||||
cfs->skip_u1(runtime_visible_type_annotations_length, CHECK);
|
cfs->skip_u1(runtime_visible_type_annotations_length, CHECK);
|
||||||
} else if (PreserveAllAnnotations && attribute_name == vmSymbols::tag_runtime_invisible_type_annotations()) {
|
} else if (attribute_name == vmSymbols::tag_runtime_invisible_type_annotations()) {
|
||||||
runtime_invisible_type_annotations_length = attribute_length;
|
if (runtime_invisible_type_annotations_exists) {
|
||||||
runtime_invisible_type_annotations = cfs->get_u1_buffer();
|
classfile_parse_error(
|
||||||
assert(runtime_invisible_type_annotations != NULL, "null invisible type annotations");
|
"Multiple RuntimeInvisibleTypeAnnotations attributes for field in class file %s", CHECK);
|
||||||
cfs->skip_u1(runtime_invisible_type_annotations_length, CHECK);
|
} else {
|
||||||
|
runtime_invisible_type_annotations_exists = true;
|
||||||
|
}
|
||||||
|
if (PreserveAllAnnotations) {
|
||||||
|
runtime_invisible_type_annotations_length = attribute_length;
|
||||||
|
runtime_invisible_type_annotations = cfs->get_u1_buffer();
|
||||||
|
assert(runtime_invisible_type_annotations != NULL, "null invisible type annotations");
|
||||||
|
}
|
||||||
|
cfs->skip_u1(attribute_length, CHECK);
|
||||||
} else {
|
} else {
|
||||||
cfs->skip_u1(attribute_length, CHECK); // Skip unknown attributes
|
cfs->skip_u1(attribute_length, CHECK); // Skip unknown attributes
|
||||||
}
|
}
|
||||||
|
@ -1774,6 +1787,10 @@ ClassFileParser::AnnotationCollector::annotation_index(ClassLoaderData* loader_d
|
||||||
if (_location != _in_method) break; // only allow for methods
|
if (_location != _in_method) break; // only allow for methods
|
||||||
if (!privileged) break; // only allow in privileged code
|
if (!privileged) break; // only allow in privileged code
|
||||||
return _method_LambdaForm_Hidden;
|
return _method_LambdaForm_Hidden;
|
||||||
|
case vmSymbols::VM_SYMBOL_ENUM_NAME(java_lang_invoke_Stable_signature):
|
||||||
|
if (_location != _in_field) break; // only allow for fields
|
||||||
|
if (!privileged) break; // only allow in privileged code
|
||||||
|
return _field_Stable;
|
||||||
case vmSymbols::VM_SYMBOL_ENUM_NAME(sun_misc_Contended_signature):
|
case vmSymbols::VM_SYMBOL_ENUM_NAME(sun_misc_Contended_signature):
|
||||||
if (_location != _in_field && _location != _in_class) break; // only allow for fields and classes
|
if (_location != _in_field && _location != _in_class) break; // only allow for fields and classes
|
||||||
if (!EnableContended || (RestrictContended && !privileged)) break; // honor privileges
|
if (!EnableContended || (RestrictContended && !privileged)) break; // honor privileges
|
||||||
|
@ -1786,6 +1803,8 @@ ClassFileParser::AnnotationCollector::annotation_index(ClassLoaderData* loader_d
|
||||||
void ClassFileParser::FieldAnnotationCollector::apply_to(FieldInfo* f) {
|
void ClassFileParser::FieldAnnotationCollector::apply_to(FieldInfo* f) {
|
||||||
if (is_contended())
|
if (is_contended())
|
||||||
f->set_contended_group(contended_group());
|
f->set_contended_group(contended_group());
|
||||||
|
if (is_stable())
|
||||||
|
f->set_stable(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
ClassFileParser::FieldAnnotationCollector::~FieldAnnotationCollector() {
|
ClassFileParser::FieldAnnotationCollector::~FieldAnnotationCollector() {
|
||||||
|
@ -2060,6 +2079,7 @@ methodHandle ClassFileParser::parse_method(bool is_interface,
|
||||||
int runtime_visible_type_annotations_length = 0;
|
int runtime_visible_type_annotations_length = 0;
|
||||||
u1* runtime_invisible_type_annotations = NULL;
|
u1* runtime_invisible_type_annotations = NULL;
|
||||||
int runtime_invisible_type_annotations_length = 0;
|
int runtime_invisible_type_annotations_length = 0;
|
||||||
|
bool runtime_invisible_type_annotations_exists = false;
|
||||||
u1* annotation_default = NULL;
|
u1* annotation_default = NULL;
|
||||||
int annotation_default_length = 0;
|
int annotation_default_length = 0;
|
||||||
|
|
||||||
|
@ -2316,16 +2336,30 @@ methodHandle ClassFileParser::parse_method(bool is_interface,
|
||||||
assert(annotation_default != NULL, "null annotation default");
|
assert(annotation_default != NULL, "null annotation default");
|
||||||
cfs->skip_u1(annotation_default_length, CHECK_(nullHandle));
|
cfs->skip_u1(annotation_default_length, CHECK_(nullHandle));
|
||||||
} else if (method_attribute_name == vmSymbols::tag_runtime_visible_type_annotations()) {
|
} else if (method_attribute_name == vmSymbols::tag_runtime_visible_type_annotations()) {
|
||||||
|
if (runtime_visible_type_annotations != NULL) {
|
||||||
|
classfile_parse_error(
|
||||||
|
"Multiple RuntimeVisibleTypeAnnotations attributes for method in class file %s",
|
||||||
|
CHECK_(nullHandle));
|
||||||
|
}
|
||||||
runtime_visible_type_annotations_length = method_attribute_length;
|
runtime_visible_type_annotations_length = method_attribute_length;
|
||||||
runtime_visible_type_annotations = cfs->get_u1_buffer();
|
runtime_visible_type_annotations = cfs->get_u1_buffer();
|
||||||
assert(runtime_visible_type_annotations != NULL, "null visible type annotations");
|
assert(runtime_visible_type_annotations != NULL, "null visible type annotations");
|
||||||
// No need for the VM to parse Type annotations
|
// No need for the VM to parse Type annotations
|
||||||
cfs->skip_u1(runtime_visible_type_annotations_length, CHECK_(nullHandle));
|
cfs->skip_u1(runtime_visible_type_annotations_length, CHECK_(nullHandle));
|
||||||
} else if (PreserveAllAnnotations && method_attribute_name == vmSymbols::tag_runtime_invisible_type_annotations()) {
|
} else if (method_attribute_name == vmSymbols::tag_runtime_invisible_type_annotations()) {
|
||||||
runtime_invisible_type_annotations_length = method_attribute_length;
|
if (runtime_invisible_type_annotations_exists) {
|
||||||
runtime_invisible_type_annotations = cfs->get_u1_buffer();
|
classfile_parse_error(
|
||||||
assert(runtime_invisible_type_annotations != NULL, "null invisible type annotations");
|
"Multiple RuntimeInvisibleTypeAnnotations attributes for method in class file %s",
|
||||||
cfs->skip_u1(runtime_invisible_type_annotations_length, CHECK_(nullHandle));
|
CHECK_(nullHandle));
|
||||||
|
} else {
|
||||||
|
runtime_invisible_type_annotations_exists = true;
|
||||||
|
}
|
||||||
|
if (PreserveAllAnnotations) {
|
||||||
|
runtime_invisible_type_annotations_length = method_attribute_length;
|
||||||
|
runtime_invisible_type_annotations = cfs->get_u1_buffer();
|
||||||
|
assert(runtime_invisible_type_annotations != NULL, "null invisible type annotations");
|
||||||
|
}
|
||||||
|
cfs->skip_u1(method_attribute_length, CHECK_(nullHandle));
|
||||||
} else {
|
} else {
|
||||||
// Skip unknown attributes
|
// Skip unknown attributes
|
||||||
cfs->skip_u1(method_attribute_length, CHECK_(nullHandle));
|
cfs->skip_u1(method_attribute_length, CHECK_(nullHandle));
|
||||||
|
@ -2511,7 +2545,9 @@ Array<Method*>* ClassFileParser::parse_methods(bool is_interface,
|
||||||
if (method->is_final()) {
|
if (method->is_final()) {
|
||||||
*has_final_method = true;
|
*has_final_method = true;
|
||||||
}
|
}
|
||||||
if (is_interface && !method->is_abstract() && !method->is_static()) {
|
if (is_interface && !(*has_default_methods)
|
||||||
|
&& !method->is_abstract() && !method->is_static()
|
||||||
|
&& !method->is_private()) {
|
||||||
// default method
|
// default method
|
||||||
*has_default_methods = true;
|
*has_default_methods = true;
|
||||||
}
|
}
|
||||||
|
@ -2818,6 +2854,7 @@ void ClassFileParser::parse_classfile_attributes(ClassFileParser::ClassAnnotatio
|
||||||
int runtime_visible_type_annotations_length = 0;
|
int runtime_visible_type_annotations_length = 0;
|
||||||
u1* runtime_invisible_type_annotations = NULL;
|
u1* runtime_invisible_type_annotations = NULL;
|
||||||
int runtime_invisible_type_annotations_length = 0;
|
int runtime_invisible_type_annotations_length = 0;
|
||||||
|
bool runtime_invisible_type_annotations_exists = false;
|
||||||
u1* inner_classes_attribute_start = NULL;
|
u1* inner_classes_attribute_start = NULL;
|
||||||
u4 inner_classes_attribute_length = 0;
|
u4 inner_classes_attribute_length = 0;
|
||||||
u2 enclosing_method_class_index = 0;
|
u2 enclosing_method_class_index = 0;
|
||||||
|
@ -2921,16 +2958,28 @@ void ClassFileParser::parse_classfile_attributes(ClassFileParser::ClassAnnotatio
|
||||||
parsed_bootstrap_methods_attribute = true;
|
parsed_bootstrap_methods_attribute = true;
|
||||||
parse_classfile_bootstrap_methods_attribute(attribute_length, CHECK);
|
parse_classfile_bootstrap_methods_attribute(attribute_length, CHECK);
|
||||||
} else if (tag == vmSymbols::tag_runtime_visible_type_annotations()) {
|
} else if (tag == vmSymbols::tag_runtime_visible_type_annotations()) {
|
||||||
|
if (runtime_visible_type_annotations != NULL) {
|
||||||
|
classfile_parse_error(
|
||||||
|
"Multiple RuntimeVisibleTypeAnnotations attributes in class file %s", CHECK);
|
||||||
|
}
|
||||||
runtime_visible_type_annotations_length = attribute_length;
|
runtime_visible_type_annotations_length = attribute_length;
|
||||||
runtime_visible_type_annotations = cfs->get_u1_buffer();
|
runtime_visible_type_annotations = cfs->get_u1_buffer();
|
||||||
assert(runtime_visible_type_annotations != NULL, "null visible type annotations");
|
assert(runtime_visible_type_annotations != NULL, "null visible type annotations");
|
||||||
// No need for the VM to parse Type annotations
|
// No need for the VM to parse Type annotations
|
||||||
cfs->skip_u1(runtime_visible_type_annotations_length, CHECK);
|
cfs->skip_u1(runtime_visible_type_annotations_length, CHECK);
|
||||||
} else if (PreserveAllAnnotations && tag == vmSymbols::tag_runtime_invisible_type_annotations()) {
|
} else if (tag == vmSymbols::tag_runtime_invisible_type_annotations()) {
|
||||||
runtime_invisible_type_annotations_length = attribute_length;
|
if (runtime_invisible_type_annotations_exists) {
|
||||||
runtime_invisible_type_annotations = cfs->get_u1_buffer();
|
classfile_parse_error(
|
||||||
assert(runtime_invisible_type_annotations != NULL, "null invisible type annotations");
|
"Multiple RuntimeInvisibleTypeAnnotations attributes in class file %s", CHECK);
|
||||||
cfs->skip_u1(runtime_invisible_type_annotations_length, CHECK);
|
} else {
|
||||||
|
runtime_invisible_type_annotations_exists = true;
|
||||||
|
}
|
||||||
|
if (PreserveAllAnnotations) {
|
||||||
|
runtime_invisible_type_annotations_length = attribute_length;
|
||||||
|
runtime_invisible_type_annotations = cfs->get_u1_buffer();
|
||||||
|
assert(runtime_invisible_type_annotations != NULL, "null invisible type annotations");
|
||||||
|
}
|
||||||
|
cfs->skip_u1(attribute_length, CHECK);
|
||||||
} else {
|
} else {
|
||||||
// Unknown attribute
|
// Unknown attribute
|
||||||
cfs->skip_u1(attribute_length, CHECK);
|
cfs->skip_u1(attribute_length, CHECK);
|
||||||
|
@ -3948,9 +3997,8 @@ instanceKlassHandle ClassFileParser::parseClassFile(Symbol* name,
|
||||||
this_klass->set_has_final_method();
|
this_klass->set_has_final_method();
|
||||||
}
|
}
|
||||||
this_klass->copy_method_ordering(method_ordering, CHECK_NULL);
|
this_klass->copy_method_ordering(method_ordering, CHECK_NULL);
|
||||||
// The InstanceKlass::_methods_jmethod_ids cache and the
|
// The InstanceKlass::_methods_jmethod_ids cache
|
||||||
// InstanceKlass::_methods_cached_itable_indices cache are
|
// is managed on the assumption that the initial cache
|
||||||
// both managed on the assumption that the initial cache
|
|
||||||
// size is equal to the number of methods in the class. If
|
// size is equal to the number of methods in the class. If
|
||||||
// that changes, then InstanceKlass::idnum_can_increment()
|
// that changes, then InstanceKlass::idnum_can_increment()
|
||||||
// has to be changed accordingly.
|
// has to be changed accordingly.
|
||||||
|
|
|
@ -125,6 +125,7 @@ class ClassFileParser VALUE_OBJ_CLASS_SPEC {
|
||||||
_method_LambdaForm_Compiled,
|
_method_LambdaForm_Compiled,
|
||||||
_method_LambdaForm_Hidden,
|
_method_LambdaForm_Hidden,
|
||||||
_sun_misc_Contended,
|
_sun_misc_Contended,
|
||||||
|
_field_Stable,
|
||||||
_annotation_LIMIT
|
_annotation_LIMIT
|
||||||
};
|
};
|
||||||
const Location _location;
|
const Location _location;
|
||||||
|
@ -143,14 +144,23 @@ class ClassFileParser VALUE_OBJ_CLASS_SPEC {
|
||||||
assert((int)id >= 0 && (int)id < (int)_annotation_LIMIT, "oob");
|
assert((int)id >= 0 && (int)id < (int)_annotation_LIMIT, "oob");
|
||||||
_annotations_present |= nth_bit((int)id);
|
_annotations_present |= nth_bit((int)id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void remove_annotation(ID id) {
|
||||||
|
assert((int)id >= 0 && (int)id < (int)_annotation_LIMIT, "oob");
|
||||||
|
_annotations_present &= ~nth_bit((int)id);
|
||||||
|
}
|
||||||
|
|
||||||
// Report if the annotation is present.
|
// Report if the annotation is present.
|
||||||
bool has_any_annotations() { return _annotations_present != 0; }
|
bool has_any_annotations() const { return _annotations_present != 0; }
|
||||||
bool has_annotation(ID id) { return (nth_bit((int)id) & _annotations_present) != 0; }
|
bool has_annotation(ID id) const { return (nth_bit((int)id) & _annotations_present) != 0; }
|
||||||
|
|
||||||
void set_contended_group(u2 group) { _contended_group = group; }
|
void set_contended_group(u2 group) { _contended_group = group; }
|
||||||
u2 contended_group() { return _contended_group; }
|
u2 contended_group() const { return _contended_group; }
|
||||||
|
|
||||||
bool is_contended() { return has_annotation(_sun_misc_Contended); }
|
bool is_contended() const { return has_annotation(_sun_misc_Contended); }
|
||||||
|
|
||||||
|
void set_stable(bool stable) { set_annotation(_field_Stable); }
|
||||||
|
bool is_stable() const { return has_annotation(_field_Stable); }
|
||||||
};
|
};
|
||||||
|
|
||||||
// This class also doubles as a holder for metadata cleanup.
|
// This class also doubles as a holder for metadata cleanup.
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue